Triggers a fake auto teams event that apparently originated from the player whose id is byId.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake leave/kick/ban event for the player whose id is playerId that apparently originated from the player whose id is byId.
Id of the player who will leave the room. (Or get kicked/banned from the room.)
The reason of kick/ban. If null, it is interpreted as he/she leaving by himself/herself, and the ban value is ignored in that case.
Whether the player is being banned or not.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake join room event; which in turn creates a new in-memory player object. If there was a player before with this id, old resources are automatically reassigned to this new player object, and that player will wake up.
Id of the player. 0 <= id <= 65535
Name of the player.
Country code of the player.
Avatar of the player.
Connection string of the player.
Auth string of the player.
void.
Triggers a fake leave room event. The player, although seemingly leaving the room, still watches the room, waiting for a new fake player join event. All parameters except id may be different in the new fakePlayerJoin call, which allows player's name, flag, avatar, conn and auth to change without the player entirely leaving the room.
fakePlayerJoin at a later time to re-insert that player.Id of the player leaving. id=0 will cause desync on clients. (Because there's a special check for this case in original clients.)
An object that has the following strucure: { id: uint16, name: string, flag: string, avatar: string, conn: string, auth: string }.
Triggers a fake chat event that apparently originated from the player whose id is byId.
The chat message.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake input(keys) event that apparently originated from the player whose id is byId.
New input value of the player. 0<=input<=31.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake game pause/resume event that apparently originated from the player whose id is byId. The game must be started first.
value=true: pause, false: resume.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake kick rate limit change event that apparently originated from player(byId).
The new min part of kick rate limit. min>=0.
The new rate part of kick rate limit. rate>=0.
The new burst part of kick rate limit. burst>=0.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake admin status change event for the player whose id is playerId that apparently originated from the player whose id is byId.
Id of the player who will have his/her admin rights changed.
Whether the player is desired to have admin rights or not.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake avatar change event that apparently originated from the player whose id is byId.
The new avatar of the player.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake chat indicator change event that apparently originated from the player whose id is byId.
The new chat indicator status of the player.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake player sync status change event that apparently originated from the player whose id is byId.
The new synchronization status of the player.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake player team change event for the player whose id is playerId that apparently originated from the player whose id is byId.
Id of the player whose team is being changed.
Id of the desired team of the player. 0: specetator, 1: red, 2: blue.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake score limit change event that apparently originated from the player whose id is byId.
The new score limit of the current room. The game must be stopped first. 0 means unlimited. 0<=value<=99.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake stadium change event that apparently originated from the player whose id is byId. The game must be stopped first.
The new stadium of the current room.
Id of the player who will look like he/she sent this event.
Triggers a team color change event for the team whose id is teamId that apparently originated from the player whose id is byId.
Id of the team whose colors are desired to change.
The angle of stripes for the inner colors. Should be between 0 and 180.
This array can contain minimum 2, maximum 4 numeric (0 <= integer <= 16777215) values. The first element is the text color and the rest are inner stripe colors.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake teams lock change event that apparently originated from the player whose id is byId.
The new teams lock value of the current room.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake time limit change event that apparently originated from the player whose id is byId.
The new time limit of the current room. The game must be stopped first. 0 means unlimited. 0<=value<=99.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake game start event that apparently originated from the player whose id is byId.
Id of the player who will look like he/she sent this event.
void.
Triggers a fake game stop event that apparently originated from the player whose id is byId. The game must be started first.
Id of the player who will look like he/she sent this event.
void.
These functions are intended to be used in host mode to create/control in-memory bot players that will run much more efficiently than standard networking bot players. They also work for normal player objects, and can be used to create some events belonging to a player that did not originate from that player. Most of these fake events also trigger an
onOperationReceivedcall before being sent to clients.