This code example should work on any version of ES5 that is 5.2.3 or later, but it was tested using our current development build. Features include:
- User chooses an avatar to use
- User chooses a chat topic (gameType)
- Server remembers the choices for a reasonable amount of time after the user logs off
- Room plugin remembers game specific information (position) for a reasonable amount of time after the user leaves the room
download the zip
live example
Please do let me know of any bugs.
I plan to write a tutorial on this later. In the meantime:
- Compile and deploy the extension.
- There is one server level component: RejoinGameServerLevel. Don't make AvatarChatWithRejoin server level; that's room level.
- You can customize the chat room topics in Extension.xml. There's no limit to the number of topics other than how many you can display to the user at once.
- You can specify the capacity of the chat rooms in Extension.xml. I have it set at 10.
- minutesToKeepDataAfterUserLeft and minutesToCheckForCulling specify how long a given plugin waits before removing stale data.
edit on July 2nd:
A Unity client has been added to the zip. This client does not give a choice of avatar, but does have the functionality for the various chat room topics. While in a chat room, to switch to a different one, press Enter (same as you do to public chat) and the buttons will appear.


Reply With Quote
