Hello everyone.
I have a MMORoom with MMOItems (which are enemies in my game).
I send updates of the enemy movements to clients using MMOApi.setMMOItemVariables
However, I'd like to know what would be the best way of telling the clients that an enemy is attacking or doing certain actions.
Is it the best way to retrieve the users of the enemy (MMOItem) AOI using getProximityList(), and then sending each of those users a message from the server?
If so, how could I do that? How can I send a message from the server to a list of users?
Thanks in advance!
MMORoom: Send Message from server to users in MMOItem AOI
Re: MMORoom: Send Message from server to users in MMOItem AOI
Hi,
you could use the ItemVariables themselves, and setting one (or more) attribute that tells the client that this particular foe is attacking.
When you receive the VariableUpdate on the client side you can always check what are the variables that were changed in this particular update, so if the "attack" variable was changed you know the enemy is shooting or throwing stones or whatever
Cheers
you could use the ItemVariables themselves, and setting one (or more) attribute that tells the client that this particular foe is attacking.
When you receive the VariableUpdate on the client side you can always check what are the variables that were changed in this particular update, so if the "attack" variable was changed you know the enemy is shooting or throwing stones or whatever
Cheers
Who is online
Users browsing this forum: No registered users and 105 guests