HeroEngine Forums

HeroEngine Support => Scripting & Programming => Topic started by: Jrome90 on Jul 20, 12, 06:25:57 PM

Title: [Resolved] proxy nodes
Post by: Jrome90 on Jul 20, 12, 06:25:57 PM
I was able to replicate nodes from a system area, to a client in a different area successfully. That was easy :)

But I am curious if it is possible to add another client to recieve the replicated node if the node to be replicated is in a different area than they are currently in.

The above probably doesn't make sense.

Here is an example:

A node was created in the same area as PLAYER A

PLAYER B is in a different area, and needs that node in PLAYER A's area to be replicated to him.

Would you use proxy nodes?
Title: Re: proxy nodes
Post by: HE-JAY on Jul 23, 12, 10:36:09 AM
System areas (http://hewiki.heroengine.com/wiki/System_Areas) - by virtue of being registered to receive player updates - have access to all currently-logged-in players' reference tokens (http://hewiki.heroengine.com/wiki/Player_Reference_Token). This allows the system area to communicate directly with the player, regardless of which area they're in.  From such a system area, you can freely replicate and remote-call to a client, bypassing the need to replicate first to their area and then to their client. You could - alternatively - use proxies to replicate first to their area and then to their client, but that would entail additional bookkeeping.