Page 1 of 1

Question about Room and Zone Extention variables

Posted: 22 Jun 2009, 00:59
by xMoMx
I'm getting confused about Zone and Room variables.

if I declare a variables at the Zone extention and update it from one of the room, does it get update for all the rooms inside the same zone? (In other word, do all the rooms share the same variables from zone Extention?)

And what about variable from Room Extention?

Posted: 23 Jun 2009, 11:06
by xMoMx
I'm so confused... not getting any of this from reading all the provided documents. I kinda draw conclusion from the examples and here's what I get ->

1. Any variables declaring from Zone and Room Extensions are created anew everytime a new room is created, not when the server started.

2. Only those declared as RoomVariables send update respense to users.

3. Zone and Room can only send variables to each other with handleInternalRequest. This add to CPU loaded and should it be avoid when possible.

4. Init are called once, when the server started.

Is this right? :oops:

Posted: 24 Jun 2009, 00:52
by xMoMx
Answering my own Q.

1. No. Variables inside Zone extension are created once, and can only be changed with its own internal logic. Same thing with variables that are declared inside room extension (and not defined as 'room variables') are created once upon the script initialized, not when room are created.

Only 'room variables' are created anew once a room is newly created.

Am I getting close?

Question is, how do I create Room internal variables that do not send update to the clients?