|
name$ - a stick named with DefineSharedStick x# - from -1 (left) to 1 (right) y# - from -1 (down) to 1 (up) |
|
Sets your own player's stick from your own input code. Use it when your game reads its controls itself - mouse steering, a tilt, a touch gesture - and the server should see the result. The stick keeps the value until you set it again, and keys bound to the stick take over while one of them is held. A value outside the unit circle is brought back to it. On a client in a server room the stick goes to the server, which reads it with SharedStickX and SharedStickY. Elsewhere it is simply this copy's own stick: SharedStickX(SharedLocalPlayer(),name$) reads it back. For the full story - server rooms, hosting, sharing and host migration - see the Shared World guide and its complete Shared_World_Playground.bb sample. See also: DefineSharedStick, SharedStickX, SetSharedButton, SetSharedBotStick. |