#plugins-dev-chat
1 messages · Page 55 of 1


you used NAudio to stream the mp3 right?
yep
why did AudioPlayerApi use Nvorbis over Naudio?
i dont know anything about audio so im curious
oh okay
playing float arrays isn't as complicated as a sample provider
don't look at the AudioTransmitter in LabApi 
i hate the concept of loading entire songs into memory for playback
streaming from disk has pretty much no overhead
also with AudioPlayerApi you must provide a 48000Hz mono ogg file which is a bit ehhh
oh yeah that kinda pisses me off
i use C# tasks to load instead
I just load them all at start
Same
you can resample with WDL and mixdown to mono
what
while that isnt ideal it at least doesnt freeze the server
i dont know what the proper term is
not a problem if you are running the server on Cyn's pc 
what do you load
i push the loading of the audio in AudioPlayerApi onto another thread
My
ohhhh
yea
A 2 hour long Unreal Tournament music
if i need to load it immediately, i just load it on another thread so that in the case it takes a significant amount of time, the TPS doesnt drop to 0
it may be 5GB compressed but a minute of audio at 48 kHz is already 11.5 MB in memory
just preload on startup 
Preload deez
Make git issue and suggest however you want to solve that
138 gigabytes
nah cuz the way i use my plugin deals with like two thousand clips
Making the server suffer more🔥
no way am i loading that on startup or having that in memory
only solution is to stream it
my library will :3
what the actual
Nice
Yeah thats fair
finding out that stereo causes it to playback at half speed and frequency discrepency causes the same thing was so funny to me
Preloading 50 fart noises
yep
not enough
what
why do you need 2K clips
What do you use the 2K clips for
To much music
i deal with two thousand clips, thats why i dont want to load it at startup
Ambiance
so that my cassie can say the top one thousand names in the United States
is that a satisfactory answer
right
fair
No that's not satisfactory
That's secret lab
😭
can i kill you
Factorio
Fight it with Eve
Go ahead
no i think i should let him live
Just to suffer
hes a smarter programmer than me, i need to let him make another plugin before i kill him
FreakyAI 🔥
no i object to the use of AI except for that one time
AI voiceovers for some songs are quite funny
AI voice overs are funny but i also find the idea really creepy
lava chicken
The new minecraft music disc
ye
💀
💀
Wait
as an alternative to streaming MP3s i was going to have my plugin utilize yt-dlp-dotnet to download the entire audio file, then load it into audioplayerapi, and then play it
i think it is an amazing system and is very efficient
whats the other thousand
if only we had YoutubeExplode on .net standard
well, its more like 3-4 thousand.
I have the base game cassie words, and then i have top 1 thousand surnames, top 1 thousand male names, and top one thousand female names (which goes to 2.7k when i exclude the duplicates, so about 3 hundred names that belong to more than one group)
So you just.... rewrote cassie
i also have all US states, i have a collection of vulgarities, and some other stuff i dont recall
Collection of swear words
well, i rewrote it, and then i made audio files for it
the plugin is probably my biggest project ive ever made so far and it was painful
i dont even know how it functions
I didn't checked it but it might be ye
checked what?
Your code
i had to make special text formatting for the tts to correctly readout
ohlahoma
well, i wouldnt be sure whether it was the biggest, it was certainly the most complicated and headache inducing. the only one that comes close is my EXILED roleplay utilities plugin, which i refuse to touch out of fear
https://github.com/icedchai/omni-plugins-pub/blob/5ab63392f2e2f614221249c929cd8d858c4115d0/Omni-Utils/extensions/PlayerExtensions.cs#L21
Olala
i just wanted to cram in as many words as possible, i dont even know if i used the US states
it was just funny hearing cassie with a different voice saying unhinged shit
cassie_sl russia is the best american state in ukraine

gm eve
hi pai
no worries
or 69.0
there is already so much [obsolete] stuff in the api so I wouldnt be surprised if we release 2.0.0 not so far away
kills u
not nice
Me when 3114 events
Also x3rt's one is actually 🔥 addition
@limber silo is there role wrappers pr currently in internal labapi ?
i might pr it otherwise
I don't think u have role wrapper
what
well idk!!!!!!
thats why i asked jesus!!!
there is, sadly the developer working on them is busy for a few weeks, so dont expect them soon
okie
First they would need to make some constants not const so can change these small things
finally
nuh uh
keep them constant
yes!!!!
I wanna change cooldown!
Please add textures to the primitives. They are easy to implement)
if they're so simple, PR them 
-# no 🗿

That means client have to download the texture
Send a message from the server so that players can use the client texture for primitives
i wonder how optimized that is
None
It's unclear whether they will use materials or textures. The materials look beautiful
at this point they might as well add AssetBundle support
We can create a Hubert ball with Hubert texture
why does
ServerSpecificSettingsSync.TryGetSettingOfUser<SSTextArea>(
player.ReferenceHub,
MainCosmetics.Instance.Config.TextID,
out var setting
);
``` always gives null?
im trying to update TextArea content
new SSTextArea(AbilityId.TextId,"...",textAlignment: TMPro.TextAlignmentOptions.Center)
the AbilityId.TextId = MainCosmetics.Instance.Config.TextID
but still always null
How about
GetSettingOfUser
Try that
Ah so
User has to send any value back to server
for this to work
(???)
Just use GetSettingOfUser<T>
its guarantee to create the setting if it doesnt exists yet
does it
Thats one way to do it
its working thanks
kinda pointless like how Player can send any value in TextArea
Just use the GetSettingOfUser
yours is/will be better
just
we actually kinda need the plugin to test that fact
LOL

i saw smth so funny today actually
someone added RueI support to their HSM plugin
rather than adding configurations
they just made a branch
What
completely recoded their whole plugin on that branch for ruei only
so now they have to maintain 2 brances
LOL
Fire
RueServiceMeow
What is hsm
hint service meow
Hardcore SL Map
So like a HSM wrapper for RueI?
it's like ruei, but tbh the syntax is pretty crap 😭
Wtf
Is anything really that badly done?
me when discord doesn’t say when the msg was sent
Today 10:53
it
Today
was sent today
oh wait it was today?
...
Ye
LUMI.
because it doesn't say yesterday or a date
shud up
you can hover it
Blind girl
bro does NOT use discord
i’m on phone
nuh uh
then tap it
smh
Tap water?
What could be the reason for pickup following lagy?
its client parented to player
what i tried ?
rigibody.isKinematic = true;
rigibody.useGravity = false;
pickup.Base.syncInterval = 0f;
pickup.Transform.parent = Player.Transform;
Shouldn't client parenting normally resolve this?
clientside parenting only works for admintoys ig
only admintoys have parenting sync, as Xname said
How do I know which grenades were activated due to another grenade exploding?
So there's no way to fix this? I tried adjusting the position and rotation myself, but it's still laggy.
You will have the patch the explosion method for that
Which path is it?
Serial?
you can do a postfix on InventorySystem.Items.ThrowableProjectiles.TimedGrenadePickup::OnExplosionDetected
and inside patch check if __instance._replaceNextFrame is true
you would probably want to add that pickup instance to a List to and somewhere else check if it's in it
just don't forget to remove that pickup from the list and clear the list between rounds
hm, sory, don't store the pickup instance
it will get destroyed, just store pickup's serial
No. I just want to limit the number of grenades that can be activated by an explosion 
private static bool Prefix(Footprint attacker, Vector3 source, float range)
{
ThrownProjectile[] projectiles = Object.FindObjectsByType<ThrownProjectile>(FindObjectsSortMode.None);
int count = projectiles.Count(x => x.PreviousOwner.Equals(attacker));
if (count > 10)
return false;
return true;
}
[HarmonyPatch(typeof(TimedGrenadePickup), nameof(TimedGrenadePickup.OnExplosionDetected))]
internal static class LimitGrenadeChainingPatch
{
public static Dictionary<Vector3, int> _chainedGrenades = [];
private static void Postfix(TimedGrenadePickup __instance, Footprint attacker, Vector3 source, float range)
{
if (!__instance._replaceNextFrame)
return;
if (!_chainedGrenades.ContainsKey(source))
_chainedGrenades[source] = 0;
int count = _chainedGrenades[source]++;
if (count <= 10)
return;
__instance._replaceNextFrame = false;
__instance._attacker = default;
}
}
I think this should work
And in the ServerEvents.OnExplosionSpawned you can remove that key from the the dictionary
LimitGrenadeChainingPatch._chainedGrenades.Remove(ev.Position);
test this because i might be wrong about clearing it instantly after triggering grenade exploded
i've updated the code a bit
I just noticed that you wrote... Unfortunately ThrownProjectile is cleared because of which it always returns 1. And I wrote the code like yours
private static readonly Dictionary<Vector3, int> GrandeCount = new Dictionary<Vector3, int>();
private static bool Prefix(Footprint attacker, Vector3 source, float range)
{
if (GrandeCount.TryGetValue(source, out int count))
{
count++;
GrandeCount[source] = count;
}
else
{
count = 1;
GrandeCount[source] = count;
Timing.CallDelayed(0.1f, () => GrandeCount.Remove(source));
}
return count <= 10;
}
XD
Or you can patch the base method for explode
and count the triggered nades
IExplosionTrigger
🥶
It works but it looks scary
I think there's a config option for that
Idk
I dont think there is
let me check
Either I'm delulu or it used to exist
dont see anything like that in gameplay config
Someone knows why this could be happening? im doing it with base game
uhoh, are you doing funky primitve spawning?
let me guess
missing dirty bits
idk
maybe i remembered an exiled config thing from my ancient times
no vanilla one
have you written the dirty bits twice?
I might have forgotten 
are you sure that's caused by vanilla primitives 😭😭
im rewriting the serialize
to see what crazy shit i can do with it



that's vanilla
the class is vanilla, i never said the method is 
im joking but yea i understood let me check if its actually that
Hii david
Hiii
how are you doing :3?
yea good
nice to hear
No btw its not that the issue
because i tested and it works fine with previous code
1C - 24
"guys idk why it breaks"
"show code"
"um"
Or you have more of it

Its very secret!!!
and top level redacted
probably ulong
You either missing or having more
So dirty
LIKE its just me doing nothing really special other than getting the network writer and trying to overflow it
😭😭😭😭
i just wanna see what happens
Didn't had to guess that part
"guys I cannot drive the car"
"why"
"I replaced the driving shaft"
Btw its not that
when
-# i know mirror is not websocket
"at least it's mine"
AHHAHAHAHHAHAH
Its going to be a big one
Like
better get the page file ready
i just realized what your pfp is...
how have i not seen this before
what
Okay
My is a spinning cat
I found a bug — can anyone recommend a good auto clicker or macro software so I can spam totally legitimate bug reports into beryls DMs?
lagging the server with SSSS?
buttons?
why are you redacted
Report any base game bugs to https://support.scpslgame.com/bug-report and LabAPI bugs to https://github.com/northwood-studios/LabAPI
(I was absolutley shitposting to mess with beryl please forgive me)
damn
ahaa ye
random hubert appeared

thank you
now return to work
Yes sir
we need more events NOW
@woeful geyser send ging
you know he’s on vacation
random hubert showup
thank you
cat
cat
cat
cat
Sneaky cat
Im trying to understand why its still happening
i cannot figure it out
Like nothing has changed
How to implement a plugin to the server?
who set the repo's description to be a modding framework
i'm not sure if you can call it that 😭
okay...
Hey axwabo
Im honestly lost rn
I CANNOT understand why it doesn't work at all
and its just random asf the error
do you need emotional voice chat support
i'm up
im just so fucking tired
Syncing till i fake it
check if you can vibecode a LabAPI plugin
i tried that
i wanted to make easy money ;(
chatgpt supremacy
i used duckduckgo ai lol
microsoft copilot seems to be closer but still hella broken
hubert i can try with Premium
plugin api
doesnt seem too far off, aside from plugin info not being a thing
Works i guess
hubert you want to become blind, you are already bald and make other people blind please don't make yourself blind too
btw use o4-mini-high because its smarter
I did use it
strange mine works fine and its even correct
because you got more lucky
hubert my gf called u an egg, how does this make you feel
i guess
the beauty of LLMs is that you get different response every time you generate
AHAHHAHAHAHHAHA
this is exactly the same prompt and exactly the same model
too scared
Never
completely different answer
unsubscribe from memory leaks *square*
oh wait
i
hubert
put the wrong emoji
it even searched the web this time, previously it didn't
it didnt happen
yeah but didn't search for the first time, despite using the exact same prompt and model
hubert pls ban zenlet, hes trying to defame me
for the second time it decided to search web on itself
Best feature I ever added
is this supposed to be a surprise to us
i typed giggle
also
ur a loser
anyway hi pai
nuh uh
nah hubert don't let me down answer please our projects depends on capybaras
ur right i missed the i and typed gg
and i guess misclicked
idk
😭
wrong emoji
hai !!
crazy, it used the wiki
Are you surprised???
Eve is so agressive today
you did this
I'm just trying to tell the truth here
I
Lucid
im gonna kill u
do it u wont
!removerole 1274619602927747115 1180466630191501363
I successfully removed Plugin Developer from obvevelyn
all so agressive today
Gone
LOL
XDDDDD
HAHAHAHAHAHA

YES NO MORE NAMELESS
lmfaooo
W
deported
Send her to #scp-discussion only
Is that a bet?
nuh uh go back to exiled
YOU go back to exiled
ur like
exiled #1 fan
wtf are you on i switched so fast to labapi
i swapped before u im pretty sure
it took me alot because i was studying for my exams
like it was the most important of my life
get gud
i have the highest grade out of my class with another of my friend
so i wasn't scared
i just wanted a good grade
Imagine still studying
90/100
Or having touched exiled
imagine stll living
Dang you got me beat there
god bless
im going to strangle you
This is an incredibly based take
What is happening in labapi channel
biggest event for primitive map makers
cooking... something ig
16 people in vc wtf
Join up pal
um, sigma?
use Player.ReadyList
why
okay pal, ban this guy
Still broke 😭
what about it is broken
what
ReadyList gets npcs too
GetAll is fine
fr?
yes

but yeah GetAll is fine
id hope so?
if ur trying to do stuff without breaking server but also letting dummies yk act as dummies?
theyre meant to be fake players
hmm
like eve!
SodaSpy was null 🤦🏼♂️
HOE
u cant say that
does changing the wave tickets still only change the starting tickets
Ur gay
a fix has been issued for it
it will be delivered with labapi's next release
gotcha, thanks 🫡
I can get a float array from NAudio right?
Yeah
Whatcha trying to do
Oh btw new rules seem to make audio recording ok for your demo stuff so that's good
On the flip side you'll probably get the EU and any other country/state with privacy laws at your doorstep if you don't do it right, so still a nono

i want to stream parts of an audio file at a time to my audio speakers
Yeah you can use NAudio for that
You'll need to encode it using VorbisEncoder iirc
before sending packets to players
(i want to play a very large audio file in smaller chunks so i dont fuck up my memory)
i dont think ill be able to get this plugin in time tho so idk if i want to even start at this point
I mean how big's the file
okay
we can say its like 40 megabytes but it takes up like a gigabyte of memory or something similar
bruh
thats why i wanna play it in pieces 😭
in any case you can just use VorbisReader to read the file, it'll stream it in
and then VorbisEncoder to encode & send
Will VorbisReader only read a specified number of bytes from the file?
so that I can get readable chunks
Pretty sure you can make it read as many samples as you want
It's what we do
Read X samples, encode & send, read more if we're under a threshold
oh so i dont even need NAudio in this case?
nop
VorbisReader will do the reading and VorbisEncoder the encoding needed by SL
You'll need NVorbis as a dependency, that's it
uhm....
so I do
VorbisReader.ReadSamples(float[] samples, int offset, int samplestoread);
offset += samplestoread;
then i can use the vorbis encoder i have to encode the samples and then send it as an AudioMessage?
do you happen to mean OpusEncoder btw?
i dont see a VorbisEncoder
yep
Offset should be 0
at all times
oh so the reader will stay where it is
the offset doesnt need to be specified
It'll read from the first byte in the samples that way
Read it to a buffer, then push the read samples into a queue
then when i dequeue, i encode it and send it as n audio message?
yep
each sample is a byte array right
oh
I think I can figure out a way to mod this into AudioPlayerApi
probably lazy but i want to have it by tomorrow
just wont mesh very well, but if i make it only for me then only i need to know
Does someone know if with EntityStateMessage you can send multiple info like
Position, Rotation and Scale?
ESM can send any syncvar info for any network behaviour for the specified network identity
I mean i need to send like one entity message and just sync 3 vars
that are this ones
public static void SendFakeUpdate(
this Player target,
uint netId,
Type targetType,
ClientSide side
)
{
string syncVarKey_Position = $"{targetType.Name}.NetworkPosition";
string syncVarKey_Rotation = $"{targetType.Name}.NetworkRotation";
string syncVarKey_Scale = $"{targetType.Name}.NetworkScale";
using var observer = NetworkWriterPool.Get();
Compression.CompressVarUInt(observer, 1UL);
int lengthPos = observer.Position;
observer.WriteByte(0);
int payloadStart = observer.Position;
if (!SyncVarDirtyBits.TryGetValue(syncVarKey_Position, out ulong syncVarMaskPosition))
{
return;
}
if (!SyncVarDirtyBits.TryGetValue(syncVarKey_Rotation, out ulong syncVarMaskRotation))
{
return;
}
if (!SyncVarDirtyBits.TryGetValue(syncVarKey_Scale, out ulong syncVarMaskScale))
{
return;
}
var syncVarMask = syncVarMaskPosition + syncVarMaskRotation + syncVarMaskScale;
//REMINDER 16 is when transform updates for AdminToys.
bool isSecondWrite = typeof(AdminToyBase).IsAssignableFrom(targetType) && syncVarMask > 16;
observer.WriteULong(0);
observer.WriteULong(syncVarMask);
if(isSecondWrite)
observer.WriteULong(syncVarMask);
if (!WriterExtensions.TryGetValue(typeof(AdminToyBase), out var writerDel))
{
return;
}
writerDel.Invoke(null, new object[] {observer, side.position, side.rotation, side.scale});
if(!isSecondWrite)
observer.WriteULong(0);
int payloadEnd = observer.Position;
observer.Position = lengthPos;
observer.WriteByte((byte)(payloadEnd - payloadStart));
observer.Position = payloadEnd;
target.Connection.Send(new EntityStateMessage
{
netId = netId,
payload = observer.ToArraySegment()
});
}
I tried making it like this, if i just do one value it works fine if i do multiple nope
yeah any amount of values works
the client doesn't reply with anything
and the server is sending
but client doesn't actually do anything
the only restriction is that they have to be associated with the network identity
it is
reply?
ahh
1uL
i checked Mirror but it should be fine
??
Also idk if SyncVarMask is accurate
shouldnt need to write the number of sync vars, as thats apart of the mask
yea it doesn't still even changing that
do you a version of the code thats documented line by line
no?
this would of been a good time
I just know with one works, with 3 no 
even tho it should be because mirror just does this
if (spawned.TryGetValue(message.netId, out NetworkIdentity identity) && identity != null)
{
using (NetworkReaderPooled reader = NetworkReaderPool.Get(message.payload))
identity.DeserializeClient(reader, false);
}
Oh wait
i just saw something
probably is not sending?
nope it sends
I think your SyncVarMask is not valid
whats this doing
if (!WriterExtensions.TryGetValue(typeof(AdminToyBase), out var writerDel))
{
return;
}
writerDel.Invoke(null, new object[] {observer, side.position, side.rotation, side.scale});
Also here some thing that might help you.
https://github.com/KadavasKingdom/LabApiExtensions/blob/main/Extensions/FakeSyncExtension.cs
i see
Its just getting the Writer
for admintoys
that doesnt seem right
That works fine with just one
the problem with >= 2 doesn't work
I will try something when i will be at my PC
How many SyncVars you wanna write?
Like maximum
3
Ok
in general i think 3
but i will rewrite to actually support more
and do like one update every time
is there a NetworkWriter<Admintoy>() method that you are getting?
I don't think such a writer exists
/// <summary>
/// Gets <see cref="MethodInfo"/> corresponding to <see cref="Type"/>.
/// </summary>
public static ReadOnlyDictionary<Type, MethodInfo> WriterExtensions
{
get
{
if (WriterExtensionsValue.Count == 0)
{
foreach (MethodInfo method in typeof(NetworkWriterExtensions).GetMethods().Where(x => !x.IsGenericMethod && x.GetCustomAttribute(typeof(ObsoleteAttribute)) == null && (x.GetParameters()?.Length == 2)))
WriterExtensionsValue.Add(method.GetParameters().First(x => x.ParameterType != typeof(NetworkWriter)).ParameterType, method);
Type fuckNorthwood = Assembly.GetAssembly(typeof(RoleTypeId)).GetType("Mirror.GeneratedNetworkCode");
foreach (MethodInfo method in fuckNorthwood.GetMethods().Where(x => !x.IsGenericMethod && (x.GetParameters()?.Length == 2) && (x.ReturnType == typeof(void))))
WriterExtensionsValue.Add(method.GetParameters().First(x => x.ParameterType != typeof(NetworkWriter)).ParameterType, method);
foreach (Type serializer in typeof(ServerConsole).Assembly.GetTypes().Where(x => x.Name.EndsWith("Serializer")))
{
foreach (MethodInfo method in serializer.GetMethods().Where(x => (x.ReturnType == typeof(void)) && x.Name.StartsWith("Write")))
WriterExtensionsValue.Add(method.GetParameters().First(x => x.ParameterType != typeof(NetworkWriter)).ParameterType, method);
}
}
return ReadOnlyWriterExtensionsValue;
}
}
I didn't create this but its from exiled and yes the fucknorthwood is from there lol
Please check in ACS if there is a Network writer dedicated for AdminToy
There is probably NONE
But you can try
^
wtf are you guys on
there wouldnt be one for admin toys
OH i figured it out
those network writer functions are for serializing/deserializing primitives and custom code. the code for syncvars and entity state messages is entirely generated
if (!WriterExtensions.TryGetValue(typeof(T), out var writerDel))
{
return;
}
writerDel.Invoke(null, new object[] {observer, value});
Other code does this T is the value so for example Vector3
Also you can just do
observer.Write(Position)
But now i need to write multiple
yeah
Ye
Wait you don't write anything after the 16'th SyncVar so you gucci
you already know the types, so you dont need to get it via reflection
observer.WriteVector3(side.position);
observer.WriteQuaternion(side.rotation);
observer.WriteVector3(side.scale);
i guess this does the job
yeah
Should this sorta work? Yes, is very derivative of AudioPlayerApi.
void Awake()
{
Timing.CallDelayed(10f, () =>
{
InvokeRepeating(nameof(SendAudio), 0, (float)AudioClipPlayback.PacketSize / AudioClipPlayback.SamplingRate);
});
Timing.RunCoroutine(ReadAudioFile());
}
public Queue<float[]> sampleQueue = new Queue<float[]>();
internal IEnumerator<float> ReadAudioFile()
{
bool shouldRun = true;
while (shouldRun)
{
while (sampleQueue.Count < 200)
{
float[] _pcm = new float[480];
vorbisReader.ReadSamples(_pcm, 0, 480);
sampleQueue.Enqueue(_pcm);
}
yield return Timing.WaitForOneFrame;
}
}
internal void SendAudio()
{
float[] pcmGot = sampleQueue.Dequeue();
int encodedLength = OpusEncoder.Encode(pcmGot, _encodedPcm);
AudioMessage msg = new AudioMessage
{
ControllerId = ControllerID,
Data = _encodedPcm,
DataLength = encodedLength,
};
NetworkServer.SendToReady(msg);
}
was there any problems
writer.WriteULong(dirtyBitMask); //writing the mask
// Writing Sync Var here now, should write from smalles of SyncVar Byte to higher one, first 1uL, 2uL, 4uL, .. etc
writer.Write(syncVarForFirst); // THIS SHOULD BE THE SMALLEST ONE!
writer.Write(syncVarFor2);
writer.Write(syncVarFor3);
writer.WriteULong(dirtyBitMask); //This satisfy the inherited one.
i havent tested it because im not in a position to, but i just want to know if anyone finds any glaring logical issues
i see
im gonna go sleep and ill test it tomorrow
you could use the labapis audio transmitter for sending audio, instead of trying todo it yourself
lab api has an audio player wrapper?
oh so can i enqueue samples for it to play
so i only have to handle acquiring the samples
oh holy shit
yeah
Ok so it works
i don't understand tho its because im doing 140ms on the server or what but if i spawn multiple of 100 primitives moving randomly the client decides to delay everything
I just do it only when there's an update tho
500,000 should be a nice amount, right?
i mean thats like ten seconds of samples
i think
client likely cant process everything in time
i think what i might do is just cache everything if no updates or anything it doesn't actually update
just when its needed
not sure if its a mirror thing but the client can fall behind
but rn it does that
that would be just like what mirror does by default for sync vars yeah
best way to save on networking is to make sure you only move the parent/root object
i do that
if you have like a particle system, your out of luck
no?
Vector3 currentPosition = transform.position;
Vector3 currentRotation = transform.eulerAngles;
Vector3 currentScale = transform.lossyScale;
UpdatesObject updates = UpdatesObject.None;
if (currentPosition != _lastPosition)
{
updates |= UpdatesObject.Position;
_lastPosition = currentPosition;
}
if (currentRotation != _lastRotation)
{
updates |= UpdatesObject.Rotation;
_lastRotation = currentRotation;
}
if (currentScale != _lastScale)
{
updates |= UpdatesObject.Scale;
_lastScale = currentScale;
}
if (updates != UpdatesObject.None)
UpdatePosition?.Invoke(this, updates);
unless the children are not admin toys they dont require updates
you should check out AudioTransmitter.Player(...)
like as you can see this is on the update
so everytime there's an update it does that
what is that for
attachedObject.UpdatePosition += (e, o) =>
{
if (e != AttachedObject)
return;
foreach(Player player in this.PlayersLoaded)
player.SendFakeUpdate(NetId, typeof(AdminToyBase), this);
};
you can queue the audio, or stream it by calling it multiple times
use local pos/rot/scale instead
hm let me test
your not patching anything internally to use world over local are you?
no im not doing anything to sl poor code its already tortured enough
oh, like this maybe
yeah
im pissed off by this error but if i fix it the plugin will probably work if i set it up correctly
thanks for pointing me to that wrapper
its very helpful
to not have to handle the messaging myself :D
for the error there should be a property with the currently loaded count(samples not sent yet)
Like publicize?
use AudioTransmitter.CurrentSampleCount instead of AudioTransmitter.AudioCLipSamples.Count
Add mscorlib from game.
You probably need to add other stuff into csproj
yea btw doing that just doesn't update them at all 
local?
yep
Vector3 currentPosition = transform.localPosition;
Vector3 currentRotation = transform.localRotation.eulerAngles;
Vector3 currentScale = transform.localScale;
sob....
This to you iced
something wrong
Those two mean different things, currentsamplecount is the current samples being read
when you send these are you sending local pos/rot/scale?
i just don't think its wrong because its just
object so it makes sense that local position is 1
Last time i seen the rotation is a quat
yep
AudioClipSamples.Count is the number of samples in queue to be read
Ah
ahh yeah your correct
i thought i had added one for total samples, i guess not
you will need to referece mscorlib from the game(also you might have to remove the reference VS/rider provides to get it to work) like SlejmUr said
<NoStdLib>true</NoStdLib>
I think inside your csproj and add mscorlib to your references or smth
technically thats how the game is doing it, and iirc networking was vastly improved(it used to send all even children in 14.0 which caused that delay like you saw before)
yea i just replaced it
it worked
so yea i need to recreate that yippe
should be been as easy as replacing world with local
wait
but idk how you have set everything up
if i send an update for each children
so like
Main
child 1
etc..
thats causing the lag
because each children is sending an update
i don't think i can send just update this...
else i would need to spawn a primitive and update just that
so are you saying if the root changes, you force update all children?
yes.
i have a library for that releasing in a few days

never
I mean what can i do to make it better
because as of rn the primitives don't have a parent with an identity
just with something normal
im referring to cases where you have primitives where they are children to other primitives and you want all to move together, if thats not the case and all should move indepentant theres nothing you can do
you have to reallocate an array every time you wanna do that, or check if the clip is free to reuse it
i guess i could use this 2
Hubert discovering these 2 events yesterday
I know
Can confirm
i think thats only called when transform.parent changes, not any changes to the pos/rot/scale
but i used it yesterday and just wasn't alr
huh?
(I didn't know about them either)
He was streaming the culling toy dev
ahh, ofc on the day im away
i have a recording if you want it
:D
haii
lets see if today by staying in vc i can crash central server by convincing someone

😭
I wonder if I can stream doing stuff too
im honestly loosing my mind
Until you don't leak stuff
You guys starting up what happened yesterday 
Labapi Dev streams
Crazy
Yea just me asking hubert if he liked the capybara
Where we refactor old game code
I mean probably not much since need art and stuff
🔥
ooo let me see
New mantra
gotta ffmpeg it still, it's 800 MB and separate audio channels
Thanks for leaking 14.1.2
BRO WHAT
Thanks for leaking 15.0.0
It's reference to the spongebob ai
No problem
😭
What
1h 42 mins
the heat death of exiled
btw do you still need translations 
i got it ty
Upload into yt
crazy
I always crazy
do what?
like for reading
you need a buffer per "clip"
i guess you could overwrite data in an existing buffer but i don't think you can guarantee at which point the end is reached
i only plan to play one audio file per player
yea btw no hangout this is sad ;(
It's 9 in the morning
i need a few mins, gotta breakfast stilll
i'll let ffmpeg run in the meantime for Riptide
Honestly
Im going insane
spawning 200 primitives moving around cause the client to explode so badly
not of fps of mirror messages
i need a way to just lower that down ;(
Rewriting admin toys to messages now
i did
and thats what im doing
its JUST TOO MANY MESSAGES
i cannot do much
WAIT
i could bundle them
Prob no
Why
they are already batched
Rn this is how it looks 100 primitives stacked on top of each other updating and just doing weird stuff
Good luck
so 200 primitives just moving randomly and changing rotation scale
You and your primitives
i need to resist for another build
yea ;(
Honestly you cannot

Wdym
That's hubert job
so try breaking that
What if I don't make them network behaviour
yea at that point i cannot do much
I make standalone message to spawn them
i can just recreate that by changing one line





