- Home /
Cmd on a runtime created object
Hi, I have a project for an online game. https://github.com/Fermivor/SheepIt2 I have some character wich have some power. My player,Instancied by the NetworkManager, got a reference to a class wich handle logic for the special ability of the character selected. So my abilities code got a function "Ability1(){}" When a client trigger this function (by click on "A" for exemple), I would like to execute a code on the server. I don't find how handle logic, I would like the player didn't know all the possibility of the abilities to keep it separate from those code.
So I would like to make Ability capable to handle command call. But I don't find how to make aclass capable to handle command except the players objects created by the NetworkManager
Is it a mean to do that or I search to complicated?
Thank
Your answer
Follow this Question
Related Questions
"Trying to send command for object without authority" warning but the object is the localPlayer 1 Answer
Unity Networking client interaction with scene not displayed on other client. Commands and RPCs 0 Answers
Non player objects movements are not syncronized on server 0 Answers