SmartlyDressedGames / Unturned-Docs

Documentation for Unturned's modding features.
135 stars 49 forks source link

Event hooks that fire on server #308

Closed yehuuu6 closed 4 months ago

yehuuu6 commented 4 months ago

I've been creating mods since 2018 I think, and the most challenging aspects have involved dealing with multiplayer functionality. Some features weren't triggering on the server due to perceived inadequacies in mod hooks. Let's talk about the activation event hook. Currently, it executes its orders on either the server or the client, depending on the game object it's attached to. For instance, if I attach it to the Siren game object, it fires the events on the server; otherwise, it only triggers them for the client. This can and is making modders' lives difficult. Perhaps we could consider adding a new option to the activation event hook, such as "use on server," which ensures that the event is fired on the server when checked. Are there any plans for implementing something like this in the future? Or you already did and I'm just unaware of it?

MoltonMontro commented 4 months ago

It sounds like you're trying to suggest a new modding feature (or ask how to best implement a feature), but this repository is for the documentation of modding features.

Consider posting suggestions to another location, such as the forums (or in the Discussions section of the community repo) instead.