com.electrotank.electroserver4.extensions
Interface RoomUserEvents

All Known Implementing Classes:
BasePlugin

public interface RoomUserEvents

Interface for a custom event handler for room user events. A plugin that implements this interface will trigger the appropriate method when a user in the room does the action.


Method Summary
 void userBanned(String userName, String message, int duration)
          Actions triggered when a user is banned from the server.
 ChainAction userEnter(UserEnterContext context)
          Actions triggered when a user enters the room.
 void userExit(String userName)
          Actions triggered when a user exits the room.
 void userKicked(String userName, String message)
          Actions triggered when a user is kicked from a room.
 ChainAction userSendPublicMessage(UserPublicMessageContext message)
          Actions triggered when a user sends a public message.
 

Method Detail

userEnter

ChainAction userEnter(UserEnterContext context)
Actions triggered when a user enters the room.

Parameters:
context - UserEnterContext
Returns:
ChainAction.OkAndContinue for a successful entry
See Also:
"PluginUserEnterAndExit example plugin"

userSendPublicMessage

ChainAction userSendPublicMessage(UserPublicMessageContext message)
Actions triggered when a user sends a public message.

Parameters:
message - UserPublicMessageContext
Returns:
ChainAction.OkAndContinue for a successful message
See Also:
"PluginPigLatin example plugin"

userExit

void userExit(String userName)
Actions triggered when a user exits the room.

Parameters:
userName - user who left
See Also:
"PluginUserEnterAndExit example plugin"

userKicked

void userKicked(String userName,
                String message)
Actions triggered when a user is kicked from a room.

Parameters:
userName - user who was kicked
message - reason for the kick

userBanned

void userBanned(String userName,
                String message,
                int duration)
Actions triggered when a user is banned from the server.

Parameters:
userName - user who was banned
message - reason for the ban
duration - duration of the ban in seconds


Copyright © 2007 Electrotank, Inc. All Rights Reserved.