#plugins-dev-chat

1 messages ยท Page 217 of 1

upper vapor
#

xd

hearty shard
#

nvm

#

i stupid

upper vapor
hearty shard
hearty shard
#

eScps.Scp079.Scp079InteractableBase x) cannot be patched. Reason: Invalid IL code in (wrapper dynamic-method) PlayerRoles.PlayableScps.Scp079.Cameras.Scp079CurrentCameraSync/<>c:PlayerRoles.PlayableScps.Scp079.Cameras.Scp079CurrentCameraSync+c.<TryGetDefaultCamera>b__42_0_Patch0 (PlayerRoles.PlayableScps.Scp079.Cameras.Scp079CurrentCameraSync/<>c,PlayerRoles.PlayableScps.Scp079.Scp079InteractableBase): IL_0047: ret

#

yooo

upper vapor
#

add a pop before

#

omg

#

ughhhhhh

hearty shard
#

pop where

#

.Insert(new CodeInstruction(OpCodes.Dup), new CodeInstruction(OpCodes.Brfalse, skip));

upper vapor
#

you're gonna have to either introduce a local, or modify the skip path

#

cuz

hearty shard
#

guh?

upper vapor
#

you can't just add pop before ret

#

just create a local variable for the room

hearty shard
#

bro....

#

ok how

#

๐Ÿ˜ญ

upper vapor
#

like

#

codematcher

#

something

hearty shard
#

yes

#

how

upper vapor
#

declarelocal

hearty shard
#

no mention of Local

upper vapor
#

rhttps://harmony.pardeike.net/api/HarmonyLib.CodeMatcher.html#HarmonyLib_CodeMatcher_DeclareLocal_System_Type_System_Reflection_Emit_LocalBuilder__

hearty shard
#

this is prob later version of harmony

#

lmao

upper vapor
#

bruh

#

then

#

generator.DeclareLocal

hearty shard
upper vapor
#

var local =

hearty shard
#

ye ye

#

but

#

u get the point

upper vapor
#

then .LocalIndex

#

store it

#

check for null

#

get room

#

dup

#

stloc

#

null check

#

brfalse

#

ldloc

hearty shard
#

what actually is the op_Implicit

#

actually

#

IL check time

#

it literally is just op_Implicit

upper vapor
#

ye

hearty shard
#

new CodeInstruction(OpCodes.Call, AccessTools.Method(typeof(UObject), "op_Implicit")),

#

wouldnt this work?

upper vapor
hearty shard
#

with new CodeInstruction(OpCodes.Ldloca_S, local), before it

upper vapor
hearty shard
#

it didnt

#

IL_001c: call 0x00000005

#

fail

#

thats why im askin

#

omfg

#

i see why

#

yep

#

๐Ÿ˜ญ

#

oops

#

loaded address of var instead of var

upper vapor
#

cfbruh emoji

hearty shard
#

it didnt actually fix null ref tho

#

omfg

#

ax

#

can we

#

just never let me cook again

upper vapor
#

yes we can

hearty shard
#

im 99% sure its cuz i was calling stloc etc w local instead of the index

#

this is what happens when i wake up at 7

upper vapor
#

as a wise hungarian said

hearty shard
#

just let me sleep til 1pm

upper vapor
#

"fรบรบ more"

upper vapor
hearty shard
#
private static IEnumerable<CodeInstruction> Transpiler(IEnumerable<CodeInstruction> instructions, ILGenerator generator)
    {
        LocalBuilder local = generator.DeclareLocal(typeof(Scp079InteractableBase));
        int localIndex = local.LocalIndex;

        CodeMatcher matcher = new CodeMatcher(instructions, generator)
            .End()
            .Advance(-BacktrackCount)
            .CreateLabel(out Label skip)
            .Start()
            .MatchEndForward(new CodeMatch(OpCodes.Callvirt, AccessTools.Method(typeof(Scp079InteractableBase), "get_Room")))
            .Insert(
                new CodeInstruction(OpCodes.Stloc, localIndex),
                new CodeInstruction(OpCodes.Ldloc, localIndex),
                new CodeInstruction(OpCodes.Call, AccessTools.Method(typeof(UObject),  "op_Implicit")),
                new CodeInstruction(OpCodes.Brfalse, skip),
                new CodeInstruction(OpCodes.Ldloc, localIndex));

        return matcher.InstructionEnumeration();
    }
upper vapor
#

uh

#

error?

hearty shard
#

null ref

sweet flax
#

unreal engine reference?

hearty shard
#

nuh uh

#

anyway

#

NullReferenceException

#

thats it literally

#

๐Ÿ˜ญ

upper vapor
upper vapor
hearty shard
#

soooo....

#

valid IL just

#

not workin

upper vapor
#

you can also write prefix notLikeThis

hearty shard
#

no more

#

ONLY transpilers here

upper vapor
#

okay good

hearty shard
#

i dont see why it wouldnt work

#

but im also stupid

#

tbf i could make it a prefix, test it, then make transpiler after lmao

#

but

#

might as well just do funky transpilers

#

for fun!

#

Uhhhhhh

terse bone
#

just guessing, idk what are you patching

hearty shard
#
[2026-05-04 19:45:01.770 +02:00] [DEBUG] [SecretAPI] Instruction: callvirt System.UInt16 PlayerRoles.PlayableScps.Scp079.Scp079InteractableBase::get_SyncId()
[2026-05-04 19:45:01.786 +02:00] [DEBUG] [SecretAPI] Instruction: brfalse.s Label1
[2026-05-04 19:45:01.802 +02:00] [DEBUG] [SecretAPI] Instruction: ldloc.0 NULL
[2026-05-04 19:45:01.816 +02:00] [DEBUG] [SecretAPI] Instruction: stloc 1
[2026-05-04 19:45:01.831 +02:00] [DEBUG] [SecretAPI] Instruction: ldloc 1
[2026-05-04 19:45:01.847 +02:00] [DEBUG] [SecretAPI] Instruction: call static System.Boolean UnityEngine.Object::op_Implicit(UnityEngine.Object exists)
[2026-05-04 19:45:01.862 +02:00] [DEBUG] [SecretAPI] Instruction: brfalse Label3
[2026-05-04 19:45:01.878 +02:00] [DEBUG] [SecretAPI] Instruction: ldloc 1
[2026-05-04 19:45:01.893 +02:00] [DEBUG] [SecretAPI] Instruction: callvirt virtual MapGeneration.RoomIdentifier PlayerRoles.PlayableScps.Scp079.Scp079InteractableBase::get_Room()
[2026-05-04 19:45:01.909 +02:00] [DEBUG] [SecretAPI] Instruction: ldfld MapGeneration.RoomName MapGeneration.RoomIdentifier::Name
[2026-05-04 19:45:01.924 +02:00] [DEBUG] [SecretAPI] Instruction: ldc.i4.s 18
[2026-05-04 19:45:01.940 +02:00] [DEBUG] [SecretAPI] Instruction: bne.un.s Label2
[2026-05-04 19:45:01.955 +02:00] [DEBUG] [SecretAPI] Instruction: ldloc.0 NULL
[2026-05-04 19:45:01.971 +02:00] [DEBUG] [SecretAPI] Instruction: ldfld System.String PlayerRoles.PlayableScps.Scp079.Cameras.Scp079Camera::Label
#

it is wrong though

#

oh wait a minute....

#

oh my gosh

#

wait no it should still work

#

Matches forward and advances position to ending of matching sequence

#

its not doing that though in this case

terse bone
#

it patches successfully right?

hearty shard
#

but the issue is

#

its setting instructions to be before get_Room

#

not after

#

but it should set it after get_Room call

#

its fine ill just .Advance(1)

sweet flax
#

i think the reason could be machendforward since if you are matching one instruciton

terse bone
sweet flax
#

it does not matter if its matchstart or matchend

hearty shard
terse bone
hearty shard
#

[2026-05-04 19:54:02.550 +02:00] [STDOUT] at PlayerRoles.PlayableScps.Scp079.Scp079BlackoutZoneAbility.Update () [0x0000c] in <69208f83d7754673a3350a7c8052e26b>:0
[2026-05-04 19:54:02.566 +02:00] [STDOUT] NullReferenceException: Object reference not set to an instance of an object

#

funny lmao

#

@upper vapor yep cant be fixed

#

client side update

#

afaik

sweet flax
upper vapor
#

lmfao

hearty shard
#

wait

#

ax

#
public override void Update()
  {
    base.Update();
    if (!this.Owner.isLocalPlayer)
      return;
    this._syncZone = ZoneBlackoutIcon.HighlightedZone;
  }
#

null ref here lmao

sweet flax
hearty shard
#

oh nvm

#

cuz its multiple errors lmao

#

Scp079HolidayCameraManager

upper vapor
hearty shard
#

the same goes for TryGetSpeaker in 079 speaker

terse bone
sweet flax
#

yes

#

ill check if im wrong in a moment

terse bone
#

yeah i see, i made a mind shortcut

hearty shard
#

try MatchEndForward will:
Move towards and match until it finds the match
Then it will stay at the end position

#

If you then Insert, you are adding it to the position at the end(in this case get_Room call)

terse bone
#

last instruction
i was thinking about last instruction in sequence to be matched

hearty shard
#

causing that call to get pushed further

terse bone
#

exactly

hearty shard
#

anyway

#

doesnt matter cuz its broken client side no matter what

#

ig

#

wait

#

TECHNICALLY

#

spawn candy room Trol

upper vapor
#

technically

#

don't have cameras

hearty shard
#

true

vast wharf
#

quick question how do i lock the round

hearty shard
#

Round.IsLocked or smth

upper vapor
#

Round.IsLocked

hearty shard
#

= true;

upper vapor
#

brain explosion emoji

vast wharf
#

hmm ok ok

hearty shard
upper vapor
#

why is the emoji named that

hearty shard
#

i do not know

#

also technically source gen for secretapi

#

does nothing

#

since patches are usually expensive but

#

im keeping it in

#

its funnier to save 0.0001ns

hearty shard
#

so

#

funny enough.....

#
while (this.IsValid)
      {
        if (this.MatchSequence(this.Pos, matches))
        {
          if (useEnd)
          {
            this.Pos += matches.Length - 1;
            break;
          }
          break;
        }
        this.Pos += direction;
      }
#

useEnd is whether its End or Start

sweet flax
hearty shard
vast wharf
#

how to exclude this guy ๐Ÿ˜ญ
i'm doing foreach (var player in Player.List)

vast wharf
#

ty

tulip kiln
#

The amount of mr beasts today is crazy

hearty shard
#

@unique crane whats up sigma

hearty shard
#

david hates me ๐Ÿ’”

pulsar locust
#

Damnit why is the automod filter so violent
I can't even mention the certain rich prince scam because the name of the country is automodded because people use it as an nword bypass

unique crane
#

Then mention scammers form India

lapis steppe
#

What are the limitations for instantiating objects using labapi?

#

i may be blind and cant find it in the documentation

unique crane
#

What objects

lapis steppe
#

because i dont think ive ever seen a server have custom meshes

#

everything's made of cubes

unique crane
#

Ah

#

PrimitiveObjectToy

lapis steppe
unique crane
#

Doc? We dont have these yet

lapis steppe
#

ohhhhh

lapis steppe
#

Is it possible to access the meshfilter in any way?

unique crane
#

No

lapis steppe
#

oh ty

lapis steppe
unique crane
#

You have basic unity shapes

#

I recommend using map editors like MER

#

For bigger structures

lapis steppe
#

surely i just use thousands of planes instead of making a custom mesh

unique crane
#

Use quads

lapis steppe
#

oh thats a lot better

pulsar locust
#

Doesn't play as well

unique crane
#

Hm

rustic pecan
#

Can we hide the voice chat pop-ups of players speaking that appear at the end of the match at the right part of the screen?
Or its... sobs ... its the client part?

upper vapor
#

It's client-side

hearty shard
#

theres no pop up if theres no client

rustic pecan
#

And crash it fr ๐Ÿ˜‚

cosmic echo
tulip kiln
#

Unless SL-AC doesn't approve

#

and your players will get banned

restive turret
#

Just ban everyone in the server

rustic pecan
restive turret
#

But no players = no money

#

Somehow I gotta sell those players data!

dull timber
restive turret
#

Contacting meta and selling it to them is hard !

#

This is a joke ofc

unique crane
#

Wild Fasmatus has appeared

restive turret
rustic pecan
tulip kiln
restive turret
#

real and true

sweet flax
#

this is the DNT?

upper vapor
opaque belfry
#

Hello! Do you know setgravity basic values?

wary gust
#

if so, you can just get it from: FpcGravityController.DefaultGravity

unique crane
upper vapor
#

Oh right

#

Hungarian is one of them

sweet flax
restive turret
#

Fps high tps low

vast wharf
#

How do I change the role name of the players displayed on spectator?

#

Or is it only editing the game files?

sinful bronze
#

Translation files

#

Plugins cant change player role name in spectator tab

vast wharf
#

Oh ok ty

pulsar locust
soft turtle
#

Why, if I assign an admin role via ReferenceHub.serverRoles.SetGroup(group), the permissions from permissions.yaml are not assigned?

restive turret
#

prob cus setgroup is temp or something

soft turtle
restive turret
#

how would I know

soft turtle
restive turret
#

I set permission as normally ,search up

soft turtle
royal mica
soft turtle
#

ServerStatic.PermissionsHandler.Members[player.UserId] = group.Name;
I found

restive turret
#

Huh

soft depot
#

Yeah itโ€™d be nice if LabAPI fixed its permissions for this

#

Exiled doesnโ€™t have this issue with its permissions

restive turret
#

I dont even know where to even look

#

I never used the temp group stuff

foggy ruin
#

Is there way to set a players face emotion

unique crane
royal mica
soft depot
#

wdym?

#

you can write your own perm checkers

#

but you'd have to patch other commands if you want them to use said perm checker

foggy ruin
#

how do you check what type of hazard a hazard is

icy knoll
#

type check

#

if(hazard is EnvironmentalHazard envHazard)

#

as an example

#

(i forgot the hazard types, dont flame me)

foggy ruin
#

yeah thats what im tryna figure out ๐Ÿ˜ญ

hearty shard
#

me when Expression actually has validation (pls microsot i dont want validation)

#

i can either reflection call microsoft code
or i can publicize it

soft depot
#

or better yet

#

use UnsafeUtility from Unity to just write the bits lil bro

hearty shard
#

idk about that one

hearty shard
#

i mean

#

another solution is to

#

not use Expression

#

and generate a new method

#

at runtime

#

with IL

#

IL doesnt have this issue soo

#

david

#

YOU do this

unique crane
restive turret
#

What are you even trying to do

hearty shard
#

optimize reflection into just basic delegates

#

it prob works for non readonly but

#

because MS has validation for readonly checks it kindaaa doesnt.

upper vapor
#

why is the search icon there tho ๐Ÿ˜ญ

hearty shard
unique crane
#

Expression?

hearty shard
# unique crane Expression?

Provides the base class from which the classes that represent expression tree nodes are derived. It also contains static (Shared in Visual Basic) factory methods to create the various node types. This is an abstract class

unique crane
#

ohh

#

syntax tree type shit

hearty shard
#

you can generate access so like bool value = someClass.someField;

#

but

#

it still has validation

#

which STINKS

hearty shard
#

oh hey i found this in harmony

#

lmao

#

i never had to work for it

upper vapor
#

obsolete

hearty shard
red tide
#

Is there way to toggle this UI on not spectator role?

sinful bronze
#

thats client sided

red tide
sweet flax
#

How can the Player::GameObject be null?

#

since its nullable

thin shuttle
restive turret
#

Player left

thin shuttle
#

also do not use 'GameObject is null' always do 'GameObject == null'

sweet flax
#

then should the reference hub be null too?

restive turret
#

It doesnt really delete the script if saved

thin shuttle
restive turret
#

Well if something deletes it maybe ye

sweet flax
thin shuttle
#

oh yeah

#

here ReferenceHub is null

#

my bad

sweet flax
# sweet flax

following the logic of the GameObject being nullable then ReferenceHub should be also nullable

#

or just add some <remakrs>

#

@restive turret

restive turret
#

i guess

rustic pecan
#

Can we exclude a specific player from 079's breach scanner?

unique crane
#

Sorry

#

Or uh

#

Maybe

sweet flax
#

patch?

unique crane
#

Check the server code

#

Not sure how it is handled

rustic pecan
#

Also does the window on the button in SCP-079's containment have a specific identifier or sth?

sweet flax
#

Scp079Recontainer::_activatorGlass

rustic pecan
#

I havent found one tho, mb Im checking the wrong part of code, but I only got NetworkId of BreakableWindow

rustic pecan
sweet flax
rustic pecan
#

Kinda worked

#

My idea is to prevent decontam if a specific player tries to attack the button

#

I do this via PlayerEvents::PlayerDamagingWindow event (or sth like that)

#

The funniest thing is it works but only when a player shoots the button

#

If uses meleee

#

If he throws an item at the window

#

If he tries to nade

#

this event doesnt activate

#

I suppose

restive turret
#

isnt the breaking of it is server code

spare zodiac
#

custom info is so weird
Works: <size=10>test</size>Text here
Doesn't: Text here<size=10>test</size>

upper vapor
spare zodiac
upper vapor
#

Wait what

#

I thought you could only have rich text tags only around the text, not somewhere in between

spare zodiac
#

wait but this works
<size=10>Test</size><size=30>Test</size>

upper vapor
#

This is crazy

spare zodiac
#

this is so fucking dumb, but I've figured this out with sizes finally SteamHappy

unique crane
#

Also I don't think that you can have RT tags in custom info

#

They get sanitized

upper vapor
#

You can

worn gull
#

This way it works for me

upper vapor
worn gull
hearty shard
#

When rework ax

upper vapor
#

I'm not gonna be reworked

vast wharf
#

any way to make the red dot of the last player not dissapear because of tutorials?

upper vapor
#

I would look for the class but gitlab search is one of the most awful things ever created

upper vapor
vast wharf
#

thanks

upper vapor
#

Np

worn gull
spare zodiac
worn gull
spare zodiac
#

my theory is that it was made by NW

upper vapor
spare zodiac
#

a gaming theory

unique crane
sweet flax
#

Stop the nw hate

#

Hate the release calendar

sacred sierra
#

i remember some discussions about that

terse bone
#

I think it is all about not allowing to fake global badges

soft turtle
#

What's the point of this constructor if it's not called? I put a Logger there, but it's never called

restive turret
#

yes

#

localplayer calling that

soft turtle
soft turtle
restive turret
#

AutoActionModule.ServerProcessCmd

soft turtle
#

Where is the check that the Target is correct?

soft turtle
restive turret
#

ShotBacktrackData.ProcessShot

soft turtle
restive turret
#

HasPrimaryTarget

soft turtle
restive turret
#

yes

#

write hub writes the id or 0

#

if 0 that means no hub found

soft turtle
#

Does the server really trust the client completely?

restive turret
#

ยฏ_(ใƒ„)_/ยฏ

#

it does backtrack

#

and idk, never really checked anything for firearm stuff

soft turtle
unique crane
#

This is just

#

"hey, I shot from this position, with this rotation at this time and I myself shot this person at this position at that time"

#

and server validates that

slender depot
#

Where the hint sent by networkConnection.Send(new HintMessage(hint)); is processed? (I found this line in HintDisplay)

sweet flax
icy knoll
#

Parameters are replaced on the client so yeah

sweet flax
icy knoll
#

Ohhh that

#

Right

spring kelp
#

hi, quick or not quick question, is it possible to change the item name in the inventory for only 1 player and only 1 item, like if i want to make customitem with custom name

sacred sierra
spring kelp
#

hah, thanks guys

spring kelp
#

tbh i have 1 more question in mind, if i wanted to spawn the firearm pickup with ammo in it how can i possibly do that

upper vapor
spring kelp
#

thanks, i'll definitely try that

terse bone
upper vapor
#

that can work too, but doesn't that apply random attachments? (may or may not be desired)

terse bone
#

it tries to apply them only if it doesn't find code for that serial in attachmentsync

#

so it will be fine if he sets attachments before calling this method

spring kelp
#

i could have overcomplicated that tbh

upper vapor
#

firearm.TryGetModule

#

also, you can do InventoryItemLoader.TryGetTemplate(Type, out Firearm? firearm)

spring kelp
#

maybe im missing reference

upper vapor
#

that one

spring kelp
#
{
    mag.ServerSetInstanceAmmo(pickup.Serial, 30);
}```
#

yep (i changed it to 20)

#

many thanks

upper vapor
#

np

spring kelp
#

yo, does anybody know how to change firearm pickup's attachments and firearm item's attachments e.g. when i spawn pickup i want it with custom fixed attachments and when i give custom weapon to player via command i want it to have fixed attachments

terse bone
#

you can get attachments code of firearm your currently holding by using forceatt command

#

discord outage my beloved

spring kelp
#

oh, that's interesting, I'll try that tomorrow, thanks

static meteor
# spring kelp yo, does anybody know how to change firearm pickup's attachments and firearm ite...
        public static bool TryApplyAttachment(this Firearm firearm, AttachmentName name)
        {
            Attachment targetAttachment = firearm.GetAttachmentByName(name);
            if (targetAttachment == null)
                return false;

            uint newCode = firearm.GetCurrentAttachmentsCode();

            for (int i = 0; i < firearm.Attachments.Length; i++)
            {
                Attachment attachment = firearm.Attachments[i];
                if (attachment.Slot == targetAttachment.Slot)
                {
                    uint bitToRemove = 1u << i;
                    newCode &= ~bitToRemove;
                }
            }

            for (int i = 0; i < firearm.Attachments.Length; i++)
            {
                if (firearm.Attachments[i] == targetAttachment)
                {
                    uint bitToAdd = 1u << i;
                    newCode |= bitToAdd;
                    break;
                }
            }

            firearm.ApplyAttachmentsCode(newCode, true);
            firearm.ServerResendAttachmentCode();

            return true;
        }

        public static bool TryApplyAttachment(this FirearmPickup firearmPickup, AttachmentName name)
        {
            firearmPickup.Info.ItemId.TryGetTemplate<Firearm>(out var firearm);
            if (firearm == null)
                return false;

            firearm.ItemSerial = firearmPickup.Info.Serial;
            AttachmentCodeSync.ServerSetCode(firearmPickup.Info.Serial, AttachmentsUtils.GetRandomAttachmentsCode(firearmPickup.Info.ItemId));
            bool success = TryApplyAttachment(firearm, name);
            if (success && firearm.WorldModel != null)
            {
                firearm.WorldModel.Setup(firearm.ItemId, firearm.WorldModel.WorldmodelType, firearm.GetCurrentAttachmentsCode());
                return true;
            }
            else
                return false;
        }
#
        public static uint GetCodeFromAttachmentNamesRaw(this Firearm firearm, AttachmentName[] attachments)
        {
            uint attachmentNamesRaw = 0;
            uint num = 1;
            foreach (Attachment attachment in firearm.Attachments)
            {
                if (attachments.Contains(attachment.Name))
                    attachmentNamesRaw += num;
                num *= 2U;
            }

            return attachmentNamesRaw;
        }

        public static Attachment GetAttachmentByName(this Firearm firearm, AttachmentName name)
        {
            foreach (Attachment attachment in firearm.Attachments)
            {
                if (attachment.Name == name)
                    return attachment;
            }

            return null;
        }

spring kelp
#

yoo, that's so helpful, thank you, would you mind if I implemented part of it in my code

cyan crown
#

anyone has any idea what algorithm scpsl uses for its layout generation

soft depot
#

gambling

#

the general idea though is just pick a random layout and populate it with rooms randomly

#

here's a zip of a bunch of layouts, the Hcz ones might be wrong though due to NW changing them last christmas I think

cyan crown
#

thanks

cyan crown
#

Is GPU skinning still set to cpu in current SL?

cyan crown
#

Oh cool its probably not BSP

#

About gpu skinning does current SL still use cpu skinning the image i took is from version 8.0.1

unique crane
#

It's literally

#

Random.next

#

Choose layout

#

Random.next

#

Choose room

#

Random.next

#

Choose items

#

Random has the seed in ctor

#

+the rooms spawn connectors

#

In heavy

cyan crown
#

Cool thanks for letting me know i'll make sure to note it down for later use

upper vapor
#

you can just decompile the code and see it for yourself toomuchtrolling

cyan crown
#

Yea sure i just dont find time for it sadly

terse bone
#

crazy

upper vapor
#

blud is holding a piece of paper, not a phone ๐Ÿ˜ญ

thin shuttle
unique crane
#

I believe it is?

thin shuttle
#

nope

unique crane
#

u sure?

thin shuttle
#

i use to play on Server that have a set seed

#

the only container that are keep in place are the one spawn by plugin

unique crane
#

Dunno if this is GD choice or programming tbh

#

Ill ask

thin shuttle
#

probably miss

#

it's use @unique crane UnityEngine.Random.Range

#

also do you know what the reason to implemented StructurePositionSync

restive turret
#

Old mirror

#

Or was unet

thin shuttle
restive turret
#

ยฏ_(ใƒ„)_/ยฏ

thin shuttle
#

i remind spawning generator with any rotation value

#

now impossible with the new implementation

#

and still work for object that do not have this NetworkBehaviours

#

an example for Door not having it and generator having it

#

(the White line is the server side collision of it)

#

that would never be a basegame bug since obvisouly Generator is never spawn on ground or on a not flat wall

#

but i would love this to be fixed :3 as how it's was before

foggy ruin
#

how would you fake the appearance of a player

#

like make a chaos look like an ntf

upper vapor
foggy ruin
#

ty

upper vapor
#

Np

foggy ruin
#

when a player dies does the spoof get reset to their new role

restive turret
#

Nope you have to handle that

hearty shard
#

eggs

harsh thorn
#

so the spoof stays as long as you keep returning the role of choice

foggy ruin
#

For some reason spoofing a dummy Scientist to D-Class works fine, but when I spoof a Chaos Conscript dummy to Ntf private it kicks me from the game

terse bone
#

there are some roles that require additional data to be sent

foggy ruin
#

ah

terse bone
#

all foundation military roles require sending 1 byte of unitid

worn gull
#

Check how LabApiExtension do it

upper vapor
#

yeah, you can use that too

#

i forgor

cyan crown
#

oh i see

#

classic

thin shuttle
upper vapor
#

i would just nuke SPS tbh

thin shuttle
#

please do

upper vapor
#

buuuut

#

mirror

thin shuttle
#

game work perfectly fine without it

upper vapor
#

and nested hierarchies

thin shuttle
#

can you try and see what happen ?

#

i don't remember any issue about hierarchies even if i have been told a lot about that

restive turret
thin shuttle
#

we see nest hierarchie with Primitive ?

restive turret
#

??

#

what

thin shuttle
#

when people parent primitive to an other primitive

#

that work fine right

restive turret
#

ye but it is runtime

thin shuttle
#

i miss a word

restive turret
#

not build time

thin shuttle
#

oh so the problem is there only at runtime

#

but so that fine

#

since they are spawn after ?

#

except for very few locker like HID / Scp127

#

that arent spawnable

restive turret
#

tbh SPS can be removed but idk, need to change some spawning code for able to do stuff with it

upper vapor
#

solution: kill mirror

restive turret
#

mirror already sending rotation btw so

upper vapor
#

but everything is local

#

meanwhile it spawns at the scene root

cyan crown
upper vapor
#

whoever did that was an absolute genuis

restive turret
upper vapor
soft depot
upper vapor
spare zodiac
cyan crown
#

hold on let me check hubert stream

#

oh its called _scripts

upper vapor
#

yes Kek

cyan crown
#

interesting same as folder name since 8.0.1

#

damn okay then Destory _Scripts ClassDTrollHD

upper vapor
#

jokes on you, Destroy() is not valid on files

cyan crown
#

since its same folder name does it mean GPU skinning is still set to CPU

cyan crown
thin shuttle
#

@upper vapor i have very simple fix

#

you self destroy the component

#

after it's get spawn

#

so we can unspawn and respawn it safely

#

that would be the most broken way of doing it

upper vapor
#

how about we remove structures

cyan crown
#

Axwabo are you using unty right nowSteamHappy

#

unty

upper vapor
#

not at this very moment but i was planning to do that today

#

waiting for the Division engine to drop ๐Ÿ”ฅ

cyan crown
#

ah i see i just wanted to know if scpsl still uses CPU skinning

cyan crown
marble cobalt
#

Should be using GPU batched

upper vapor
cyan crown
#

awesome i thought why the game lags because its using CPU skinning in older versions of the game

cyan crown
upper vapor
upper vapor
#

fun fact: unity hub disappeared from my system today after an upgrade

#

(at least the shortcut did)

cyan crown
#

lol

#

malware activated

upper vapor
#

unity could be anything tbh ๐Ÿ˜ญ

#

its own upgrade scriptlet does a separate upgrade

#

kinda sus ngl

cyan crown
#

install valorant to fix unity

#

๐Ÿ˜ญ

upper vapor
#

gonna be pretty difficult on linux

cyan crown
#

i was looking forward to s&box but after they revoked my access i just gave up on it

#

it doesn't even appear on my steam search list

upper vapor
#

you can just

#

build the engine yourself

#

-# probably no source 2 license tho

cyan crown
#

yeah the license :(

thin shuttle
cyan crown
#

i'll just stick to unity until they do something good

#

probably never

upper vapor
#

no 300 fps :((

thin shuttle
#

do you know when it's was added ?

upper vapor
#

any minute now

#

"preview size limit exceeded"

#

this has been a thing ever since spawnable structures have existed

thin shuttle
upper vapor
#

2021

thin shuttle
#

ok

#

it's strange because i am pretty sure i seen Generator rotation working before

upper vapor
#

hallucinations? TrollDespair

thin shuttle
#

could be reminder of before 2021

#

i played SL before COVID

restive turret
cyan crown
#

๐Ÿ˜ญ

silk prawn
#

Could someone tell me why Sever Specific Settings won't register?

        public static void Register()
        {
            ServerSpecificSettingsSync.ServerOnSettingValueReceived += OnValueReceived;
        }

        public static void Unregister()
        {
            ServerSpecificSettingsSync.ServerOnSettingValueReceived -= OnValueReceived;
        }

        private static void OnValueReceived(ReferenceHub referenceHub, ServerSpecificSettingBase settingBase)
        {
            if (!Player.TryGet(referenceHub.gameObject, out Player player))
                return;

            if (settingBase is SSKeybindSetting keybindSetting && keybindSetting.SettingId == 30 && keybindSetting.SyncIsPressed)
            {
                if(player.Role != PlayerRoles.RoleTypeId.ClassD)
                {
                    player.SetRole(PlayerRoles.RoleTypeId.ClassD);
                }
                else
                {
                    player.SendHint("You're already Class-D!", 3f);
                }
            }
        }
upper vapor
#

did you.. add them to the list?

#

btw i'd recommend using SecretAPI for SSSS, a lot easier to deal with

silk prawn
#

hold on let me try then

upper vapor
vast wharf
#

is there any way to set friendly fire on only for tutorials?

unique crane
sweet flax
#

how is functionHashCode being set?

#

is there some code that is being compiled or is it const?

restive turret
#

Huh

#

Example, place

#

Or what are you exactly talking about

sweet flax
#

its used in network behaviour

#

sendrpcinternal

#

RpcMessage

#

im thinkig its mirrors extension getstablehashcode

restive turret
#

Yes

sweet flax
#

and its called on nameof?

restive turret
#

You can read more in mirror

#

Or check my repo and see it

sweet flax
#

will text tomorow if if found it

#

jk

#

could you tell which one

restive turret
sweet flax
#

is there some example on how SL does that?

#

like officail code

#

or they are just typing it by hand

restive turret
#

Auto generated

sweet flax
restive turret
#

Weavers are fun

#

I enjoy working them more instead of source generators

sweet flax
#

its unity only?

restive turret
#

Nope

#

You can use fody for it in not unity project

#

And source generators works in unity now too

sweet flax
#

most usefull network writer

#

thats why the game is unplayable

restive turret
#

Server doesn't have any audio lol

sweet flax
#

its a clientrpc

restive turret
#

Ye

sweet flax
#

end then given back

restive turret
#

That's why the server send and rpc "hey, okay voice"

sweet flax
#

couldnt it be just ArraySegment<byte<.Empty?

restive turret
#

Send patches to mirror

#

It's auto generated so go there create prs however you like it

sweet flax
#

it also probably fdoesnt matter

thin shuttle
#

if that what you need

sweet flax
thin shuttle
restive turret
#

!leak

restive turret
vast wharf
upper vapor
#

99% of my playtime toomuchtrolling

carmine prawn
#

๐Ÿ’€

#

Does the base game limit the maximum value of world coordinates?

thin shuttle
#

maximum value are kinda float.infinity

upper vapor
#

if you have no map, you can have up to 254 waypoints

thin shuttle
#

can you remind me how big is the square of a waypoint in metric ?

carmine prawn
#

I tried placing my map away from the facility, but players don't seem to be able to teleport there

upper vapor
#

no clue how the unity measurement system works ngl

restive turret
#

However big you want

upper vapor
#

but should be 128 units

thin shuttle
upper vapor
#

then it's very slightly less than 128

#

iirc there's a const for max range

thin shuttle
carmine prawn
#

so maybe I can expand it?

#

or not

upper vapor
#

you have bigger problems if you need a map that has an area larger than 320 square kilometers

carmine prawn
#

only about 200x100x200 size in the unity editor, using MER

upper vapor
#

make it smaller

carmine prawn
#

๐Ÿ˜ญ

upper vapor
#

you know you can scale things down

carmine prawn
#

smaller player and map scale?

upper vapor
#

yeeeees

thin shuttle
thin shuttle
#

but it's required unspawn and respawn Waypoint and making sure Ragdoll // item are correctly sync

upper vapor
thin shuttle
#

if you teleport Waypoint in the direction you going

#

that can work

carmine prawn
#

So I have these solutions:

  1. scale down the entire map and the player's proportions
  2. use waypoints to teleport the player
    ||3. tell NW to change back the surface Y position back to the original 1000||
    right?
thin shuttle
#

you can't scale down a Room

#

(except HczTestRoom and Ez330 but these are exception)

#
  1. use waypoint as regular not teleport
#
  1. they won't it's was to fix flickering bug on MTF clothes
#

why do you need it back to Y level 1000

carmine prawn
#

I may not have fully explained my question Hmm

#
  1. What I want to place is an extra map that I created in MER. If possible, I can delete the entire facility since I won't be using any of the rooms within it
#
  1. I tried using OnServerMapGenerating and then setting seed = -1 to delete the map, but it seems to cause a desync error that prevents players from moving normally / noclip. This issue also occurs when exceeding a certain area beyond the world boundary
#

This is why I asked, "Does the base game limit the maximum value of world coordinates?"

upper vapor
#

but yeah it's a bit funky sometimes

#

and if you have no waypoints, ofc the player won't be able to move

carmine prawn
#

oh, waypoint

#

I completely overlooked it (on none map)

soft turtle
#

Is it possible to play sounds through the voice chat on behalf of a player? Like making it seem as if the player is speaking through the intercom

carmine prawn
#

and.. May I ask what a waypoint is?

restive turret
#

The thumbnail is 10/10

soft turtle
upper vapor
#

what am i looking at ๐Ÿ˜ญ

#

you can use SecretLabNAudio to play audio, even as players

worn gull
upper vapor
#

if you already have your own API, just send a VoiceMessage instead of an AudioMessage

upper vapor
worn gull
upper vapor
hearty shard
#

no need to copypaste it (also wouldnt work)

thin shuttle
#

:)

thin shuttle
carmine prawn
#

๐Ÿ˜ญ

thin shuttle
#

RelativePosition is just your position from an other object

#

it's made like this in SL for Elevator system

and they put it everywhere because they found they use less ressource for sync player position

#

as it's 4 byte value

  • 8 Id
  • 16 x
  • 16 y
  • 16 z
    16 x 3 + 8 = 56
    instead of 3 float
  • 32bits x
  • 32bits y
  • 32bits z
    32 x 3 = 96
#

@carmine prawn

thin shuttle
#

you don't really need to know how the sytem work

#

tho

upper vapor
#

๐Ÿฉณ

thin shuttle
#

oups

carmine prawn
thin shuttle
#

and that enough

carmine prawn
#

yep, I think that covers it. Thanks PeepoLove

#

I previously thought that Waypoint *only *worked with elevators

terse bone
upper vapor
#

it just makes things a lot worse

thin shuttle
#

they sent less data through network

upper vapor
#

waypoint purge at some point hopefully

thin shuttle
#

Waypoint is very good but should be limited to Elevator / moving object

#

@upper vapor do you know micro optimisation i would have an question

#

float num = this.Priority * this.Priority * Mathf.Sign(this.Priority);
or
float num = this.Priority * Mathf.Abs(this.Priority);

#

what the best

upper vapor
#

most likely the latter one

thin shuttle
#

i just chech Math.Abs

#

and yeah

#

2nd one is better

#

but i didn't expect int.MinValue would OverflowException on Math.Abs

soft turtle
#

How to remove dummy from the player list?

upper vapor
upper vapor
#

np

soft turtle
#

Is it possible to simply send empty dummies to ClientConnection, or does it necessarily have a ReferenceHub, etc.?
I just need the Ragdolls to stand

soft depot
#

Just fake the existence of the dummies client side (bad idea) Trolley

restive turret
unique crane
#

you wont get it any cheaper

soft turtle
unique crane
#

Its 3 dummies ๐Ÿ˜

#

not the end of the world

vast wharf
#

Someone exited the pocket dimension, and teleported him to a custom zone i have close to surface, how can i avoid this? is there any way to patch the TP?
(I circled where it teleported him)

unique crane
vast wharf
#

between surface and light would work?

unique crane
#

I mean moving it a bit to the left would do the trick

vast wharf
#

because there is a point horizontally that players stop moving and items dont appear

#

oh ok, thanks

royal mica
#

is there an event where a location is selected for teleport?

#

maybe could hook into that and override when it is in range

#

(though that is way harder and nuanced)

upper vapor
#

exitingpocket or something

#

but you can patch Scp106TeleportLocationFinder or something

#

locationfinder

royal mica
#

would be an interesting patch to MER (or whichever map thing ppl use) to create marker zones (like in Source engine) for blocking OR including zones

vast wharf
#

how?

upper vapor
#

spawn a WaypointToy or use the map editor of your choice to create one

vast wharf
#

would that also avoid the nuke killing all the players there?

upper vapor
#

not really..?
i thought that bug has been fixed already

vast wharf
#

i didnt test the waypoint but if you are far enough in surface not yet where it bugs but you cant see the skybox it does

thin shuttle
#

or make a check of Y level in case of it

upper vapor
thin shuttle
#

was it made when Surface zone level got changed ?

#

14.0.3-release-beta-a5da2001

unique crane
#

14.0 changed it

thin shuttle
#

right ?

unique crane
#

I honestly

#

kinda dont care

#

14.0 it was

#

probably incremeneted during patreon/public beta

thin shuttle
thin shuttle
#

instead of modifying the const

#

they changed code

#

noice

#

oh yeah that was the missing roundend field

#

round couldn't end

restive turret
#

It isn't really matter tbh

thin shuttle
#

was a the first release for LabAPI

thin shuttle
#

i have a friend that got angry at me because i read some dm we have with her today

#

i found that funny nostalgia

#

but she really didn't like it

vast wharf
#

anyone knows possible causes of the server restarting at the end of a round after like 4 rounds?

restive turret
#

You set it inside gameplay or LA

vast wharf
#

it's disabled

restive turret
#

Then check your LA logs

vast wharf
#

ohh it's a plugin of mine sending hints just when the round fully ends

silk prawn
#

Could someone help me because I made Raycast and it detects only one Schematic but it doesn't detect others and I'm confused

icy knoll
silk prawn
icy knoll
silk prawn
# icy knoll im confused then, as this message doesnt specify exactly what you want
Transform transform = player.ReferenceHub.PlayerCameraReference.transform;

Ray ray = new(transform.position, transform.forward * 0.1f);

int layerMask = 1 << 9;

if (!Physics.Raycast(ray, out RaycastHit hit, 7f, layerMask))
{
    Logger.Debug("Nothing found");
    return;
}

That's the part of code I'm talking about because it checks for the name of hit.collider?.transform.parent?.gameObject.name
and later must do something if the name is in Config

#

Yea i wrote it wrong before

icy knoll
#

instead of parent

silk prawn
#

okay I will try

silk prawn
carmine prawn
#

Players can only move normally within waypoint coverage

carmine prawn
vast wharf
#

But I will add the waypoint myself I think

hearty shard
#

hmmm

upper vapor
worn gull
upper vapor
#

skill issue TrollDespair

vast wharf
#

should i create the waypoint when the plugin enables or at the round start?

upper vapor
#

on waitingforplayers

vast wharf
#

ok

silk prawn
upper vapor
#

the one you highlighted?

#

might be a map editor issue

silk prawn
#

oh

#

so there's no really way to make it work ?

upper vapor
#

ummmm

#

could you log the components on the hit object and the name of the object?

#

string.Join("\n", hit.collider.gameObject.GetComponents<Component>().Select(e => e.GetType().FullName))

icy knoll
upper vapor
#

#if DEBUG

#

problem solved

icy knoll
#

forgot the #endif

#

plugin no longer builds in release

upper vapor
#

no it's still going

#

this chat is now in debug mode

#

and who said they will build in release

icy knoll
#

You'd probably kill them if they didn't build release versions in release

#

You threatened my life when I forgot to change to release mode

#

/j

upper vapor
#

a lot of people don't even know that release mode exists ๐Ÿ˜ญ

lapis steppe
#

am i stupid or am i stupid

#

send help

sweet flax
#

You are not referencing assembly csharp

lapis steppe
#

thats why im confused

#

did i mess up the project setup

#

i swear if it is because im using .net 8.0 instead of 4.8 im gonna lose my mind

lapis steppe
#

wait

upper vapor
#

"Because newer" what ๐Ÿ˜ญ

lapis steppe
#

48 works 4.8 doesnt

#

thank you

upper vapor
#

Welcome to .net frameowrk where nothing makes sense

lapis steppe
upper vapor
#

That's not how unity does stuff unfortunately

lapis steppe
#

wait nope it still doesnt work

#

im

#

im

#

rahhh

upper vapor
#

Did you... add the reference?

lapis steppe
#

still cant find it

upper vapor
#

SCPSL_Data/Managed

lapis steppe
#

and going back to 4.8 broke a bunch of other stuff

#

reeeeeeeee

lapis steppe
upper vapor
#

Np

lapis steppe
upper vapor
#

Edit the csproj
Put <LangVersion>12</LangVersion> in a property group

lapis steppe
upper vapor
lapis steppe
#

ty

upper vapor
#

Np

lapis steppe
#

lol i broke steam

#

thanks for the help tho

pulsar locust
lapis steppe
pulsar locust
#

dotnet also has better support for embedding compared to framework

lapis steppe
#

huh

upper vapor
lapis steppe
#

i was so confused because it didnt let me make the project in 4.8

#

so i didnt expect just swapping the versions to work

#

never had to do it before either tbh

#

good to know tho

#

also didnt help that the doc didnt mention that i had to get the assembly from the files

upper vapor
#

wiki will be updated with a proper setup guide at some pointโ„ข

lapis steppe
#

๐Ÿ™

upper vapor
#

misleading things:

#
  • a lot of phrasing
  • visual studio
  • visual studio being "easy to use and intuitive"
  • you must install .net frameowrk 4.8
lapis steppe
#

i had 4.8 it just didn't let me create the project with 4.8

#

it does say you need 4.8