#Runtime Netcode Patcher
1 messages ยท Page 1 of 1 (latest)
NetcodeValidator
- The
NetcodeValidatorwas cleaned up and restructured to more closely match the class it is effectively a wrapper for. This changes the api to require a call tonetcodeValidator.PatchAll()now after initializing withnew NetcodeValidator(this) NetcodeValidatoralso now patches all methods immediately uponPatchAll()but waits until NetworkManager is Initialized each time to register custom named messages.- Patched all the NetworkBehaviour constructors to start a coroutine to yield until the
NetworkObject.IsSpawnedand then bind to said network object and update network properties. This mitigates having to add NetworkBehaviours before NetworkObject load.
FastBuffer Extensions
- A large quantity of the data processing was moved to the respective extension methods. This is all internal but a large move in the right direction regardless.
RPC Changes
- Big Changes: Parameter counts are now (theoretically) larger than we can discuss
- You can now use
System.Serializable(With an attribute [Serializable]) orINetworkSerializable(with inheritence) as parameters.
QoL
- Large sections of code have been removed and reduced to improve readability.
@torn schooner can you elaborate more on the example provided. it seems incomplete
When did you check that
And if you're talking about these examples https://github.com/NicholasScott1337/RuntimeNetcodeRPCValidator?tab=readme-ov-file#examples
Then there isn't anything else to elaborate on? Besides maybe the AddToTerminalObject is incomplete
AddToTerminalObject is what i was referring to yea
Yeahhhh Idk why I didn't type it
But it's just __instance.gameObject.AddComponent<PluginNetworkingInstance>()
I fixed it and will push to include that line lol
I guess I just zonked out on that xD
๐ฌ
all good lol
tried the example 1 to 1 and RunClientRpc() doesnt actually get called because isHost is always false
I'm assuming NetworkObjectId is valid or there would probably be an error
I'm pushing an update soon
I'm assuming it's because the NetworkManager is null so IsHost isn't assigned when I run the method ๐ค
I'll have to think about a solution while I finish these changes and implement it for 0.1.1
Adding a NetworkBehaviour to a NetworkObject at runtime is a workaround to how netcode wants it done
But tbf it should be valid if NetworkObject IsSpawned
But the takeaway is to just always get .NetworkObject.IsOwner
That is 100% accurate
It's just getting those values to be accurate on your custom behaviour is difficult
thanks
sorry .NetworkObject.NetworkManager.IsHost
It's what we're talking about lol
It might be a bit late @devout gorge but could you tell me if you get an error like this ?
chekcing logs
Hmm
Thanks for bringing this to my attention cuz upon further investigation the networkobject ref is null ๐ค
So inconsistent now?
Casn you do me a favor @devout gorge
Well nvm it's Terminal Start there too
Yea I hate to butr can you try this?
send it
I'm also in Terminal-Start as Prefix and I'm getting this log output
So IsHost is true for me, I'd like to see if 0.1.1 fixes your issue
I added a wait until the NetworkObject is valid so that might be what fixed it
But ^ seems redundant from my understanding ๐คทโโ๏ธ
weirdly still false & true
๐ฎ
Whaaaa
Ye that's the issue then
Why does Awake get run before the construct of your type
How does that work
Omgggg
The networkobject isn't spawned in awake
BROOOOOO
Nah
Change your logging method from Awake to Start in your plugin
copy
Like that to Start
I'm waiting until NetworkObject.IsSpawned, which maybe I shouldn't do
Okay that's def the problem
I gotta run to the store for lunch but when I get back i will 100% fix that and wait until something that happens before awake
Cuz that's what's going on is I'm waiting for NetworkObject.IsSpawned
and clearly that won't fly
Cuz it runs wayyyyy too late
So glad we could track that down, tysm @devout gorge
That's a huge hel,p
np cant wait to fully utlize this and get my mod out finally lol
0.1.8 - NuGet
Allot of the updates up to 0.1.8 is getting all the github workflows worked out thanks to @barren bone. A major byproduct is RuntimeNetcodeRPCValidator is now on on NuGet! You can do dotnet add package NicholaScott.BepInEx.RuntimeNetcodeRPCValidator --version 0.1.8 or right click nuget packages and add the name from the search.
@devout gorge 0.1.8 should fix any of the issues you had previously. I also added a public method thisNetworkBehaviour.SyncWithNetworkObject() that you can run before calling any references to NetworkBehaviour properties if you run into any weird issues.
got some extra braincells in me time to try this again
You should get a log error just before Awake if it's null
If it's not then try .SyncWithNetworkObject just before those debug logs
Show load message
For runtime patcher
The load messsage for the plugin?
let me disable everything else to make sure theres no conflicts
I'm gona push an update to make it 0.2.0 soon that's gonna change a thing you'll have to update
incase you wanna know what im using
oh im dumb
[Info : BepInEx] Loading [RuntimeNetcodeRPCValidator 0.1.8]
nothing else tho
Yea there was a logging error I'm afraid may also be affecting things
I'm not sure why it's not working tho tbf xD
I had consistent results before I pushed 0.1.8
your example is incorrect still btw
public void SendPreferredNameServerRpc(string name) {
Debug.Log(name);
TellAllOtherClients(NetworkBehaviourExtensions.LastSenderId, name);
}
[ClientRpc]
public void TellEveryoneClientRpc(ulong senderId, string name) {
Debug.Log(StartOfRound.Instance.allPlayerScripts.First(playerController => playerController.actualClientId == senderId).playerUsername + " is now " + name);
}
TellEveryoneClientRpc but is calling TellAllOtherClients
xD
anyone with half a braincell with notice it and fix it but just incase
Well thankfully before I'm pushing this update I'm finalizng my UnitTester plugin that will be in the repo along side it so examples should be build-ready going forward
And hopefully avoiding the issues w stuff not working ๐คฆโโ๏ธ
๐
@devout gorge The only change you'll have to note on 0.2.0
PluginGUID instead of Plugin
alright
remeber i said i had some braincells
clearly i didnt
i forgot to readd the validator......
Big memin
wait
i think ik the issue
could be the staging shit
i removed the exampels and its still in the log lol
๐ฌ i broke my new glow steps git repo on accident cuz idk what im doing xD
It's a struggle
@torn schooner got a error when a non host player tried to trigger a rpc
[Error : Unity Log] NotServerException: ConnectedClientIds should only be accessed on server.
Stack trace:
Unity.Netcode.NetworkManager.get_ConnectedClientsIds () (at <1b23ec5fcbfc4fbca0db70afcdb9b715>:0)
Unity.Netcode.CustomMessagingManager.SendNamedMessageToAll (System.String messageName, Unity.Netcode.FastBufferWriter messageStream, Unity.Netcode.NetworkDelivery networkDelivery) (at <1b23ec5fcbfc4fbca0db70afcdb9b715>:0)
RuntimeNetcodeRPCValidator.NetworkBehaviourExtensions.MethodPatchInternal (Unity.Netcode.NetworkBehaviour networkBehaviour, System.Reflection.MethodBase original, System.Object[] args) (at <16c204566f764b8f9c2a9a66ccf07b63>:0)
RuntimeNetcodeRPCValidator.NetworkBehaviourExtensions.MethodPatch (Unity.Netcode.NetworkBehaviour __instance, System.Reflection.MethodBase __originalMethod, System.Object[] __args) (at <16c204566f764b8f9c2a9a66ccf07b63>:0)
(wrapper dynamic-method) BunkbedRevive.BunkBedNetworking.DMD<BunkbedRevive.BunkBedNetworking::RevivePlayerClientRpc>(BunkbedRevive.BunkBedNetworking,int)
BunkbedRevive.BunkbedController.OnInteract () (at <3bd758e1b80c4ed38df9aa7eee6b0e06>:0)
BunkbedRevive.BunkbedController+<>c.<CreateTrigger>b__4_0 (GameNetcodeStuff.PlayerControllerB <p0>) (at <3bd758e1b80c4ed38df9aa7eee6b0e06>:0)
UnityEngine.Events.InvokableCall`1[T1].Invoke (T1 args0) (at <e27997765c1848b09d8073e5d642717a>:0)
UnityEngine.Events.UnityEvent`1[T0].Invoke (T0 arg0) (at <e27997765c1848b09d8073e5d642717a>:0)
InteractTrigger.Interact (UnityEngine.Transform playerTransform) (at <44743d9474784365a095189c76175301>:0)
GameNetcodeStuff.PlayerControllerB.Interact_performed (UnityEngine.InputSystem.InputAction+CallbackContext context) (at <44743d9474784365a095189c76175301>:0)
UnityEngine.InputSystem.Utilities.DelegateHelpers.InvokeCallbacksSafe[TValue] (UnityEngine.InputSystem.Utilities.CallbackArray`1[System.Action`1[TValue]]& callbacks, TValue argument, System.String callbackName, System.Object context) (at <69a3ba35f0be43dc9f2827cb84fef646>:0)
UnityEngine.InputSystem.LowLevel.<>c__DisplayClass7_0:<set_onUpdate>b__0(NativeInputUpdateType, NativeInputEventBuffer*)
UnityEngineInternal.Input.NativeInputSystem:NotifyUpdate(NativeInputUpdateType, IntPtr)
[Error : Unity Log] NotServerException while executing 'performed' callbacks of 'Movement/Interact[/Keyboard/e]'
A client is trying to call a serverrpc
You should look intently at your code @devout gorge
I reckon I should add a check to make the error message more clear
But ye SendNameMessageToAll is the server custom message handler send to clients call
Sorry I didn't see this sooner
Call a ServerRpc that then calls a ClientRpc
It's possible you've ogt it right
Ye no I double checked it seems you have a client calling a client rpc
Ye
You should call a ServerRpc
(That in theory does some checks for maliciousness idk xD)
Then call that RevivePlayerClientRpc
ClientRpc's really shouldn't be called unless you're inside a ServerRpc(Obviously the server) or you've checked you're on the server manually (By using if IsHost)
works 100%
^_^
Just finished the Testing plugin too, feeling confident to finalize and push 1.2.0 ๐
๐ฅณ
v0.2.0
Changed
- The final changes to the
NetcodeValidatorclass occur w/ this update. This will be the final form, the only change on your end is anew NetcodeValidator(YourPluginGUID)instead ofnew NetcodeValidator(YourPlugin). This is to be more in line with how Harmony instances are handled and to make things easier on the back-end. This includes a few new methods listed below following the pattern of the Harmony class. - NetcodeValidator.Patch(Type type)
- NetcodeValidator.Patch(Assembly assembly)
- NetcodeValidator.PatchAll()
0.2.1
Changes
- Improved error checking.
- Unified text handling to improve readability and end-user experience.
just realized, no license @torn schooner ?
Thanks, didn't notice @wintry plume Uploading releases now
only noticed cause I wanted to take a look at how you do error messages :)
0.2.2-5
Fixes
- Fixed licensing thanks Xilo โค๏ธ
Changes
- Major Readme overhaul with much better info ๐
- NetworkBehaviours on Pre-Existing NetworkObjects now need manual binding. More on the github README
Removals
NetworkBehaviourExtensions.LastSenderIdhas been removed in favor of RpcParams.
Additions
- Now fully supports ClientRpcParams & ServerRpcParams as the last parameter of your RPC, to the same specs as normal NGO
@torn schooner when you get the chance, would you be willing to look into adding your API to https://lethal.wiki?
This article goes into how to add to the wiki, and if you need any help (if you choose to add it to the wiki), just lmk
this is exactly what i was looking for, didn't want to go down the route of making a manager prefab for my networking
also if you don't want to add how to use it to the wiki, I can just add it as a programming API and link to your docs
I'm happy too, perfect thing to do on my laptop, I'll definitely try and get it done today! I'm kinda swamped trying to help w/ networking problems ;~; its a bit slow going on this i3 hp laptop ๐คฃ
Erm
@wintry plume lol
Idk if I should put RNV on there
Unless we severely modify how it's presented atm
Cuz it's just gonna confuse people w/ 'Networking' being entirely @junior sails patcher
Then having a Runtime alternative too
๐คทโโ๏ธ
isn't it more of an API than a dev tool? may be misunderstanding it
Evaisa's Netcode Weaver is compile time
Mine does the same
But at runtime
W/ Harmony
It adds some alternatives
Like ability to serialize System.SErialize
Not needing to do asset bundles
Etc.
So it has valid usages over Weaver
(It's allot easier to setup and use imo)
You dont need to compile you just add a dependency
And you dont need asset bundles and you can bind Behaviours to pre existing objects
So it's a bit more conducive to new modding
But ye
Unless the 'Networking' article is restrutured
Having another article on RNV
Might just confuse people to thinking they need both
(Which would be TERRIBLE)
Having both would be brokey af
the networking article can be restructured
I really do want it on there cuz the examples in my readme has been a headache to maintain
I need a nice wiki for it tbh
This is primo oppurtunity
But I also don't want to confuse people ;~:
is the general rpc code the same and just "initializing it" is different (ie have separate sections for compile & runtime under https://lethal.wiki/dev/advanced/networking#spawning-the-networkhandler & past)
Yeah, as long as you're cool with me proposing a restructure I can work on that
Allot of crossover ye
Just different "setups" for each I guess
(I've programmed RNV to do RPC checks and processing to be as close to the same as Netcode Patcher)
Even just added the XXXRpcParams handling so you can do that the same as NGO as well
I need to talk to Evaisa more
I say
- adjust preface to include your runtime patcher
- add section on "Why use RNV?"
- make any slight differences on how RPC works at appropriate parts in "Creating the NetworkHandler" (and maybe restructure?)
- separate "Spawning the Network Handler" to
- Compile Patcher
- Runtime Patcher
- move last "Using Unity Netcode Patcher" to the compile patcher section
it's a lot, but I know both the article and VitePress in-and-out so I can definitely provide help on it
And get a bit more on the same page
But I think there's a mutual respect (hopefully lol)
The way I see the difference imo

If you're not going to use Assetbundles
You should probably just use RNV
Cuz otherwise you're going through a whole extra process when you could just throw in a dependency and bind to the terminal
I wrote the networking article so long ago with like 5 days work of networking knowledge, some of the stuff is just flat out wrong or needs to be changed to be more generalized
Oki, wish me luck โค๏ธ
like this
I recommend separating this script as far as possible from any patches to avoid potential errors through Unity. This can easily be done by not including/using any outside methods and variables in the script.
just wrong
no need to do that
Interesting
Well hopefully I won't have to change much, just generalizing :3
You're a knowledgable fella
this came out of errors happening cause I didn't know what I was doing and ran into issues I couldn't solve at the time
Relatable
lmao the code here doesn't use the right type
https://lethal.wiki/dev/advanced/networking#clientrpc
this is flat out missing a semicolon
https://lethal.wiki/dev/advanced/networking#finalized-network-object-manager
if you also want me to help you format your personal wiki I can also help (using vitepress, currently writing my api wiki in it)
I am making my mod of making a gym into the ship and I am trying to sync everything but i get an error
Stack trace:
RuntimeNetcodeRPCValidator.FastBufferExtensions.WriteMethodInfoAndParameters (Unity.Netcode.FastBufferWriter fastBufferWriter, System.Reflection.MethodBase methodInfo, System.Object[] args) (at <0df0f351a5d94cbb9af1af6290fbdcfa>:IL_00CF)
RuntimeNetcodeRPCValidator.NetworkBehaviourExtensions.MethodPatchInternal (Unity.Netcode.NetworkBehaviour networkBehaviour, System.Reflection.MethodBase method, System.Object[] args) (at <0df0f351a5d94cbb9af1af6290fbdcfa>:IL_00A5)
RuntimeNetcodeRPCValidator.NetworkBehaviourExtensions.MethodPatch (Unity.Netcode.NetworkBehaviour __instance, System.Reflection.MethodBase __originalMethod, System.Object[] __args) (at <0df0f351a5d94cbb9af1af6290fbdcfa>:IL_0000)
(wrapper dynamic-method) BenchPress.DMD<BenchPress::OnEnterServerRpc>(BenchPress,GameNetcodeStuff.PlayerControllerB)
BenchPress.OnEnter (GameNetcodeStuff.PlayerControllerB player) (at <966b5a204c05406e993ca03271e0b863>:IL_0017)
UnityEngine.Events.InvokableCall`1[T1].Invoke (T1 args0) (at <e27997765c1848b09d8073e5d642717a>:IL_0010)
UnityEngine.Events.UnityEvent`1[T0].Invoke (T0 arg0) (at <e27997765c1848b09d8073e5d642717a>:IL_0025)
InteractTrigger+<specialInteractAnimation>d__61.MoveNext () (at <44743d9474784365a095189c76175301>:IL_0033)
UnityEngine.SetupCoroutine.InvokeMoveNext (System.Collections.IEnumerator enumerator, System.IntPtr returnValueAddress) (at <e27997765c1848b09d8073e5d642717a>:IL_0026)
UnityEngine.MonoBehaviour:StartCoroutine(IEnumerator)
InteractTrigger:Interact(Transform)
GameNetcodeStuff.PlayerControllerB:ClickHoldInteraction()
GameNetcodeStuff.PlayerControllerB:DMD<GameNetcodeStuff.PlayerControllerB::Update>(PlayerControllerB)
I have no idea how to fix this
Here are the rpcs with "playerInBench"
PlayerControllerB is not a serializable object, and there's not a method to easily serialize it since that happens during compile time;
try passing the playerClientId and get the player controller from that
Xilo
lol
Don't be so nice
xD
I wasn't gonna be shady or nuthin
But I did explain that in the readme
So I was gonna link it ๐
And the serialization article of NGO
Nw it's obscure, but the serialization article is nice
Espc if you've never set it up before
Lemme find it
Netcode uses a default serialization pipeline when using RPCs, NetworkVariables, or any other Netcode-related tasks that require serialization. The serialization pipeline looks like this:
Check that out @slow osprey
But I wonder
since you use system.serialization too (via json?) you can look at this too
https://docs.unity3d.com/Manual/script-Serialization.html
Since you can serialize a NetworkBehaviourReference
You could maybe just cast the PlayerCOntrollerB to that
And then tryGet
oh hmm
actually yeah that's the method
And I dont use json
I just serialize it to bytes
Just a slightly diff process than INetworkSerializable
That's the whole thing
For writing a Method identifier and it's parameters
I wasn't able to get writing to bytes to work for me (partially cause unity prims aren't serializable I think) as well as the ByteWritter isn't secure, so I went with json
the if (contains(INetworkSerializable)
else if (isSerializable is the dif
Sorry
Wrong
That's reading
That's writing
You can totz jack that code from FastBufferExtensions.cs on RNV git if you want @wintry plume
Lemme make sure license allows that
Pretty sure it did
If not we changing that bish
just a heads up
that you created a security leak and people can run malicious code over your stuff :)
im lazy
Worst case is a DoS
I.e. crash your shit
The preferred alternatives gives no alternative to serliazing out to a system serializable object
Cuz that's kinda not really security friendly anyways
But the real risk
Is that I'm writing a method name
But there's checks
SO it' should be fine
I clearly don't know enough about byteformmater or whatnot
still sticking with json though
cause it works
and I spent 2 fucking days trying to make it work
issue is that I only have 1 rpc for each (unless you can use INetworkSerializable object in an rpc, but I doubt)
also supports people just adding [Serializable] to their classes
INetworkSerializable are like for RPCs
I mean not really xD
But NGO does use them
RNV supports them
this method worked great thx ๐
I just had to deal with a similar issue and remember seeing something like that in game code
https://github.com/Xilophor/LethalNetworkAPI/blob/main/LethalNetworkAPI/LethalNetworkExtensions.cs
(self-promo)
Hey @wintry plume I'm workign on the article
I noticed you used nuget references to bepinex in the assemblies section
Do you care if I also suggest using @barren bones lethal gamelib?
<PackageReference Include="LethalCompany.GameLibs.Steam" Version="45.0.2-alpha.1" PrivateAssets="all"/>
Nice
where did i?
just interested
oh wait
I see
/dev/starting-a-mod
You also use UnityEngine.Modules
But that lacks some of the addon packages
Such as Netcode
and ofc LethalCompany specific stuff
But thankfully their GameLibs covers it ๐
Alright
@wintry plume
I'm removing System.Serializable
All it takes is one person to ruin it for everyone
One bad actor
me? :P
lol
i mean xD
You put it out there
GOt me reasearching
There's not allot
But i mean
Someone else gonna start digging now
Eventually someone will ruin it fs
Plus it really unifies it
Then it is just like NGO rpcs
- you can bind to preexisting networkbehaviours
Easier for the docs too
yeah
Hehehehe I'm clever
@wintry plume
See the bold
"Unity Netcode Patcher" "Patching" "Unitys Netcode"
"Runtime Netcode Validator" Runtime" "Validation" "Netcode"
Ps that lookin nice and neutral?
Like I'm not biased af
All information eh
looks good 
I like pivoting
Which that github link is a permalink to a the line-specific method https://github.com/NicholasScott1337/RuntimeNetcodeRPCValidator/blob/6e2f89b3631ae55d2f51a00ccfd3f20fec9d2372/RuntimeNetcodeRPCValidator/NetworkBehaviourExtensions.cs#L79
Just added some basic comments about how the snippet that's added works
looks good
it's good for quick start like 'i want this to build YESTERDAY' but not great when you want to go to definition
Oh, @torn schooner question, what happens when your thing is installed but a mod is already patched. I assume you account for that in some way?
Nothing good
I don't see a practical way to even detect that honestly
Just woke up but kinda considering depreciating RNV ๐ค
@junior sail Do you know if the patching does anything to the DLL besides adding the [RuntimeInitializeOnLoad] __initializeVariables method (and the obv RPC modification
Think I'm gonna utilize (Type).GetMethod("__initializeVariables", AccessTools.all).GetCustomAttributes<RuntimeInitializeOnLoad>().Any() to see if it's patched by NGO
Runtime Netcode Tools
Discussing Upcoming Changes
With Weaver reaching full maturity, thanks to the hard work of @junior sail & @barren bone, I've found the actual patching part of this API to be a moot point. While my instinct is to ko the repo, it still has some significant value in the method NetcodeValidator::BindToPreExistingObjectByBehaviour<TCustomBehaviour, TNativeBehaviour>() so I will be marking the whole package as depreciated and transitioning to a generic module for the above mentioned purpose. Sorry for the changes but please check out the process of compile-time patching using NGO's IL Post Processing facilitated by Evaisa's Unity Netcode Patcher
Sorry I wasn't home when i sent that
moot* btw @torn schooner :)
this sounds like a really great solution
to keep having the best of both worlds
The patcher has IL Post Processors for NetworkBehaviour, INetworkSerializable, and INetworkMessage
so will do stuff to all of those
for the record i did not intend to push your solution out of the way, i can't say the patching part didn't feel slightly redundant to me but the development is cool.
The reason i asked that question is because i worried what happens when there was mods installed that used netcodepatcher, and mods that used your thingy for patching.
I do think there is value in a solution which makes the other parts easier, such as what you mentioned
day's API is like harmony, you have to opt-in
it doesn't do anything automatically
ah that makes sense
in that case i don't see a reason to deprecate it
that was not my intention
i hate seeing cool projects get dropped, i never considered this a competition or anything
ehm
not especially
๐
tbf it would be pretty perfectly suited to being added to lcapi
i can, just gonna take a bit
we should probably leave the depreciation message here ๐คทโโ๏ธ
Discussing Upcoming Changes
With Weaver reaching full maturity, thanks to the hard work of @junior sail & @barren bone, I've found the actual patching part of this API to be a moot point. While my instinct is to ko the repo, it still has some significant value in the method NetcodeValidator::BindToPreExistingObjectByBehaviour<TCustomBehaviour, TNativeBehaviour>() so I will be marking the whole package as depreciated and transitioning to a generic module for the above mentioned purpose. Sorry for the changes but please check out the process of compile-time patching using NGO's IL Post Processing facilitated by Evaisa's Unity Netcode Patcher
yah that's all good man :)
๐ฌ
Discussing Upcoming Changes
With Weaver reaching full maturity, thanks to the hard work of @junior sail & @barren bone, I've found the actual patching part of this API to be a moot point. While my instinct is to ko the repo, it still has some significant value in the method NetcodeValidator::BindToPreExistingObjectByBehaviour<TCustomBehaviour, TNativeBehaviour>() so I will be marking the whole package as depreciated and transitioning to a generic module for the above mentioned purpose. Sorry for the changes but please check out the process of compile-time patching using NGO's IL Post Processing facilitated by Evaisa's Unity Netcode Patcher

Runtime Netcode Patcher
why ๐ญ
Huh
Follow my train (heh just finished playing derail valley) of thought, right
I reckoned that Evaisa's thing pretty much covered all bases
But there have been some issues with my transfer process
And appar people are still using RNV, despite my attempts to depreciate
(Including More Emotes which is kinda big)
Twas a bit of a passion project
Maybe I shouldn't kill it?
eba and I never wanted you to kill it
it's up to you what you do
it's a very cool thing
Ofc, I know no one does, I just hate being the source of so much confusion in the modding community
Thanks for the input โค๏ธ
on a separate note @torn schooner , UNP now supports embedded debug symbols!
it took some fuckn wrangling i'll tell u that lmao
also did u hear we broke the thunderstore decompiler
Oh reeeally?
certain mods would fail to decomp on thunderstore after being netcode patched
Oh no
I think because the IL code I was generating for the NetcodePatchedAttribute was completely invalid
so i've fixed that now
Hey Eba, did you have any input on this? if not nw ๐
we'll see on the next release of this mod
(assuming they update their netcodepatcher... which they might not)
Source don't exist
(Oh speaking of, @barren bone the problem with patching net 4.7.2 still consistently shows up, check #dev-general )
yeah idk what i can do about this
i could try including polysharp?
i don't mind, i've always liked variety, it isn't a competition, more angles brings more knowledge
The biggest problem was naming scheme, with you calling your thing runtime netcode patcher
I'm honestly open to rebranding mine
I'm bad at names and gave it an accurate descriptor lmao
@barren bone for some reason the plugin info references for RNV don't get decompiled on thunderstore source either
names are not my strong suit either
So where is this attribute?
Well
U wanna VC?
actually dwai i can show u
If I'm gonna continue, I'd like to avoid confusion by supporting a user utilizing both UNP and RNV (for RNV features but also just avoid issues) by not patching already patched methods
AH ok
wait
attributetargets.class??
I can certainly check if the type contains a [RuntimeInitializeOnLoad] void __initializeVariables but that may not be the most robust way
that's not right
Lol
Basically
Check if the assembly has a custom attribute whose full name is [AssemblyName].NetcodePatcher.NetcodePatchedAssemblyAttribute
I'd also really like to know what all these Post Processors are actually doing
Where can I find these definitions @barren bone
NGO sourcecode
It seems it doesn't actually do anything to the INetworkSErializable
Sorry ye
Found it โค๏ธ
Just error checking it seems
Does some real chicanery w/ the INetworkMessage
@junior sail ?
name?
fine with me, tho might be a tad misleading as it does more than just validating no?
Right, so Runtime Netcode Utilities with a .Patching namespace that features the harmony patcher and I can do my other fancy stuff, which makes sense cause it can be used w/ ur patcher
Tysm for the guidance
who should i ask for bugs with RuntimeNetcodePatcher?
apparently NetworkObjectReference[] does not get marked as NetcodeSerializable and thorws an error
@torn schooner maybe as OP you know how to avoid it ๐ค
@barren bone apparently you are lordFire i did not know
have any idea about this problem? (#dev-general message - slient ping on suggestion from here)
Day (Little Llama) made Runtime Netcode Validator, lordfire maintains unity netcode patcher
๐ then definitely lordfire to ask
need to pass NetworkObjectReference[] to an Rpc as StartOfRound.SyncAlreadyHeldObjectsClientRpc does, but at runtime the Patcher complains it is not Serializzable
use unity NetCode patcher instead at compile time
and it's from a time where the compile time patcher was harder to use
do you have a link for the compile time one?
recommend you
- follow the 'prepare' steps
- install the CLI
- do the 'usage as post build target'
MSBuild would be great but it's broken rn
uhm ok i guess better move out of this channel, do you mind if i ask you more in https://discord.com/channels/1168655651455639582/1211989201793449994 ?
not at all, go ahead