#plugins-dev-chat

1 messages · Page 23 of 1

restive turret
#

sucsk to suck

#

cus idk where it register

hearty shard
#

er

#

what tf r u doing

restive turret
#

searching stuff inside the decompiled unity project

hearty shard
#

NetworkClient.RegisterPrefab

restive turret
#

idk ask david but the prefabs should have NetIndentity

hearty shard
#

errrrrr

#

i dont know

#

i just realized

#

how is this gonna differentiate different door types

#

💔

#

like lcz vs hcz

#

errrr

#

i might lose my mind

upper vapor
#

.name

hearty shard
#

have u seen my code

upper vapor
#

or hardcode the prefab ids

hearty shard
#

all i have is a generic MonoBehaviour

restive turret
#

skill issue

hearty shard
#

damn

upper vapor
#

foreach (var (key, o) in NetworkClient.prefabs)

#

isn't that what you're doing?

hearty shard
#
get
            {
                if (savedPrefab)
                    return savedPrefab;

                foreach (GameObject gameObject in NetworkClient.prefabs.Values.Concat(RagdollManager.AllRagdollPrefabs.Select(r => r.gameObject)))
                {
                    if (gameObject.TryGetComponent(out savedPrefab))
                        return savedPrefab!;
                }

                return null!;
            }
unique crane
#

Turns out

hearty shard
#

david

#

im gonna rage

#

i want you to know this

unique crane
#

So uh after profiling

#

Seems like that animations & Vector3.sub is taking the most kekw

unique crane
worthy rune
#

Vector3.sub?

hearty shard
#

tf is vector3 sub

hearty shard
unique crane
#

Subtraction

hearty shard
#

oh

restive turret
#

unity issue

worthy rune
#

weird

upper vapor
restive turret
unique crane
#

So if you replace it with this

Vector3 res;
res.x = v1.x - v2.x;
res.y = v1.y - v2.y;
res.z = v1.z - v2.z;

return res;
#

It gets much more performant lol

#

Because it aint calling new

hearty shard
#

damn

celest thorn
#

Crazy

hearty shard
#

David

unique crane
#

Like for 1 call its nothing

hearty shard
#

do i just have PrefabStore for most but stuff like doors i could have their own prefab stuff

#

idfk

unique crane
#

but after calls

hearty shard
#

or i completely go back to my old idea

restive turret
#

[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static Vector3 operator -(Vector3 a, Vector3 b)
{
return new Vector3(a.x - b.x, a.y - b.y, a.z - b.z);
}

#

LMAO

random scaffold
#

better

languid temple
unique crane
#

whaa

restive turret
#

!wran millerjr huuuh

regal lakeBOT
#

@restive turret has wranned millerjr Reason: huuuh

hearty shard
#

thank you

languid temple
#

no worries i gotchu

wispy dirge
#

what method/wrapper is used to create a custom keycard?

#

😭

hearty shard
wispy dirge
#

wdym

#

i dont see it

hearty shard
#
KeycardItem.CreateCustomKeycardMetal(
            player,
            ItemName,
            GetHolderName(player),
            CardLabel,
            KeycardPermissions,
            PermissionsColor,
            KeycardColor,
            LabelColor,
            WearLevel,
            SerialLabel)!;
wispy dirge
#

wha

hearty shard
#

or

#

stop using basegame 😭

wispy dirge
#

oh yeah

#

woops

#

labapi nuget exists too

#

i forgor

hearty shard
#

i dont even use that

#

i might never

unique crane
#

I might do like overload with some custom struct instead of all arguments

wispy dirge
#

nuget my beloved

#

i rely on it for everything since im lazy

unique crane
#

Yeah like that

wispy dirge
#

i updated my refs

#

i see it now

#

thank you :D

hearty shard
#

idk what im gonna do w my prefabs

#

do i just have seperate classes for handling door vs ragdoll vs other prefabs?

#

hm

restive turret
#

burn it

hearty shard
#

no!

zealous yarrow
#

please tell me there is a way to turn off debug for labAPI

icy knoll
zealous yarrow
unique crane
restive turret
#

Thank u for giving us 7 hours of time to prepare ClassDTroll

hearty shard
#

or yk 2 weeks

wispy dirge
#

i mean i only had 11 errors

restive turret
#

nah it came right here! its only 7 hour!

unique crane
#

You had 46 hours

#

Since the initial announcement

hearty shard
#

troll

restive turret
unique crane
#

and the refund period is over

#

too bad

random scaffold
#

7 hours

wispy dirge
#

how does KeycardLevels work?

#

im getting rlly confused

hearty shard
wispy dirge
#

oh

#

😭

hearty shard
#

also new(DoorPermissionFlags) exists

#

but yeah

wispy dirge
#

wtf is wearLevel?

#

😭

hearty shard
#

errrr

unique crane
#

Visual dirtiness

hearty shard
#

its wear level!

wispy dirge
#

you can change that/!?!??!?!

unique crane
#

Yea

wispy dirge
#

now thats customization

unique crane
#

You dont really notice it

#

Or at least I never did

#

Like you have to look for it

#

but it is visible

wispy dirge
#

so this is correct?

#

interms of keycard levels

unique crane
#

Yea

#

value from 0-3

wispy dirge
#

k thanks

restive turret
#

if you disable clamp it can make kc as 5, 5, 5

modern plover
#

Y'all is there a way to make cassie broadcasts only audible to players within a certain zone?

hearty shard
unique crane
#

^

modern plover
hearty shard
modern plover
#

;-; I have a bad feeling about this

hearty shard
#

its not too difficult

modern plover
#

I hope so, I'll look into it shortly

hearty shard
#

you just gotta figure out how mirror sends the msg

#

and replicate it

next oracle
#

Like web exploiting lol

hearty shard
#

what

#

yes you replicate how mirrors ends a msg
and then send it to only x player

next oracle
#

Wow

#

That’s easier than I thought

hearty shard
#

what did u think it was

#

i can see if i can figure it out

next oracle
hearty shard
#
[ClientRpc]
    [OriginalAttributes(MethodAttributes.Private)]
    public void RpcCassieAnnouncement(
      string words,
      bool makeHold,
      bool makeNoise,
      bool customAnnouncement,
      string customSubtitles)
    {
      NetworkWriterPooled writer = NetworkWriterPool.Get();
      writer.WriteString(words);
      writer.WriteBool(makeHold);
      writer.WriteBool(makeNoise);
      writer.WriteBool(customAnnouncement);
      writer.WriteString(customSubtitles);
      this.SendRPCInternal("System.Void Respawning.RespawnEffectsController::RpcCassieAnnouncement(System.String,System.Boolean,System.Boolean,System.Boolean,System.String)", -31296712, (NetworkWriter) writer, 0, true);
      NetworkWriterPool.Return(writer);
    }
#

thats it

restive turret
#

speakerSource

hearty shard
#

what

restive turret
#

ah nvm ye

hearty shard
#

idk how exiled does this

#

but i dont wanna copy paste it

restive turret
hearty shard
#

yeah but what if the rpc changes

#

i wanna make it nicer

#

just slightly

#

theres RpcMessage

restive turret
#

ye

hearty shard
#

i just need to replicate that

restive turret
#

SendRPCInternal is just rpcmessage

hearty shard
#

yeah

#

hm

#

how do i do it without
string functionFullName,
int functionHashCode

#

ok the first isnt needed

#

its just logging

#

so what i need is the hash code

restive turret
#

idk how u get the hashid btw

hearty shard
#

errrr

#

errrr

restive turret
#

(ushort)Mirror.Extensions.GetStableHashCode(functionName)

hearty shard
#

and what would function name be

#

ig uhh

#

(Type).(Method)

#

?

#

I HATE THIS

restive turret
#

method.FullName

hearty shard
restive turret
#

@hearty shard can u check if
(ushort)(nameof(RespawnEffectsController.RpcCassieAnnouncement),GetStableHashCode() & 0xFFFF)
returns -31296712 ?

hearty shard
#

Not rn

#

w gf now

upper vapor
hearty shard
#

but i am in call w her watching stuff

upper vapor
#

ohhhh

hearty shard
#

also

#

fuck mirror

#

💔

#

if my stuff works im happy

#

if it doesnt im crying

upper vapor
#

make a new networking solution

restive turret
#

bc the name should be loke this:
System.Void Respawning.RespawnEffectsController::RpcCassieAnnouncement(System.String,System.Boolean,System.Boolean,System.Boolean,System.String)

hearty shard
#

exiled has smth for this

#

iirc

#

to make it auto

#

i just dont wanna copy paste it

upper vapor
#

i mean

#

you can copy-paste the RPC ID

#

for this one use case

hearty shard
#

i want it to be expandable

#

but yes i could

upper vapor
hearty shard
#

yea im already sad

upper vapor
#

hey

#

your gf wants attention

hearty shard
#

tru

#

bai

restive turret
hearty shard
#

i want to be able to get the function has based of Type and string of the rpc method name

restive turret
#

have fun

#

u have to get the System.Void Respawning.RespawnEffectsController::RpcCassieAnnouncement(System.String,System.Boolean,System.Boolean,System.Boolean,System.String)

hearty shard
#

yeah i have to store them

#

somehow

#

reflection time!!

#
private static Dictionary<string, ushort>? typeMethodToHash;

        public static Dictionary<string, ushort> TypeMethodToHash
        {
            get
            {
                const BindingFlags methodFlags = BindingFlags.Instance | BindingFlags.Static | BindingFlags.Public | BindingFlags.NonPublic;

                if (typeMethodToHash == null)
                {
                    typeMethodToHash = new Dictionary<string, ushort>();
                    foreach (Type type in typeof(RoleTypeId).Assembly.GetTypes())
                    {
                        foreach (MethodInfo method in type.GetMethods(methodFlags))
                        {
                            typeMethodToHash.Add($"{type.Name}.{ method.Name}", 0);
                        }
                    }
                }

                return typeMethodToHash;
            }
        }
#

surely

#

smth like this

#

idk wtf im doing

#

😭

upper vapor
hearty shard
#

can you show the line

languid temple
#

no, find it thats part of the fun

upper vapor
#
public static string GenerateMethodName(string initialPrefix, MethodDefinition md)
        {
            initialPrefix += md.Name;

            for (int i = 0; i < md.Parameters.Count; ++i)
            {
                // with __ so it's more obvious that this is the parameter suffix.
                // otherwise RpcTest(int) => RpcTestInt(int) which is not obvious.
                initialPrefix += $"__{md.Parameters[i].ParameterType.Name}";
            }

            return initialPrefix;
        }
#

also the link contains the line

hearty shard
#

ik but im watching stuff

#

soo

upper vapor
#

prefix is "InvokeUserCode_"

hearty shard
#

errrrrr

#

okay

#

so i just gotta use that

upper vapor
#

awit

#

wait

#

might be the wrong code

hearty shard
#

yeah uh

#

that doesnt seem right

#
[ClientRpc]
    [OriginalAttributes(MethodAttributes.Private)]
    public void RpcCassieAnnouncement(
      string words,
      bool makeHold,
      bool makeNoise,
      bool customAnnouncement,
      string customSubtitles)
    {
      NetworkWriterPooled writer = NetworkWriterPool.Get();
      writer.WriteString(words);
      writer.WriteBool(makeHold);
      writer.WriteBool(makeNoise);
      writer.WriteBool(customAnnouncement);
      writer.WriteString(customSubtitles);
      this.SendRPCInternal("System.Void Respawning.RespawnEffectsController::RpcCassieAnnouncement(System.String,System.Boolean,System.Boolean,System.Boolean,System.String)", -31296712, (NetworkWriter) writer, 0, true);
      NetworkWriterPool.Return(writer);
    }
#

InvokeUserCode_ aint there

upper vapor
#

what about
$"{methodInfo.ReturnType.FullName} {methodInfo.DeclaringType.FullName}::{methodInfo.Name}({string.Join(",", methodInfo.GetParameters().Select(e => e.FullName)})"

restive turret
#
public static string GetLongFuncName(Type type, MethodInfo method)
{
    return $"{method.ReturnType.FullName} {type.FullName}::{method.Name}({string.Join(", ", method.GetParameters().Select(x => x.ParameterType.FullName))})";
}
upper vapor
#

that

#

yea

hearty shard
#

cant even send it

upper vapor
#

you need the parameter type's full name

hearty shard
#

yeah uh

#

FullName doesnt exist

upper vapor
#

cuz i forgor

#

use the one Slejm sent

restive turret
#

RPC should never be static so

hearty shard
#

errr

restive turret
#

NetworkWriterPool.Return(networkWriterPooled);

#

use this

#

animal

upper vapor
#

using NetworkWriter writer

hearty shard
#

done

#

anyway

restive turret
#

NetworkWriterPool isnt desposable

hearty shard
#

i hate having to typeof(RespawnEffectsController).GetMethod(nameof(RespawnEffectsController.RpcCassieAnnouncement))!

hearty shard
#

well

#

Pool isnt

#

Pooled is

#

public class NetworkWriterPooled : NetworkWriter, IDisposable

#

which is what pool returns

#

@restive turret did u test ur thing btw

hearty shard
#

idk how id do that

upper vapor
#

AccessTools.Method

restive turret
#

tested the thing

#

should work

upper vapor
#

MY EEYES

restive turret
#

sry

upper vapor
#

ty

celest thorn
#

I have a strange question i was checking the serialization for primitives, and i saw it doesn't work and requires last 4 bytes but there's no mention by the stack trace i figured it out its an UINT but what is that? because in other toys this seems to have a role but on the primitives it doesn't

upper vapor
#

you have the write the dirty bits again for derived classes (every toy)
after the static bit

upper vapor
#

oh wait you're serializing everything

#

nvm

celest thorn
#

yea?

upper vapor
#

doesn't apply for initial spawn

celest thorn
#

1 doesn't do anything

#

0

#

doesn't

#

0 works for primitives

#

for other toys it doesn't

upper vapor
#

the parent ID isn't a syncvar

celest thorn
#

1,2 neither

celest thorn
#

because mirror is asking a last 4 bytes

#

that are a uint

upper vapor
#

oh wait it is written after the...

#

but not on initial spawn

#

you have to invoke the rpc to set the parent

celest thorn
upper vapor
#

wait

#

am i dumb

#

yes

restive turret
#

SerializeSyncVars

celest thorn
upper vapor
#

it does set the parent on initial state

celest thorn
#

OH

#

LOL

#

I UNDERSTOOD

#

But that doesn't explain

#

why toys don't spawn

#

and only primitives do

upper vapor
#

also why don't you use the named overloads instead of generics

celest thorn
upper vapor
#

but this should work i think

celest thorn
#

yes no errors on the client

#

but

#

no primitive

upper vapor
#

add Compression.CompressVarUInt(writer, 255) at the start

#

cuz you need to write all dirty bits on initial send

#

that'll be the missing 4 bytes

restive turret
#

255 the value you syncing

#

if you know how many thigns u write you set the 255 to that

upper vapor
charred sapphire
#

can anyone tell what changes from 14.0 so it's not working anymore?

contest: trying to do voice to player, with role, that cant speak normally.

foreach (var pl in Player.List.Where(r => ev.Player != r && r.IsAlive && Vector3.Distance(ev.Player.Position, r.Position) <= Plugin.Instance.Config.VoiceChatDistance))
{
    LabApi.Features.Console.Logger.Info(pl.Nickname); // write the nickname of the other human
    foreach (var ply in pl.CurrentSpectators)
    {
        ply.Connection.Send(ev.Message);
    }
    
    pl.Connection.Send(ev.Message);
}
celest thorn
upper vapor
#

check their dirty bits

celest thorn
upper vapor
#

i decompiled it

celest thorn
#

on primitives

upper vapor
#

you need to combine all of them

#

1 & 2 & 4 & 8

#

etc

celest thorn
#

ok so

#

32UL + 64UL + 128UL?

restive turret
#

basically waht u want

#

ye

celest thorn
#

Ok crazy i didn't know about that

restive turret
#

its a flag

#

but isnt really like that

celest thorn
#

but still i think there's something on the client thats not allowing them to spawn?

restive turret
#

if you get some no spawn or smth check yo Player.log

#

for primitives you have to write the syncbits 2 times

celest thorn
celest thorn
restive turret
#

well reverse how mirror does it then

celest thorn
#

because it doesn't explain on why

#

it doesn't make any sense if i send spawn message on the Primtive it works but on capybara example it doesn't

#

so its really strange

still thistle
#

a

#

I HAVE A LOTS OF PLUGINS FOR SAKYON SCP SERVER AND SKYZONE SCP

restive turret
#

i dont know who to tag but

Latest has Logger.Debug("Invoking event " + eventHandler.FormatToString(), true);

#

which should not

#

@unique crane I guess you are the right one

unique crane
#

U sure u on experimental?

restive turret
#

im on public

mild ice
#

Which doesn't have the right build right now

#

Sit tight

restive turret
#

oh oki

mild ice
restive turret
#

yup!

#

thank you guys

viscid raven
#

Uhhh guys

#

Why is EXILED not working anymore

#

I updated the server and EXILED isn't starting up

#

Along with all of the plugins

carmine prawn
#

ask exiled discord

#

labapi worked fine

viscid raven
#

I'm gonna cry vro

hearty shard
#

@unique crane uhhh

#

so did yall change SSSS

worthy rune
#

huh

hearty shard
#

public bool IsEnabled => Base.SyncIsB;

#

this returns false

#

Oh

#

wait

#

nvm

#

im stupid

#

MY BAD

worthy rune
#

i know

hearty shard
#

i hate u

#

i forgot !

#

i was returning on enabled not disabled

wispy dirge
#

has this been made aware?
[WARN] [LabApi] Missing DoorName enum value for door name tag HID_LAB

grand flower
#

What's the hotfix for

hearty shard
#
Locker locker = Locker.List.GetRandomValue();
return UseChamber ? locker.Chambers.GetRandomValue().Base.Spawnpoint.position : locker.Position;
#

why does this return null sometimes

#

either locker isnt findable or a locker doesnt have a chamber

#

but its done on round start so i dont see why there'd be 0 lockers around

plain gazelle
#

How can i send a player an RA-Console message?

rugged laurel
hearty shard
#
[2025-05-18 21:07:45.371 +02:00] [STDOUT] ArgumentException: An item with the same key has already been added. Key: ReferenceHub (Name='Player [connId=43]', NetID='5502', PlayerID='28')
[2025-05-18 21:07:45.371 +02:00] [STDOUT]   at System.Collections.Generic.Dictionary`2[TKey,TValue].TryInsert (TKey key, TValue value, System.Collections.Generic.InsertionBehavior behavior) [0x0015a] in <069d7b80a3914a08b6825aa362b07f5e>:0
[2025-05-18 21:07:45.371 +02:00] [STDOUT]   at System.Collections.Generic.Dictionary`2[TKey,TValue].Add (TKey key, TValue value) [0x00000] in <069d7b80a3914a08b6825aa362b07f5e>:0
[2025-05-18 21:07:45.371 +02:00] [STDOUT]   at LabApi.Features.Wrappers.Player..ctor (ReferenceHub referenceHub) [0x0000b] in <bea7f403b90e4786abd99fa819db9853>:0
[2025-05-18 21:07:45.371 +02:00] [STDOUT]   at LabApi.Features.Wrappers.Player.AddPlayer (ReferenceHub referenceHub) [0x00008] in <bea7f403b90e4786abd99fa819db9853>:0
[2025-05-18 21:07:45.371 +02:00] [STDOUT]   at (wrapper delegate-invoke) System.Action`1[ReferenceHub].invoke_void_T(ReferenceHub)
[2025-05-18 21:07:45.371 +02:00] [STDOUT]   at ReferenceHub.Start () [0x00009] in <8db1ca0fe9a6484084cda320b139932c>:0
#
[2025-05-18 21:07:16.187 +02:00] [STDOUT] Exception in Subcontroller RPC handler for SubcontrollerRpcMessage (PlayerID=6 Role=Scp3114 Length=1 Payload=[01 @ 1/1])
[2025-05-18 21:07:16.188 +02:00] [STDOUT] IndexOutOfRangeException: Index was outside the bounds of the array.
[2025-05-18 21:07:16.188 +02:00] [STDOUT]   at PlayerRoles.FirstPersonControl.Thirdperson.Subcontrollers.SubcontrollerRpcHandler+SubcontrollerRpcMessage.ProcessRpc () [0x0004d] in <8db1ca0fe9a6484084cda320b139932c>:0
[2025-05-18 21:07:16.188 +02:00] [STDOUT]   at PlayerRoles.FirstPersonControl.Thirdperson.Subcontrollers.SubcontrollerRpcHandler.ClientProcessMessage (PlayerRoles.FirstPersonControl.Thirdperson.Subcontrollers.SubcontrollerRpcHandler+SubcontrollerRpcMessage msg) [0x00000] in <8db1ca0fe9a6484084cda320b139932c>:0
[2025-05-18 21:07:16.188 +02:00] [STDOUT] UnityEngine.DebugLogHandler:Internal_LogException_Injected(Exception, IntPtr)
[2025-05-18 21:07:16.188 +02:00] [STDOUT] UnityEngine.DebugLogHandler:Internal_LogException(Exception, Object)
[2025-05-18 21:07:16.188 +02:00] [STDOUT] UnityEngine.DebugLogHandler:LogException(Exception, Object)
[2025-05-18 21:07:16.188 +02:00] [STDOUT] UnityEngine.Logger:LogException(Exception, Object)
[2025-05-18 21:07:16.188 +02:00] [STDOUT] UnityEngine.Debug:LogException(Exception)
#

me when

#

@harsh thorn sry for ping ur TransportReceivePatch is in the exception

#
[2025-05-18 21:07:16.184 +02:00] [STDOUT] Mirror.<>c__DisplayClass56_0`1:<ReplaceHandler>b__0(NetworkConnection, SubcontrollerRpcMessage)
[2025-05-18 21:07:16.185 +02:00] [STDOUT] Mirror.<>c__DisplayClass9_0`2:<WrapHandler>g__Wrapped|0(NetworkConnection, SubcontrollerRpcMessage, Int32)
[2025-05-18 21:07:16.185 +02:00] [STDOUT] Mirror.<>c__DisplayClass8_0`2:<WrapHandler>b__0(NetworkConnection, NetworkReader, Int32)
[2025-05-18 21:07:16.185 +02:00] [STDOUT] Mirror.NetworkClient:UnpackAndInvoke(NetworkReader, Int32)
[2025-05-18 21:07:16.185 +02:00] [STDOUT] CedMod.Patches.TransportReceivePatch:Prefix(ArraySegment`1, Int32)
#

also my game is completely borked

carmine prawn
grand flower
#

As well as players not dying in gunfights, although that might be us, anyone else got that?

hearty shard
#

me when i need to wrap this in a try catch

#

cuz get_gameObject returns null ref internally on unitys end 😭

olive falcon
#

does AudioAPI work for 14.1?

restive turret
#

InventoryExtensions.OnItemRemoved
This trigger but the ItemBase is null ALWAYS

#

thanks to removed in the DestroyItemInstance code

#

why even is the out if the item alread being destroyed

#

huh

wispy dirge
#

audioplayerapi works fine

olive falcon
wispy dirge
olive falcon
random scaffold
icy knoll
#

audioplayerapi makes that crap easy

#

so no, they shouldn’t just use speaker toy

#

:3

modern plover
#

:3

wispy dirge
#

🥀

#

either a bug or exiled borked something 😭

restive turret
#

me when I even tested and now nothing works

celest thorn
#

someone knows how do lights be spawned and what they do after spawning them with just spawnmessage doesn't even work

celest thorn
# hearty shard Show code
      NetworkWriterPooled writer = NetworkWriterPool.Get();
      writer.Write<byte>(1); // Flag for 1 NetworkIdentity
      writer.Write<byte>(94); // Size of Syncvar
      writer.Write<Vector3>(position); // Position
      writer.Write<Quaternion>(rotation); // Rotation
      writer.Write<Vector3>(scale); // Scale
      writer.Write<byte>(0); // Movement Smoothing
      writer.Write<bool>(false); // Static
      writer.Write<float>(LightIntensity);
      writer.Write<float>(LightRange);
      writer.Write<Color>(LightColor);
      writer.Write<LightShadows>(ShadowType);
      writer.Write<float>(ShadowStrength);
      writer.Write<LightType>(LightType);
      writer.Write<LightShape>(LightShape);
      writer.Write<float>(SpotAngle);
      writer.Write<float>(InnerSpotAngle);
      writer.Write<uint>(0); // client parent
#

it works fine for mirror

hearty shard
#

Unless ur not creating it server side

celest thorn
hearty shard
#

R u only doing it client side

#

💀

celest thorn
#

btw just funny enough

#

lights don't work

#

but capybaras do

wispy dirge
#

wth happened to dummies 🥀

#

they cause like errors no matter what

#

they work but always cause issues

hearty shard
#

Show

wispy dirge
hearty shard
#

Cant see

wispy dirge
# hearty shard Cant see

[2025-05-18 20:11:10.789 +00:00] Exception while handling encrypted message on channel RemoteAdmin (server, running a handler). Exception: Object reference not set to an instance of an object

#

[2025-05-18 20:11:10.799 +00:00] at PlayerRoles.PlayerRoleManager.PopulateDummyActions (System.Action1[T] actionAdder, System.Action1[T] categoryAdder) [0x00019] in <8db1ca0fe9a6484084cda320b139932c>:0
at NetworkManagerUtils.Dummies.DummyActionCollector+CachedActions.UpdateCache () [0x00016] in <8db1ca0fe9a6484084cda320b139932c>:0
at NetworkManagerUtils.Dummies.DummyActionCollector+CachedActions.get_Actions () [0x00008] in <8db1ca0fe9a6484084cda320b139932c>:0
at NetworkManagerUtils.Dummies.DummyActionCollector.ServerGetActions (ReferenceHub hub) [0x00006] in <8db1ca0fe9a6484084cda320b139932c>:0
at

#

RemoteAdmin.Communication.RaDummyActions.AppendDummy (ReferenceHub dummy) [0x0001e] in <8db1ca0fe9a6484084cda320b139932c>:0
at RemoteAdmin.Communication.RaDummyActions.GatherData () [0x0003a] in <8db1ca0fe9a6484084cda320b139932c>:0
at RemoteAdmin.Communication.RaClientDataRequest.ReceiveData (CommandSender sender, System.String data) [0x00032] in <8db1ca0fe9a6484084cda320b139932c>:0
at RemoteAdmin.Communication.RaDummyActions.ReceiveData (CommandSender sender, System.String data) [0x00095] in <8db1ca0fe9a6484084cda320b139932c>:0
at (wrapper dynamic-method) RemoteAdmin.CommandProcessor.RemoteAdmin.CommandProcessor.ProcessQuery_Patch1(string,CommandSender)
at RemoteAdmin.QueryProcessor.ServerHandleCommandFromClient (ReferenceHub hub, EncryptedChannelManager+EncryptedMessage content, EncryptedChannelManager+SecurityLevel securityLevel) [0x0002d] in <8db1ca0fe9a6484084cda320b139932c>:0
at (wrapper delegate-invoke) <Module>.invoke_void_ReferenceHub_EncryptedChannelManager/EncryptedMessage_EncryptedChannelManager/SecurityLevel(ReferenceHub,EncryptedChannelManager/EncryptedMessage,EncryptedChannelManager/SecurityLevel)
at EncryptedChannelManager.ServerReceivePackedMessage (Mirror.NetworkConnection conn, EncryptedChannelManager+EncryptedMessageOutside packed) [0x00071] in <8db1ca0fe9a6484084cda320b139932c>:0

grand flower
#

Happens when you spawn a dummy before the round starts right?

hearty shard
#

Oh

#

Dummy actions

wispy dirge
#

no

#

just doing anything in terms with dummies

grand flower
#

that's when it was happening to me

wispy dirge
#

round has started

grand flower
#

ah

#

I just patched it out

#

was annoyed at the spam

wispy dirge
#

so i could add it to my plugin 😭

grand flower
#
[HarmonyPatch(typeof(PlayerRoleManager), nameof(PlayerRoleManager.PopulateDummyActions))]
public static class NWRADummySpawningPatch
{
    public static bool Prefix(PlayerRoleManager __instance, Action<DummyAction> actionAdder, Action<string> categoryAdder)
    {
        if (__instance._dummyProviders == null)
        {
            return false;
        }

        var isStillDirty = false;
        foreach (IRootDummyActionProvider dummyProvider in __instance._dummyProviders)
        {
            if (dummyProvider != null)
            {
                try
                {
                    dummyProvider.PopulateDummyActions(actionAdder, categoryAdder);
                }
                catch (Exception)
                {
                    isStillDirty = true;
                }
            }
        }

        __instance.DummyActionsDirty = isStillDirty;
        return false;
    }
}
wispy dirge
#

tysm

#

ill see if it works

restive turret
wispy dirge
# restive turret Ye its known, reported on labapi repo

still broken 🥀
[2025-05-18 20:52:47.826 +00:00] Exception while handling encrypted message on channel RemoteAdmin (server, running a handler). Exception: Field PlayerRoles.PlayerRoleManager:_dummyProviders' is inaccessible from method Site16Essentials.Patches.FuckYouNorthwood:Prefix (PlayerRoles.PlayerRoleManager,System.Action1<NetworkManagerUtils.Dummies.DummyAction>,System.Action1<string>)'
[2025-05-18 20:52:47.836 +00:00] at (wrapper dynamic-method) PlayerRoles.PlayerRoleManager.PlayerRoles.PlayerRoleManager.PopulateDummyActions_Patch1(PlayerRoles.PlayerRoleManager,System.Action1<NetworkManagerUtils.Dummies.DummyAction>,System.Action1<string>)

#

dont ask why i called it FuckYouNorthwood 😭

#

i dont like it when major releases contain easy bugss to find

restive turret
#

Ye this 14.1 is so rushed will need 14.1.1 to fix itwires

wispy dirge
#

😭

upper vapor
subtle ravine
#

It seems that when using primitives that r above ur character and below you your player room position is set to "unknown"
Room.TryGetRoomAtPosition
this method returns false and warhead kills you

wispy dirge
#

toolgun UI is fucked for me

#

any known fixes?

unique crane
#

That is a plugin

#

Ask the creator?

wispy dirge
#

woops i thought i was on MER server

#

😭

wispy dirge
#

😭

icy knoll
#

Does anyone know how to translate a VoiceMessage into something that can be sent over a speakertoy?

#

there is only byte[] for the stuff

upper vapor
#

do you wanna play it instantly?

#

then you can just take the data ig

unique crane
#

I believe so yea

icy knoll
unique crane
#

It uses same system

#

i think

icy knoll
restive turret
#

Hey david

upper vapor
#

yoink the data bytes and length and put it in an AudioMessage

icy knoll
#

.Play doesn't intake voicemessage

#

lol

unique crane
#

But you have the internal float[]

#

Or byte[]

#

whatever

icy knoll
#

there is no float[]

unique crane
#

Data

icy knoll
#

it only accepts float[]

#

lol

upper vapor
#

send an AudioMessage with the speaker's controller ID and the data bytes from the voice message

icy knoll
upper vapor
#

then

#

womp

unique crane
#

Wait

#

got it

upper vapor
#

why would you waste time & resources decoding and re-encoding

icy knoll
#

this is my current code

unique crane
upper vapor
#

yea

unique crane
#

this method converts it from the byte[] to float[]

upper vapor
#

is that on the role?

#

or voicemodule

unique crane
#

Thats in voice module

#

but you can just create new one I guess?

#

OPr maybe

#

SpeakerToy has one?

#

OpusDecoder

icy knoll
#

SpeakerToy has a .Play feature but it doesn't take in the data and parse it for us 😭

upper vapor
#

that's pretty inefficient if you can just yeet back the data from the client

unique crane
#

@icy knoll

#

...

#

I am going to kill youuuu

icy knoll
#

what

#

oh

#

uhhh

restive turret
#

@unique crane
Issue on
InventoryExtension.OnItemRemoved.
When this is called the ItemBase is always null no matter what since you destroy the item inside the (DestroyItemInstance) function.
Can you somehow make a change that call that even BEFORE the ItemBase being destroyed? i would really appreciate that SteamHappy

icy knoll
#

and that doesn't help with playing the audio through speakertoy 😭

#

that's a void function?

unique crane
#

Thats in SpeakerToyPlaybackBase

icy knoll
#

ok and i dont have an audio message

upper vapor
icy knoll
#

but i do have the speakertoy

#

i just want to .Play the audio

#

that's it

ashen hornet
upper vapor
#

no need to waste resources on encoding

icy knoll
upper vapor
#

yea

#

you already have the speaker

icy knoll
#

also, that doesn't seem to send the data?

icy knoll
unique crane
upper vapor
#
new AudioMessage
{
   ControllerId = toy.Id,
   Data = voiceMessage.Data,
   DataLength = voiceMessage.DataLength
}.SendToAuthenticated();
#

or something like that

icy knoll
#

i know that

#

i dont want to do that though, i want to do it directly through labapi itself as it has a speaker toy component

upper vapor
icy knoll
#

unless you legit cant with the component then what??????

#

why have Play methods if neither can be used 😭

upper vapor
#

they can be used

#

if you have the samples

upper vapor
#

but you need to decode the data from the client

upper vapor
icy knoll
#

this code works fine, but I want to make it smaller, no way it needs to be this big

upper vapor
#

you don't need to decode and encode

#

cuz you already have the data you need to send

unique crane
#

Yeah you have the encodedData already

#

in the VoiceMessage

icy knoll
#

so i dont even need the OpusHandler stuff?

restive turret
upper vapor
icy knoll
#

ok

unique crane
#

Yeah you can just skip this part

upper vapor
#

what you did is nothing on a next level Kek

unique crane
#

and use the VoiceMessage.Data

icy knoll
upper vapor
icy knoll
#

now is there a way to eliminate .SendToAuthenticated or do I need to cope and seethe?

unique crane
#

Also please enter the single line returns and continues ):

#

so its more readable

upper vapor
#

or create an extension method named S that invokes SendToAuthenticated

#

or

#

create a struct that creates the audio message and sends it

upper vapor
#

so you get the illusion of new()

icy knoll
#

hmm

#

idk how structs work yet

#

that's my limit of c# knowledge

unique crane
#

Like class but it isnt necessary on heap

#

also its passed by value

icy knoll
#

yeah that says nothing to me david

hearty shard
upper vapor
#

not really

icy knoll
#

also, did an event for labapi get added for when an item is given is given to a player via RA?

hearty shard
#

Theyre different from classes

#

But they are readonly no?

#

just gave the quickest thing i could for her

unique crane
#

@upper vapor Patch Vector3 math operations to remove the constructor call trolling

unique crane
#

It will make the server run faster a bit

icy knoll
icy knoll
#

wdym bruh

hearty shard
#

Struct doesnt pass a ref back it passes the values right

unique crane
#

Not necessary

hearty shard
#

I always thought it was readonly

#

Damn

unique crane
#

No you have to declare it as it

hearty shard
#

Oh

upper vapor
# icy knoll idk how structs work yet

structs can help you avoid memory allocations where applicable
if you create one in a method and don't box, there will be no GC time
(boxing is like casting to object, an interface; or storing it in a class)
when you pass in a struct to a method, it gets copied
you can modify non-readonly structs in the scope you're currently in
but if you invoke a method with that struct, it won't modify the "original" unless you pass it by reference ref

upper vapor
icy knoll
upper vapor
#

okay

#

so

icy knoll
#

nah dw

#

ill read up on it in my own time

royal mica
#

Is it that Struct allows member declaration and free back-casting?

upper vapor
#
void A()
{
    var vec = new Vector3(1,2,3);
    B(vec);
    vec.a; // still 1
}
void B(Vector3 vector)
{
    vector.a = 2;
}
hearty shard
upper vapor
hearty shard
#

Yeah

#

Its a requirements list basically

royal mica
#

Wouldn't that apply for Structs as well?

upper vapor
#

structs are "final"
you can't implement or inherit structs

hearty shard
#

It is purely a requirements list

unique crane
#

Interfaces really just define some behavior

hearty shard
#

Struct you can new()

unique crane
#

which you can implement

royal mica
hearty shard
#

Interface is purely for inheirrit

royal mica
#

Yeah I see now

#

Thank you

hearty shard
#

A lot of times used for

Having a base idea of something

#

Like IPlayerEvent

hearty shard
royal mica
#

(I'm coming from Java/Kotlin background, so it was kind of strange that wall of text dogkek )

hearty shard
#

And handle it all at a time

#

I never actually use struct...

upper vapor
#

interesting

unique crane
#

SL has some really nice examples for interfaces

royal mica
#

in java everything is a suggestion icant

hearty shard
royal mica
#

though I love Java's ENUM more than C#'s

hearty shard
upper vapor
upper vapor
#

good answer

hearty shard
royal mica
#

though it is just a glorified static private class

upper vapor
#

not just enums

#

complex state

unique crane
hearty shard
#

i dont rly have a need for it mostly

royal mica
unique crane
#

-list ends here-

upper vapor
#

also it's weird being red here

hearty shard
unique crane
hearty shard
#

I love discord new thing they adeed

#

Added*

upper vapor
royal mica
#

wait you get msg exp here?

hearty shard
#

Yea

royal mica
#

I do not want to lose green ;-;

upper vapor
#

ye :3

hearty shard
royal mica
#

dam

unique crane
#

I like this bluish one

royal mica
#

%rolecolor green

#

damn

hearty shard
upper vapor
hearty shard
#

Yk what i love?

upper vapor
hearty shard
#

Discords new colors

#

The gradients

#

i love the gradients discord lets us put :3

unique crane
#

Not accessible here ):

#

I dont even like it that much

hearty shard
hearty shard
upper vapor
royal mica
#

I wonder how cursed would it be to write a plugin interpret platform so you could write LabAPI plugins in Kotlin

hearty shard
#

No

#

No

upper vapor
#

just rewrite the server in Kotlin

royal mica
#

would be easier to just write a Kotlin -> C# transpiler lol

hearty shard
#

Awh getting my msgs auto deleted

royal mica
upper vapor
#

that would be too easy

unique crane
#

💀

upper vapor
#

you gotta figure out how unity works, how mirror works, how SL works

#

pretty good weekend throwaway project toomuchtrolling

unique crane
#

Pretty good one year project

upper vapor
#

i mean if you work on it consistently, yea

hearty shard
#

David!!

unique crane
#

I havent seen/touched most of the SL code

#

Only like the most common one

unique crane
upper vapor
hearty shard
unique crane
#

Last time you told me how much hatred feelings you have towards me

#

no

hearty shard
#

Well i missed YOU!

#

Cant believe this

upper vapor
#

um

#

i should reconsider my life choices

hearty shard
#

:)

upper vapor
#

dam it's tomorrow now

unique crane
#

It truly is

#

Im gonna go eep

upper vapor
#

gn

unique crane
#

but updating the labapi dll because some other labapi PR got merged is truly something special :3

unique crane
#

Ah yes

#

Merge master from base game, merge dev from labapi

hearty shard
unique crane
#

Build the base game locally...

hearty shard
#

i would hate to work for nw

unique crane
#

Get the assembly c sharp

#

Compile labapi dll

#

Put new one back in

#

push

#

funny ~20 minutes adventure

hearty shard
#

what r u on about

#

Oh

#

You mean you make a change basegame
Then you need to wait for a compile to get labapi refs

#

Yea thats why i will never become labapi maintainer

unique crane
#

At least Unity 6 server builds takes like 5 mins

hearty shard
#

whats the old build time on unity 5

unique crane
#

Dont ask

hearty shard
#

I just did

#

Now answer!

unique crane
#

Like 30

hearty shard
#

Oh.

unique crane
#

40

#

Depends on your pc

#

But still faster than CDCI pipeline

hearty shard
#

r u happy to no longer spend an hour w a single line change

hearty shard
royal mica
hearty shard
#

Yall have that

royal mica
#

wait, are there ingame unit test framework?

upper vapor
unique crane
#

No, we have QA

royal mica
#

oh slavery

hearty shard
#

momenr

#

Moment

hearty shard
#

Do yall just trust each other

#

To not break build

#

Well not have a broken build pushed by accident

royal mica
#

has bullet targets
has primitve objects
has dummies
looks inside
unit tests are QA slaved
i love this game

hearty shard
#

well itd be caught at some point

upper vapor
hearty shard
unique crane
hearty shard
#

A missing semi colon

#

Breaks C# build

#

itd be caught at some point

#

i usually have git actions to test it tho

#

anyway old chat leak of exiled

#

thunder takes his love confession back (typo?)

upper vapor
hearty shard
#

sometimes

upper vapor
#

yeah but then you don't get a build for QA to test, so no release

#

right

#

?

hearty shard
#

i test in production

#

no QA

upper vapor
hearty shard
#

my docs worked on my machine earlier but then when git actions caught it complained

#

secret api moment

#

?!?!

hearty shard
#

Yes!

upper vapor
#

copium

hearty shard
#

D:\a\SecretAPI\SecretAPI\SecretAPI\Features\PrefabStore.cs(18,33): error CS1723: XML comment has cref attribute 'TPrefab' that refers to a type parameter [D:\a\SecretAPI\SecretAPI\SecretAPI\SecretAPI.csproj]

#

It was this

upper vapor
#

yeah you should've used typeparamref

#

Rider is not that great at XML docs

wispy dirge
#

i love it when NW releases broken releases

#

already you have to patch smthn to make dummies not have errors

#

🥀

#

lots of other things

upper vapor
#

the dummy actions thing?

#

uh

#

have fun

#

:3

wispy dirge
#

no just doing anything with dummies

#

spawning them, healing them, etc etc

unique crane
hearty shard
unique crane
#

No that's gitlab

hearty shard
#

Yeah but

#

Yk what i mean

#

💔

unique crane
#

Um no

hearty shard
#

Thingy has thingy for unity

#

and im gonna murder you

unique crane
#

):

upper vapor
hearty shard
#

i meant gitlab having unity tests

unique crane
hearty shard
#

i mean it makes sense

harsh thorn
#

youd have to build the game somehow hmm

unique crane
#

And then compiles

upper vapor
hearty shard
upper vapor
#

please do

unique crane
#

What unity tests?

upper vapor
#

:33333

unique crane
#

Noooo don't kill axwabo

upper vapor
hearty shard
#

Whoops

upper vapor
#

i wonder how many issues i'll get with the 2 plugin releases

#

have fun with the unity tests

unique crane
#

Eep time

#

Bye

upper vapor
#

byeeee

hearty shard
#

i wanna redo mer, cedmod and ruei myself at some point

#

But

#

Errrrr

#

Nuh ug

#

Nuh ug

#

💔

hearty shard
#

sleep tight

unique crane
#

Gn

restive turret
buoyant oyster
#

any way to view these comment docs in a searchable format? using Rider

#

im spoiled by javadocs, very new to c#

restive turret
#

If you use the labapi nuget might be

#

But you only get doc for labapi and no basegame

carmine prawn
#

Refactored tooltips system to properly re-adjust their position based on the side of the screen they are on. This should result in support for every resolution.

is about hint?

teal junco
#

Im very mad it doesnt have docs

restive turret
#

Y'know what would be funny if LabApi comes with auto patching

#

Should I propose this change or nah? I mean it no longer need Harmony as 3rd party dependency but will be in server

restive turret
#

It should use RespawnTokens i guess

#

Create a pr

carmine prawn
#

I noticed that it has not been "fixed" so

restive turret
#

And wait until 14.2

carmine prawn
restive turret
#

Lel

austere iron
#

Hey who ever have plugin Roleplay Names on LabAPI?

upper pike
#

The hell is wrong with you?

random scaffold
upper pike
upper vapor
#

You're not allowed to display NSFW content in any way

#

Get your horny ahh out bruh 😭

random scaffold
upper pike
#

Why do you want to be the guy who's singlehandily responsible for getting the VSR changed

upper vapor
#

This is a PG-13 game
Not an R rated one

#

Or 16+ technically (according to GeForce NOW at least)

unique crane
#

Your gonna do that once and your gone

icy knoll
#

If you want stuff that is NSFW on your server, your server needs to be on whitelist and you need to do your own age checks

#

and that's according to the VSR

upper pike
icy knoll
random scaffold
#

lol

icy knoll
#

make sure to read up on the vsr to make sure that is true

upper pike
#

!vsr

regal lakeBOT
upper vapor
#

I hate people

icy knoll
upper vapor
#

3.6.1

#

There

upper pike
icy knoll
#

if you just give everyone the whitelist tho, yeah uhhh not good :3

upper vapor
unique crane
#

First statement is a lie 100%

upper vapor
#

I'm a furry

unique crane
#

I knooow

#

just kidding

upper vapor
#

The second statement might change

#

Sometime

unique crane
#

get in the api team

icy knoll
unique crane
#

(free maid outfit)

upper vapor
#

Wenamechainsama
No I'm not gonna work during the summer 😭

upper vapor
unique crane
#

Why the fuck when I open up Paypal

#

its in german

upper vapor
# random scaffold what?

I despise NSFW though I can't prevent you from doing that if the VSR allows you if you meet the requirements
You better make a proper age verification system then

upper vapor
icy knoll
unique crane
#

never in time

#

hours of delays

upper vapor
#

This isn't MÁV's fault this time
Thanks CFR
-# 3h delay

unique crane
#

Yeah uhhhh

#

translation?

upper vapor
#

I don't think many railway companies are known.for being punctual

icy knoll
upper vapor
# unique crane translation?

According to the Romanian railway agency, the EuroCity train Dacia (EC 346) from Bucharest to Vienna is arriving at the border station and departs for Budapest with a 170-180 minute delay.

unique crane
#

😭

upper vapor
#

Some

#

And China

royal mica
#

classic MÁV

#

even if it is not their fault, it is

upper vapor
#

No

#

:3

upper vapor
upper vapor
#

CASSIE KATIE

#

Kollektive Audio Table of Informational Elements

royal mica
upper vapor
#

I'm gonna create KATIE

#

Not sure if the real Kati and MÁV would be okay with that xd

brazen dune
restive turret
wispy dirge
#

[ERROR] [LabApi] [LOADER] Couldn't load the dependency inside '/home/container/.config/SCP Secret Laboratory/LabAPI/dependencies/global/Mono.Posix.dll'

is this known? 😭

unique crane
#

Well thats your dependency..

#

It may have another dependency itself

restive turret
#

that exiled issue

#

you the one before that version

wispy dirge
restive turret
#

??

#

shut down server

#

delete file

#

use older exiled release, grab the same file, and put in there

wispy dirge
#

alr

wispy dirge
hearty shard
#

@unique crane what are the door prefabs called

#

do they just have Lcz and Hcz in theem

unique crane