| entity - any entity |
|
Returns the player id of a shared entity's owner, or 0 if it is not shared. Each shared entity is controlled by one player: a character by its player, and every other shared entity by the host. Only the owner should move, animate or simulate it; everyone else's copy follows the owner's. SharedEntityLocal and SharedEntityRemote answer the usual question, mine or theirs, directly. In a server room the server owns every entity, and SharedEntityOwner returns 0 for each of them. For the full story - services, hosting, sharing and host migration - see the Shared World guide and its complete Shared_World_Playground.bb sample. See also: SharedEntityLocal, SharedEntityRemote, SharedEntityID, SharedHostPlayer. |