#plugins-dev-chat

1 messages Β· Page 16 of 1

hearty shard
#

you cannot send the spawn msg to the dedicated

#

lmao

upper vapor
#

yeah um

#

yep

#

that makes sense

#

it shouldn't have taken this long though 😭

hearty shard
#

also fuck PickupCreatedEventArgs

#

that shit does NOT work for what i need

#

and theres no alternative

#

πŸ’€

#

Exiled patches ItemDistributor.CreatePickup for the event

#

and that worked for me

#

maybe i just gotta patch that too ig

#

well

#

actually no

#

hm

#

idk

#

even when i throw it, same issue so wtf

#

is the event not working

worthy rune
#

what are you trying todo?

restive turret
#

Worked for me teheehe

hearty shard
restive turret
#

Ah nice so scale things work

hearty shard
#

the event only calls for basegame ones

worthy rune
#

strange

restive turret
#

Then subscribe to once in InventoryExtension?

hearty shard
#

like im throwing an item

#

and it doesnt log anything

hearty shard
restive turret
#

PlayerDroppedItem

hearty shard
#

2 events πŸ’”

restive turret
#

Just call underlying method with your serial

#

Also droppeditem won't trigger when player died

worthy rune
#

theres ItemPickupBase.OnPickupAdded but that should be equivilant to the labapi PickupCreatedEvent

restive turret
#

And drops is item

worthy rune
#

i see the issue, its becuase the wrapper is created and cached before the event is called

hearty shard
#

bwa

worthy rune
#

this should work, not sure when the next patch is happening tho could be awhile

/// <summary>
/// A private method to handle the creation of new pickups in the server.
/// </summary>
/// <param name="pickup">The created <see cref="ItemPickupBase"/> instance.</param>
private static void AddPickup(ItemPickupBase pickup)
{
    try
    {
        if (!Dictionary.TryGetValue(pickup, out Pickup wrapper))
            wrapper = CreateItemWrapper(pickup);

        ServerEvents.OnPickupCreated(new PickupCreatedEventArgs(wrapper));
    }
    catch(Exception e)
    {
        Console.Logger.Error($"Failed to handle pickup creation with error: {e}");
    }
}
hearty shard
#

πŸ’”

upper vapor
#

will the public beta be extended to wait for labapi fixes?

worthy rune
#

subscribing to ItemPickupBase.OnPickupAdded will work how it supposed to tho

hearty shard
#

cool

worthy rune
upper vapor
worthy rune
#

most things are fixed done already just not merged

upper vapor
#

"labapi 1.0.0 has been released with 14.1! it only contains 42 bugs!"

upper vapor
hearty shard
restive turret
#

I mean you probably using exiled so why not use exiled events

hearty shard
#

im not using exiled

restive turret
#

Then wth us CustomItem cus its aint mine

hearty shard
#

its mine

restive turret
#

Guh

hearty shard
#

erm

#

i gotta fix smth

#

πŸ’€

restive turret
#

Lmao

hearty shard
#

it falls through it

#

and idk the fix rn

#

skull

restive turret
#

Skill issue

hearty shard
#

fak u!!

restive turret
#

I just parent the light to pikcup

worthy rune
#

^

restive turret
#

I prev just moved the light to coords

#

Also why when you use an item the light moves back & forth?

#

I parented to the player

worthy rune
#

huh

hearty shard
#

thats not the issue

#

its falling through the pedestal

#

because pedestals dont properly spawn until door opens

restive turret
worthy rune
#

i dont remember seeing anything like that

#

will try it later

hearty shard
#

should i just make it isKinematic when i spawn it

#

hm

worthy rune
#

i thought you parented the light?

hearty shard
#

im talking about the pickup

#

the pickup goes through the pedestal

worthy rune
#

something isnt right here

hearty shard
#

thats the issue

#

cuz pedestal doesnt get spawned in fully

#

until room is opened

#

so im asking if isKinematic = false can do the job

worthy rune
#

you must be offsetting the light, since the position is client sided it should be where the item is visually

hearty shard
#

pls re-read

worthy rune
#

also pickups should be kinematic anyway

hearty shard
#

its the item itself

hearty shard
#

default prob

worthy rune
#

yeah i know about the room stuff, and im pretty sure the game does what you are saying

hearty shard
worthy rune
#

a pedestal is a locker with one chamber

hearty shard
#

i just spawn em in the locker position

hearty shard
worthy rune
#

oh your replacing the pickup with your own?

hearty shard
worthy rune
#

ic

hearty shard
#

oh btw

#

i might rework my thing to use a prefab kinda style like basegame

#

so each CustomItem only controls its own single item instance

#

would that be a good idea to use the unity prefab kinda style for it

#

not sure how easy it is in plugins

worthy rune
#

maybe, i might be biased since i hate the singleton manager style ones

hearty shard
#

wdym

#

like what exiled does ?

worthy rune
#

yes

hearty shard
#

its the same im doing rn

#

i do wanna change it

worthy rune
#

lol

hearty shard
#

for items and roles

#

just havent bothered yet

upper vapor
#

you mean components that control the specific instance? i support that

worthy rune
#

you gotta have some manager somewhere i just dont like it being the main way to implement custom items

hearty shard
#

now uh

#

where is kinematic property

#

i forgot

worthy rune
#

on rigidbody

hearty shard
#

oh

#

lol

restive turret
hearty shard
#

for now its this

#

oh yeah

#

my CI doesnt work anymore

#

cuz exiled is gone

#

😭

restive turret
#

Womp womp

#

(same)

icy knoll
#

exiled works for me

#

lol

hearty shard
#

(you dont)

icy knoll
hearty shard
#

this has the references for CI?

icy knoll
#

chaos insurgency

hearty shard
#

no maam

#

so yeah my CI will be broken

icy knoll
#

smh

restive turret
#

If u replace that it will work

hearty shard
#

there is none public rn tho

#

and im too lazy to make one rn

hearty shard
#

im gonna kill u

worthy rune
restive turret
#

Huh

#

I need to record it

hearty shard
restive turret
#

Its really small movement si

worthy rune
restive turret
#

i have a few question.
song?
nice panel is that public?
thats funny

worthy rune
#

Thomas Bergersen - Memoria
SSS panel is not public yet

unique crane
#

Riptide cooked on that one

#

πŸ”₯πŸ”₯

hearty shard
#

david

restive turret
#

ye panel looks great

hearty shard
#

can we cook you

unique crane
#

Testing stuff is much easier

worthy rune
#

lmao

unique crane
#

I think I'll be cooked enough by that

hearty shard
#

not enough

unique crane
#

Lay on sand with no shadows nearby

#

Then say something

restive turret
#

I swear it moved

#

and cant replicate it

hearty shard
#

is this schizophrenia

agile oasis
#

for some reason RigidBody doesn't work, making primitive to stay in a air, RigidBody applied on parent game object, not on primitive itself.

#

don't know what is blocking code snippet there, but here is code part

icy knoll
#

or enable

#

i cant remember

agile oasis
#

I try, thank you

upper vapor
agile oasis
#

well, i've tested in unity itself without collider, it should work

#

will add after figure out why there no movement

upper vapor
#

you've set the toy to static

#

that's fine

#

but you need to sync the transform properly

#

hold up, this is the wrapper

agile oasis
#

yes, sorry didn't mentioned, I am using wrapper for creating primitive

upper vapor
#

it should've occurred to me from the code lol

#

anyways, you need to use the local transform when setting admin toy transform properties

#

so localPosition goes to Position, localRotation goes to Rotation and localScale to Scale

#

you already have those as parameters so you can use them

agile oasis
#

yes, I am using transform of parent which is spawned on global coords and set on localPosition and localRotation to zero, so it spawns correctly, the only thing there are no movement

agile oasis
upper vapor
#

you're creating an empty game object

#

it's not possible to parent toys to an empty object outsideor within another empty object

#

each parent needs to have a network identity

#

i'm not sure why you need that offsetPoint object, but don't parent the toy to it
parent it to the transform of the gameobject itself

#

@worthy rune could you add some sort of error log if the parent changes to an object that doesn't have a network identity?

#

cuz it might be confusing for new devs

upper vapor
#

your best bet is to create an invisible colliderless (PrimitiveFlags.None) game object as a parent

#

that means you can move the parent, too

upper vapor
teal junco
#

I usually just use a dictionary of serials and a model i make representing the item stuff I want

#

I guess I just got used to this way of thinking, the singleton item managers dont bother me in the slightest

#

neither do the customroles

upper vapor
#

well, singletons are more so meant for single objects, not for multiple ones
i mean yeah you can store the state in a dictionary
but if you have a component attached to a gameobject, it'll clean its state up

#

it means more allocations though

tulip kiln
#

Bumping this. People complain about binds not working between servers on the same network awokado_kek

upper vapor
#

i think a safe approach would be to prompt players to reuse settings if they've modified the settings on the same ip but different port

#

this would all be client-side

worthy rune
worthy rune
worthy rune
icy knoll
icy knoll
#

oh

teal junco
#

or are they just some people dont like them

agile oasis
#

@upper vapor ok, I figured out that for some reason Rigidbody works only for these primitives and not for gameobject which groups them. Strange, because vanilla unity allowes me that

faint sparrow
#

!status

regal lakeBOT
upper vapor
# agile oasis <@435474959595208704> ok, I figured out that for some reason Rigidbody works onl...

Adding a Rigidbody component to an object will put its motion under the control of Unity's physics engine. Even without adding any code, a Rigidbody object will be pulled downward by gravity and will react to collisions with incoming objects if the right Collider component is also present.
the docs say you must have a collider along with a rigidbody, are you sure the vanilla unity thing didn't have one?

agile oasis
white matrix
#

@restive turret remember how I brought up that one can add \n to descriptions? Yeah no that doesn't work like I want it to don't forget to add # in front or it won't be commented out.

lethal cradle
#

greetings nerds

white matrix
#

Hey so uuuh

#

you should be able to disable DMS right?

#

like in server config?

#

Why does it not work?

#

also how is the game suddenly deciding to spawn a Chaos Miniwave when the only team that had a Token and spawned (Ntf) didn't..?

#

like I find this particularly weird, only ntf had spawned, nothing else had any tickets, milestones or tokens, and it spawns a chaos miniwave

#

additionally, I used the admin panel to disable DMS and it did not actually do that. It still went off.

agile oasis
white matrix
#

however.. why the flip does it still run DMS when it's disabled?

#

like I disabled DMS in the admin panel and server config?

white matrix
#

I'd like to make something to set minimum spawn wave size for main waves and mini waves, but idk what determines when a team spawns because that'd need to be modified. I can't find the function. I wouldn't be surprised if I'd need to Patch it either.

restive turret
#

MaxWaveSize

#

WaveSizeMultiplier

nova cosmos
#

Hello, are there api functions to get the local and global config directories? I will just build the paths myself for now but I would like to use ones that automatically update when the api changes things up.

agile oasis
nova cosmos
#

what is that?

icy knoll
agile oasis
nova cosmos
icy knoll
nova cosmos
nova cosmos
white matrix
# restive turret WaveSizeMultiplier

Can I also use that for minimum size? So wait with spawning until a certain amount of spectators are met? In our lobby so small we keep having 1-2 people waves wasting tokens when waiting a little bit would be fine, so I wanted to make something for our server to set a minimum, but idk how to set that as it'd mean I have to interrupt the spawning of the team until enough people are spectator before I allow it to select (which I reckon requires a patch)

fresh zenith
#

Would be my implementation

grand flower
#

Made a PR for the CustomDataStore

#

It currently doesn't support checking if a data store exists on a player

#

GetOrAdd() would simply add it

unique crane
#

Until you have enough players

white matrix
unique crane
#

Property IsAllowed

white matrix
#

Oh awesome I'll take a gander at this

upper vapor
unique crane
#

This is what you might be looking for?

nova cosmos
#

sort of, I need to be able to get both the port and global ones seperately

unique crane
#

Yeah thats why the isGlobal parameter exists

nova cosmos
#

oh nvm I am blind

#

where is that function?

unique crane
#

ConfigurationLoader

nova cosmos
#

oh and it even adds the plugin dir

#

very nice

ashen hound
ashen hound
#

hard very much

upper pike
#

Stealing this

upper vapor
unique crane
#

Feels the same for me

unique crane
ashen hound
#

I mean yeah we can add some stuff to wrappers

#

I used just base game methods

#

just make like KeycardItem can check if has permissions to some door idk

unique crane
#

Yea

icy knoll
unique crane
#

Same code, you just replace the door with locker

ashen hound
#

yeah just showing example as door thing

#

I not making plugin

upper vapor
ashen hound
#

xdd

nova cosmos
#

is it possible to get breakpoints working when debugging plugins?

nova cosmos
#

this doesnt stop on breakpoints when I try to run it

#

also tried running then SCPSL.x86_64 binary directly but I cant get it to work

upper pike
#

Don't think you can

#

How would that work anyway

nova cosmos
#

yes that is my question

#

I would assume running the scpsl binary directly would fix it but I cant get it to work properly

#

it just dies immediately

grand flower
#

Probably doesn't like you attaching a debugger to it

nova cosmos
#

no I have only tried running it without a debugger so far

grand flower
#

Although if there's a way I'd love to know

unique crane
#

Not sure.. but you might need the debug symbols for the Assembly-Csharp too?

#

Never tried this tbh

grand flower
#

Probs won't be possible, might also be Unity not letting you debug it since it's a released build

#

Most engines kick your debugger out for non-dev builds

upper vapor
#

i've tried to attach a debugger to the SL process
it died

nova cosmos
#

very strange

grand flower
#

SL client will probably nuke you from orbit if you try to debug it :^)

nova cosmos
#

I would have assumed the debugger just wouldnt show any information about the rest of the binary

#

well thats incredibly annoying

#

I have the strangest issue

#
HttpWebRequest request = (HttpWebRequest)HttpWebRequest.Create("https://steamcommunity.com/profiles/76561198022373616?xml=1");

This doesnt work because apperently the uri prefix is unsupported

grand flower
#

Makes me wonder if Northwood could provide a server build with debug stuff enabled for plugin devs

nova cosmos
#

last time I checked https is pretty supported

grand flower
#

Why aren't you using HttpClient

nova cosmos
#

I dont know

#

this is like 6 years old code

grand flower
#

Switch to .NET's HttpClient class

#

Probably a lot better than Unity's

nova cosmos
#

this is dotnet

grand flower
#

Oh nvm that is .NET

#

Got it confused

unique crane
#

Unity's work with coroutines

#

thats the point of it

nova cosmos
#

in any case, this has worked for years but stopped recently for some reason

unique crane
#

cuz no async (until now?)

unique crane
grand flower
#

Unity's async is so weird I don't wanna touch it anyway

nova cosmos
#

I used the exact same line in the bot and it works but of course thats dotnet 9.0

grand flower
#

Are you sure it's whining about the URI prefix

#

Because https is apparently supported

nova cosmos
white matrix
white matrix
#

shouldn't be hard to add if it's not the right event but still worth confirming

static osprey
#

Logger.Error

ashen hound
#

I think gen events etc ahould have same rhing

white matrix
grand flower
#

works fine on .NET 4.7 so idk what's up with yours

ashen hound
#

You will need to change some stuff

nova cosmos
grand flower
#

Honestly just switch to HttpClient

#

Microsoft considers HttpWebRequest obsolete anyway

nova cosmos
#

I'll try that, thanks

nova cosmos
grand flower
#

Yeah it's just what I could try with an online compiler

#

Also tried 4.8 and it worked fine

nova cosmos
#

ah ok

grand flower
#

As well as latest .NET so idk what's wrong

stuck peak
# nova cosmos also tried running then SCPSL.x86_64 binary directly but I cant get it to work

copied from Exiled's discord, but you aren't in it anymore:

Step by Step debugging

You want to do step by step debugging!

Setup

Note:

Maybe, do a copy of your server. To recover if you make a mistake or want to go back.
You can download your self or just take attached files.
Only server modification, DO NOT TOUCH THE CLIENT! Server, is where the Steam is install not EXILED.

Check if you Visual Studio / IDE as the extension for Unity Dev.

If not install it.

Download the Unity 64-bit, version: 2021.3.17f1. Different version now, but the rest applies the same
Unpack the executable using Winrar or 7zip.
[ExtractedFolder]\Editor\Data\PlaybackEngines\windowsstandalonesupport\Variations\win64_development_mono\

Take UnityPlayer.dll and replace the one found at the root of the server.
Take WindowsPlayer.exe place it at the root of server, delete SCPSL.exe, rename WindowsPlayer.exe to SCPSL.exe.

You can delete UnitySetup64-2021.3.17f1.exe and the extracted folder.

Go to [Server root]\SCPSL_Data\boot.config, edit it and add:

wait-for-managed-debugger=1
player-connection-debug=1

Debug

Place break point in your code. Build and place the dll in server ...
Start the server... A windows will open which will suggest you attach your EDI. Go to or EDI and attached it.
For Visual Studio (min 2019):
Go to Debugging > Attach to Unity > Select Project call "Debug" > click Ok.
Go to the windows open by the server and click Ok.
Disable the auto crash restart: HBCTRL disable

When a break point is trigger, you can inspect the value of instant. Durring run time you can add other break point. The modifications that you will make in your code are not taken ! You need to restart...

Disable the Debugging

Go to [Server root]\SCPSL_Data\boot.config, edit it to:

wait-for-managed-debugger=0
player-connection-debug=0
grand flower
#

@stuck peak made a new PR targetting your branch instead of master πŸ‘Œ

#

makes more sense yeah hah

stuck peak
#

sounds good I was just about to ping you lol

nova cosmos
grand flower
#

I wrote a quick extension method that uses reflection to do the same so I figured I might as well try to get it in LabAPI :^)

stuck peak
grand flower
#

oooooh

#

that sounds amazing, ty

icy knoll
stuck peak
#

it doesn't list half the channels and I don't think I can put ids in

icy knoll
#

easy

stuck peak
#

ah I see thanks

icy knoll
stuck peak
#

north wood studios

white matrix
#

So I've been trying to alter spawning conditions a little bit for both the vanilla teams, however I can't quite figure out how to check before the animation starts playing, as when I for example cancel a wave spawn I'd like to not notify all the chaos with the spawning music

upper vapor
#

oh wait nvm

#

WaveTeamSelectingEventArgs

#

it doesn't pause the timer though

hearty shard
white matrix
upper vapor
#

ye

white matrix
#

I'll give that a shot later, thanks for the input.
I'm trying to only spawn waves once a certain % of the lobby is spectator to 1. not waste tokens and 2. not make the waves so small they're basically not worth the 5min wait

#

so being able to toss a wave without the animation playing means I can do a bunch of logic behind that

fresh zenith
#

uh what is the publicbeta called? my server can't get the image lol

upper vapor
fresh zenith
#

k thx

#

i was wondering

#

i thought it might be different

unique crane
#

or early-server-build

#

they are the same build currently

fresh zenith
#

oh okay

static osprey
#

anyone know of a way to get RA role name?

restive turret
static osprey
#

i think thats class roles

#

but anyway i got it

hearty shard
#

oh

#

you mean

static osprey
hearty shard
#

permission group

hearty shard
fresh zenith
#

question: "foreach (ItemBase item in invInfo.Items.Values)" gives me all items the player has. but if the player has an item in the hand it won't return this one?

upper vapor
#

items also includes the currently equipped item

fresh zenith
#

hm. maybe just an bug in my code lol welp deuggigigiging

upper vapor
#

did you build and copy the dll?

#

(happens sometimes Kek)

fresh zenith
#

ofc i did

#

well it gives me the item yes but i can't get the permission from the keycard lol

#

(just added like 3 more Loggers for debugging)

upper vapor
fresh zenith
#

oh i might found the error lol

#

used the wrong Event.

upper vapor
fresh zenith
#

yea.... it took me like 30 minutes...

#

(and i was wondering why ev.CanOpen was only an get; bool ....)

hearty shard
#

😭

fresh zenith
#

well works now.

obtuse spruce
#

labapi didnt provide any support to change player Scale ?

upper vapor
#

nope, that's still in the works, or at least not public atm

obtuse spruce
#

Okay that why i got so much issues when i change the scale via the old method

upper vapor
#

yup

#

firearms just die

obtuse spruce
#

Yea

#

And Tesla too

#

Tesla stay in idle mode as what i see

upper vapor
#

that's interesting

obtuse spruce
#

let me check

#

Yea tesla stay in idle mode

upper vapor
#

we got it for ragdolls but not players 😒

obtuse spruce
true cedar
hearty shard
true cedar
#

wait wheres the 14.1 doc

hearty shard
# true cedar wait wheres the 14.1 doc
true cedar
#

very cool

obtuse glade
#

question, what dll references do you need in your vs project for a plugin?

static meteor
obtuse glade
#

alr thanks for the help

#

its essentially the same as the nwapi

hearty shard
#

yeah no difference

#

just Nwapi -> Labapi

#

thats the difference in reference

round vale
#

How can i remove a coin after being used, cuz like when I used the northwood api, it would glitch

static meteor
#

FlippedCoinEventArgs If I remember correctly

#

Then do ev.CoinItem.Remove() I think

#

Idk haven't really messed with this event much

restive turret
#

Remove or destroy.
But wait atleast .1f to do

#

Timing.CallDelayed(0.1f, () => ev.Player.RemoveItem(ev.CoinItem));

obtuse glade
#

where is the MEC reference though?

round vale
#

also is there a way to turn lockdown and overcharge?

restive turret
obtuse glade
#

nvm

#

found it

#

😭

restive turret
#

:sob

round vale
#

cuz server runcommand doesnt work

upper vapor
#

you can decompile those commands and see how they work

#

but LabApi wrappers should let you do that

#

Facility.SomethingSomething this was from NWAPI

restive turret
#

Yes

#

Exactly that parameter

worthy rune
#

i dont think we have anything for overcharge iirc

upper vapor
#

Map.TurnOffLights

round vale
#

yeah but thats just for lights

obtuse glade
#

i think you can just "simulate" an overcharge essentially

#

and just play the cassie alert

#

and make it look like it is an overcharge

worthy rune
#

lmao

upper vapor
worthy rune
#

only unique thing in Map is the seed property everything else is just loops and random stuff which is kinda useless imo

upper vapor
restive turret
#

But that's funny

worthy rune
#

ngl i want to delete it

upper vapor
#

note that it'll also try to kill 079

restive turret
#

Skill issue SteamHappy

upper vapor
restive turret
#

Or just check how the RA console command works

restive turret
upper vapor
#

indeed Despair

#

when zone but no zones

#

i'M not even sure which door overlaps two zones even

restive turret
#

Well

#

First one will be selected

#

Which is random

limpid fjord
#

Can't play custom text on CI key card?

upper vapor
#

you can play custom pixels

limpid fjord
#

I need that

#

I want to play bad apple

upper vapor
#

just render the text shrug

upper vapor
limpid fjord
#

What functions can I use?

upper vapor
limpid fjord
#

SnakeDisplay?

#

SnakeEngine.UpdateDisplay(SnakeDisplay, bool)?

upper vapor
#

that's client-side

#

use ChaosKeycardItem::ServerSendMessage

limpid fjord
#

ChaosKeycardItem.ServerSendMessage(SnakeNetworkMessage)

upper vapor
#

it's funny how your name is anaconda toomuchtrolling

limpid fjord
#

love you

hearty shard
#

ages ago

#

πŸ’”

#

ur just copying me ngl

#

Delete Map.cs
move Seed to Round.cs

#

problem solved ngl

upper vapor
restive turret
#

Nice

#

Round.deez

hearty shard
#

....

#

ur not funny

#

ur banned

#

for unfunny

upper vapor
restive turret
limpid fjord
#

just an snake game

carmine prawn
#

simple question, how can I know if a jailbird attack type is a sprint?

#

use OnPlayerHurt

upper vapor
#

check the jailbirddamagehandler

upper vapor
unique crane
#

Didnt know its per-pixel

#

I though it was just sprites

upper vapor
#

idk either 😭

#

i'm just guessing

limpid fjord
#

nope...

#

It doesn't work even with HarmonyPatch

#

Is the Snake game handled on the client side, meaning the server can't directly control or render what appears on the Snake display?

upper vapor
#

i've heard that someone's already made bad apple in snake

limpid fjord
#

Π ΠΠ—Π’Π•Π ΠΠ˜ ΠžΠŸΠ˜Π‘ΠΠΠ˜Π•

β–°β–°β–°β–°β–°β–°
| Бсылки:
| DIscord [SCP:SL Classic] - https://discord.gg/jyPAcwePez

β–°β–°β–°β–°β–°β–°

Мой Π΄Ρ€ΡƒΠ³ Griefer вновь ΠΎΠ±Π΅Π·ΡƒΠΌΠ΅Π» ΠΈ Π΄ΠΎΠ±Π°Π²ΠΈΠ» Π² ΠΈΠ³Ρ€Ρƒ Bad Apple!!. На этот Ρ€Π°Π· Π½Π° устройствС Π²Π·Π»ΠΎΠΌΠ° ПΠ₯.

"Bad Apple!! - это Ρ‚ΠΎΡ‚ са...

β–Ά Play video
#

Is this it?

upper vapor
#

seems like it

#

no clue how it works

limpid fjord
#

This is client modding

restive turret
#

Or somebody green screened to it

upper vapor
icy knoll
#

client side mods

#

a lot of that stuff is

teal junco
upper vapor
hearty shard
#

this doesnt appear to work (the isKinematic)

#

unless Locker::Chamber position changed to be the bottom of the pedestals

carmine prawn
restive turret
#

get stuff from _moveDirection?

carmine prawn
#

nope

restive turret
#

well you can get the dmg

carmine prawn
#

if I changed it on other OnPlayerHurting πŸ’€

restive turret
#

well

#

good luck

carmine prawn
#

add AttackType on JailbirdDamageHandler plz

hearty shard
unique crane
#

?

#

Context

hearty shard
#

i spawn it in a LockerChamber

#

and set it as isKinematic true

unique crane
#

Aaaand

hearty shard
#

and it spawns in the bottom of the pedestal

#

like in the actual footing of it not the chamber

unique crane
#

Well do you set the coords of the spawn to the chamber

#

And not structure coords

#

since structures has coords starting at floor

hearty shard
#

return UseChamber ? locker.Chambers.GetRandomValue().Base.transform.position : locker.Position;

#

...

#

so should it be
return UseChamber ? locker.Chambers.GetRandomValue().Base.Spawnpoint.position : locker.Position;

unique crane
#

Print both and compare with the pickup coords

hearty shard
#

i cba to test rn

#

ill consider this the fix

unique crane
#

Hmm ok

hearty shard
#

didnt know that was a thing

#

i swear exiled didnt do that

#

or maybe i did make it like that

#

idk

unique crane
#

Β―_(ツ)_/Β―

static osprey
#

@unique cranemight you know if onplayerbanning is bugged or something?

#

its not firing for me

#

though onplayerleft is

unique crane
#

Nothing I would know of

static osprey
#

πŸ˜”

unique crane
#

Hmmmm

#

I can test in a bit

agile oasis
#

so this one

GameObject Parent;
void Init(Player player) {
Parent = new GameObject("Parent");
Parent.transform.position = new Vector(player.Position);

var toy = PrimitiveObjectToy.Create(Vector3.zero,
                Quaternion.identity, Scale, Parent, true);

Timing.RunCoroutine(Move());
}

private IEnumerator<float> Move()
{
  while (true)
  {
    yield return Timing.WaitForSeconds(1f);
    Parent.transform.position += new Vector3(0, -5f, 0);
  }
}

doesn't work

restive turret
#

cus that gmaeobject doesnt have network identity

agile oasis
teal junco
#

network identities have always been a thing

#

it essentially defines an object that the client will listen to the server about

#

14.1 added client side parenting

agile oasis
#

I am trying to understand why it stopped working , because on previous version it works fine, primitive changed its pos

teal junco
#

But the parent needs a network identity

teal junco
#

so the primitive is probably at 0, 0, 0

agile oasis
teal junco
#

yeah, so that the parent relationship can actually work client side

#

if there isnt a network identity, how is the client supposed to know what object to parent it to

agile oasis
#

so adding extra primitive to group and build everything on primitives...
But if I set flags for this "parent" primitive to be invisible and no collision, it also applies to child ones... How to handle it then.

teal junco
#

I dont think primitive flags apply to children

#

are you sure

agile oasis
#

I've checked, they applied

teal junco
#

that's unfortunate

agile oasis
#

Appreciate if there can be example to group primitives, so I can put a logic to group, instead of applying changes for each of them

#

Thats why it worked well before client started to check, maybe I miss something

teal junco
agile oasis
#

also if you set Scale to Vector3.zero, it applies to childrens too

teal junco
#

imagine if the primitive invisible flag actually disabled it instead of deleting the renderer SteamHappy

hearty shard
#

you need a NetworkIdentity on an object to parent it client side

soft depot
hearty shard
#

so uhhhhh

#

like a player

#

another admintoy

#

uhhh

#

what else has this

#

i forget

#

πŸ’€

teal junco
#

He claims the primitive flags inherit to childrenπŸ’€

teal junco
#

Item

#

camera

hearty shard
#

damn

teal junco
#

uh

#

idk bro

agile oasis
#

oh, sorry guys, my bad, flags do not inherit

#

feels like creating primitive works ok and I can depend on it

unique crane
#

elevator

#

Hmm what else has netidentity

teal junco
#

room and tesla?

hearty shard
hearty shard
#

except like

#

2

teal junco
#

TC

#

and i think testing room, at least it used to pre 14.0

unique crane
#

so yea

hearty shard
#

see

#

im smart

white matrix
#

hey uuuh why if my timer is paused on a wave, does the timer keep running? I have both wave's timer's paused right now and both are still going (granted, both being paused is not intended, but still)

#

nevermind I'm a dummy

icy knoll
#

waves that have no spawn waves will be paused also

white matrix
#

hold on I just fumbled something terribly I'm confsing myself a moment

icy knoll
white matrix
#

I'm trying to get the OnServerWaveTeamSelecting wave, and under a certain condition, pause all other timers, set the timer of ev.Wave to 30 and make it retry again in 30s

#

granted the code I'm trying to test right now isn't the greatest for that

#

I wrote this super tired earlier so I gotta rewrite it

#

but it's just not pausing at all

white matrix
#

like it's a paused timer, so I thought

#

why was it designed differently?

icy knoll
#

whilst making timers, i learnt this fact lol

white matrix
#

πŸ’€ buh

icy knoll
#

timer may be paused, but the time will still count down

white matrix
#

I truly do not understand why that was done that way

icy knoll
#

for me, it stopped at like 30 seconds or smth

white matrix
#

damn I guess I've got to find a way to preserve their current timer values then somehow huh

#

It makes no sense to me that that is how that works though.. I cannot understand how pausing a timer doesn't actually pause the timer

#

Is that an issue I can post somewhere? Because it to me seems very illogical that this works the way it does

white matrix
#

the API is just a way to interact with these features as far as I know, and thus if the API says 'pause the timer' the game is supposed to act accordingly, however the behaviour there is weird.

hearty shard
#

its official api

#

they can do changes to basegame

white matrix
#

I guess that

#

's a really good point

#

Should I mark it as an Idea or Task then? I don't really know what to do with the templates provided

restive turret
#

please let us make custom waves and be in sync πŸ™

white matrix
restive turret
#

ye everthing work

#

just would be better if things can sync

white matrix
#

I was going to probably use it soon

#

I kind of want to see if I can get Serpents to work

#

it'd be a fun challenge

#

I might split off one of the things I'm making right now into a separate plugin, or just rename what I have right now

marble cobalt
hearty shard
#

the RA

marble cobalt
#

The RA waves menu iirc gets built based on what is on the server

#

May be wrong though

hearty shard
#

i think it crashes client

#

but yes it does

#

probably

#

@restive turret knows more

marble cobalt
#

No yeah it does

hearty shard
#

but i think he said it crashes

#

or i rememebr wrong

restive turret
#

if you send packets for Custom Wave that isnt in basegame it crashes

#

since it getting non existing index

marble cobalt
#

That could be a bugfix you could request imo

hearty shard
#

also hii beryl

marble cobalt
#

Hello

restive turret
#

but prev the bug talked about (if I followerd right?) the client still counting the timer despite being paused

marble cobalt
#

As designed, waves still countdown even when paused/frozen unless they have like ~30s or less

#

don't remember the exact values atm

restive turret
#

oh ah

#

ncie to know

white matrix
#

but yeah a paused timer shouldn't keep running imo

marble cobalt
#

This was done because the timer gets paused while waves have 0 tokens

#

But balance-wise the waves would stay frozen with a full timer

white matrix
marble cobalt
#

Which sucked terribly gameplay-wise

white matrix
#

I don't see why a team timer should keep running if it's out of tokens

hearty shard
#

maybe rename it

#

from paused

#

to Delayed or smth

marble cobalt
#

iirc because it guaranteed it wouldn't spawn even if it achieved enough points

white matrix
#

and as someone who's trying to alter the respawning system, having something unintuitive like this is kind of annoying

marble cobalt
#

because the otehr team would always be ahead

hearty shard
#

just rename it tbh

#

thats the fix to this

#

(and ofc an actual pause for it)

restive turret
white matrix
#

😭 I still need a pause or I gotta figure out how to make something like that myself

#

I'm sobbing

white matrix
#

I'm so fucking close to having it all set up man 😭 SO CLOSE

#

all of it works except for this

#

I'm sobbing

hearty shard
#

trust

marble cobalt
marble cobalt
#

You can kinda see I tried making custom waves possible (Michal and I refactored the respawn scripts)

hearty shard
#

can you at least consider what i said ? rename Paused > Delayed

#

or smth

restive turret
#

I didnt even saw that before it got reworked

#

i just only seen when i worked on it like this week

marble cobalt
restive turret
#

yeah

#

deadlines is deadlines

marble cobalt
#

Its a difficult thing to balance, sadly

hearty shard
#

πŸ’”

white matrix
#

@marble cobalt do you mind if I at least bring it up on the Github Issues page? Even if it gets shot down, you guys at least have an issue to refer to. I wouldn't say it's super high priority, I think I can just work around it by altering TimeLeft in some super shoddy and finnicky way, but it'd still be quite the improvement if implemented imo

icy knoll
white matrix
#

there are no issues with the word Pause in the title yet on the LabAPI Issues page

marble cobalt
marble cobalt
#

So any new programmer unfamiliar with the respawn system who gets asked by game design to change the pause mechanics, or pause here or there

#

They can easily search the word "Pause" in the respawn scripts and find what they need

restive turret
#

also fun seeing SCP have objective but not used

marble cobalt
#

You as plugin devs also benefit from this because if we say "pause" in the changelogs, you know which parts of the script we're referring to

#

Or which game mechanics may be affected

hearty shard
#

aye aye aye

marble cobalt
white matrix
marble cobalt
#

Like, its not necessarily difficult its just, as you said, its not the highest priority

restive turret
#

highest priority is [REDACTED]

hearty shard
#

Ur leaking

marble cobalt
white matrix
white matrix
#

I'm not that githubpilled unfortunately

#

mfw first year of cs and kinda just doing some stuff I find interesting and fun

restive turret
#

I did many stuff that find me interesting so

#

(Thats why I have 74 github repo )

white matrix
#

I have a couple so far but most of them private for like random things I'm tinkering with

#

I just like learning

#

but like if I'm making a configurable respawn system overhaul plugin I might as well make it public

restive turret
#

its good to see how much did you developed your coding skills

white matrix
#

my coding skills aren't really that developped

#

I just start typing and eventually the bugs are fixed and it works

restive turret
#

me who started as batch script

white matrix
#

for someone who likes mathematical proofs, I'd assume I'd be more rigorous with my software but alas

white matrix
#

was bored in high school so instead of paying attention to class I started learning python

#

it all went downhill from there

#

good shit

restive turret
#

wehn I was 12 I even did minecraft command block "programming"

#

😭

white matrix
#

I mean modern datapacks can be quite interesting

#

man..

#

I'm a bit bummed out now

restive turret
#

i learned c# by looking code in github

white matrix
#

until the timer is changed, which for now I'm assuming is never

#

I will need to find a workaround for this

#

it's quite frustrating ngl

restive turret
#

was funny af how I literally learned C# by just looking and understanding code in gh

white matrix
#

honestly

true cedar
#

i think that's how like

white matrix
#

I learnt basic python syntax

true cedar
#

most people learn

white matrix
#

started typing

#

at one point looked up C# syntax

#

started typing

#

it clashed a lot with my brain at first, having a static typing language when only having experience with dynamic

#

but nowadays I work with python as if it's dynamic

restive turret
white matrix
#

and then I'm teaching friends introductory programming I'm basically just making them do static typed python, because python is easy to read and quite flexible, has a lot of docs and whatnot

true cedar
#

code tutorials are useless

white matrix
#

but the dynamic typing is so confusing

white matrix
restive turret
#

yes I know

white matrix
#

there were a whole bunch of people who had to learn Java from scratch by the supplied course

restive turret
#

im in like my 3rd year

true cedar
#

like if its an introductory programming course

#

you shouldn't be surprised when people don't know programming

white matrix
#

I know

#

I mean it was mandatory for everyone, even the people with previous experience

#

but for some reason I've seen people accept the stereotype of 'all cs students have programming experience before they start'

restive turret
#

me who joined at CS with like 2yr of experience of programming (or more if we count scratch, MC command blocks)

white matrix
#

I just type man

#

I just type

#

because if you ever see some of the shit I've made

#

the structure is.. not great

#

even more modern stuff I'm not particularly proud of

restive turret
#

i mean my code was shit too so

true cedar
#

well now u know that what u made isnt great

#

so u learn what not to do

white matrix
#

a little more sl related; once a wave spawns, all other timers are changed right?

#

the spawned wave's timer goes to default, the others do what exactly?

white matrix
#

also mini waves; are they required to have tokens or not? because they have a running down timer too, however I've noticed one spawning without having a token before

#

could be because of broken things in the background though

white matrix
#

because then I've found an easy temporary workaround for what I'm doing here

restive turret
#

to 0? and starting counting down again?

#

it goes back to some value

#

idk what exactly

white matrix
#

I mean I am trying to implement a minimum % of the lobby needs to respawn for a wave to go off

#

if it cannot delay the wave by 15-30s then try again

#

but if a wave spawns and it resets all other wave's timers

#

then that would mean that I can just do this for all other waves wave.TimeLeft += wave.TimePassed; // reset timer to default.

#

but that might not work

#

I'd have to double check if TimePassed is truly what I think it is

#

after the entire timer pause debacle I am doubting and double checking for a short while I reckon

#
Logger.Debug("Resetting all other team timers.", RTOPlugin.Instance.Config.EnableDebugLogging);
foreach (SpawnableWaveBase spawnableWaveBase in WaveManager.Waves)
{
    RespawnWave wave = RespawnWaves.Get(spawnableWaveBase);
    if (wave is null)
    {
        Logger.Debug($"\tRespawnWave {spawnableWaveBase.TargetFaction} | {spawnableWaveBase.GetType()} is not a RespawnWave.");
        continue;
    }
    wave.TimeLeft += wave.TimePassed; // reset timer to default.
}
evWave.TimeLeft = 15;  // Will try again in 30 seconds.
evWave.PausedTime = 0;
``` something like this to delay the respawn and reset the other timers.
#

alright imma try this

#

and hope it works

#

that or I'm throwing a fit

#

going to straight up babyrage

#

and do something else for the day casper64SheppyGamer

#

I've had a long one

#

yeah no it does some weird ass infinite loop.

#

I'll just fix it another way

#

holy shit I think I've got it to work without pausing but it's such a wacky fix

agile oasis
#

is saving hypothermia effect after death is a known bug ?

hearty shard
#

might be plugin bug

white matrix
#

@restive turret @hearty shard

#

It did not paste my pings

#

anyways I'm going to take a fucking break now

restive turret
#

will look at it while i eat

white matrix
#

have a nice meal :D

#

I thought I'd give it a shot

#

I mean I primarily made it for my own server, but might as well release it

restive turret
#

Instead of using Player List use Player ReadyList

teal junco
#

is readylist cached or something

#

idrk what context this is

grand flower
#

Is there a way to hide global tags of a player in favour of local ones

unique crane
#

You have badge preferences in menu

grand flower
#

That or maybe separating the global from the local tags

#

Since global tags can hide custom server tags that are used for gameplay

unique crane
#

To like force show the local one?

true cedar
unique crane
#

I feel like you should respect the preferences-

#

yea

#

It might violate it

true cedar
#

make it custom info

grand flower
#

I figured it might, kinda why I hope in the future they'll be split

#

Although I wish the rules would be hiding the global one for "no good reason"

#

If it's like a custom role or something I feel like that should be fair game

unique crane
#

You dont need a local tag for a custom role?

#

There is CustomInfo for that

#

specifically

grand flower
#

I'll take a look at that then ty

hearty shard
#

yeah

#

well

#

with InfoArea you can disable a players tag

#

idk what its called in labapi tho

#

role text too

#

at least like

#

the hover text

#

like hovering over another player

true cedar
#

u dont even need to do that

hearty shard
#

probably not but it is a feature

unique crane
#

Looks better if you have custom roles yea

white matrix
#

I think there's like 2 usages for it; one to see who are all spectators and one just to see how many players are on the server

hearty shard
white matrix
hearty shard
#

ReadyList only contains npcs and real players

white matrix
#

then that's something that @untold raft might want to know too for #1338896688743579801 message UsefulHints, as that's something I ran into earlier for the teammates

white matrix
white matrix
#

What methods of putting text on screen are currently available/supported? I'm trying to look into hints but don't really understand how to change the placement of the text on the screen.

worthy rune
heady turret
#

btw if i drop card to button that work fine

teal junco
#

is SCP SL physics deterministic?

worthy rune
#

no

teal junco
#

Fuck

worthy rune
#

what are you trying todo

teal junco
#

Replay system

worthy rune
#

that might work, as long as you dont leave anything out it should be deterministic

#

physx is abit finicky, stuff from one part of the scene can effect the physics in another part even if they are no where near eachother so you have to make sure you include everything

teal junco
#

Oh, alright. I don't know that it's possible to exactly recreate a scene 1:1 so I might have to handle physics by recording it or something.

#

I should probably start at basic stuff anyways

grand flower
#

It'll probably give you a result close enough to the original

teal junco
#

I thought of that, but I wondered how it would look for players.

#

It's probably the easiest and most reliable solution.

grand flower
#

What kind of replay system are talking

#

Like, what usecase

teal junco
#

My personal use case would probably be recording rounds and using it for B-Roll or to review gameplay with my friends (My favorite part of certain Source games was the demo review after the game)

#

I guess for that it doesn't actually matter how good it looks.

grand flower
#

It'll be fine then, that's basically what the demo system does

#

Same when you spectate players in a Source game, you're only interpolating between snapshots the server sends you

teal junco
#

I still need to fake inputs for some things like picking up stuff or shooting guns

grand flower
#

Can be part of the snapshots

teal junco
unique crane
teal junco
grand flower
teal junco
unique crane
#

Oki

teal junco
worthy rune
#

my idea for something like that was to record mirror network messages and then play them back to the clients, you might need to alter some messages to get them to work, and some have to be removed like VC ones but i think it could work

grand flower
#

I feel like that's a lot more complicated than just capturing and replaying snapshots

teal junco
#

Yeah

worthy rune
#

it might be, i never looked into it much so im not sure

teal junco
#

I could type up a demo for this and see how it actually looks

#

Also, does anyone know if theres any libraries / programming concepts I should investigate before looking at this?

grand flower
#

Not really no. Probably just .NET's default stuff for writing to a stream. You'll probably want to make some data types for snapshots and write them to a file as you go.

#

You're better off writing a prototype and iterating on it as you go for a project like this

#

You'll quickly find out what works or doesn't

teal junco
grand flower
#

Something around that ballpark yeah

#

idk if you'll want to write to the file every time you capture a snapshot

#

Potentially better to use something like a MemoryStream and then write to the file every X snapshots

teal junco
grand flower
#

Yeah IO might become a bit of a bottleneck

#

Might as well just hold X snapshots in memory and when you reach capacity you flush it all to the file

teal junco
unique crane
#

SL actually stores players location for like 3N physics ticks

grand flower
#

Wouldn't use a readable format

unique crane
#

I don't remember how much

#

But it does

#

Just don't store it every tick

grand flower
#

There's no reason to, it'll add overhead to the conversion and make the recordings bigger than they need to

teal junco
grand flower
#

yep

teal junco
unique crane
#

Binary

grand flower
#

Yeah convert to binary and flush

teal junco
#

does .net have a way to write stuff to file directly

#

oh okay

unique crane
#

Ofc it does

grand flower
#

FileStream iirc

teal junco
#

does this also preserve type

unique crane
#

If you use any serializer, yes

grand flower
#

Would make it easy that way to write the snapshots as binary to a MemoryStream and then append the memorystream to the file

#

You don't need to preserve type with binary since you're basically just writing the memory

unique crane
#

File.WriteAllBytes

#

Done

grand flower
#

Yes to the former, no to the latter, you're not keeping the entire recording in memory and then writing it to a file

teal junco
#

I can append it instead right?

grand flower
#

yeah, that's why I suggested a file stream

#

makes the whole MemoryStream -> FileStream code a lot easier

#

Play around with the amount of snapshots you keep before writing to the file, find out what works best performance wise

#

You'll probably want snapshots to have some sort of pre -> update -> post setup