ElectroServer 5 Client: C#
Electrotank.Electroserver5.Api.EvictUserFromRoomRequest Class Reference

By default, the first client joined to a room is the room operator. More...

Inheritance diagram for Electrotank.Electroserver5.Api.EvictUserFromRoomRequest:
Electrotank.Electroserver5.Api.EsRequest Electrotank.Electroserver5.Api.EsMessage Electrotank.Electroserver5.Api.IThriftSerializable

Public Member Functions

 EvictUserFromRoomRequest ()
 
 EvictUserFromRoomRequest (TBase t)
 
override TBase ToThrift ()
 
override TBase NewThrift ()
 
override void FromThrift (TBase t_)
 

Properties

int ZoneId [get, set]
 Id of the zone that contains the room that contains the user. More...
 
int RoomId [get, set]
 Id of the room that contains the user. More...
 
string UserName [get, set]
 
string Reason [get, set]
 Reason for the kick or ban. More...
 
bool Ban [get, set]
 Set to true if the user should be banned as well. More...
 
int Duration [get, set]
 The duration of the ban. More...
 

Detailed Description

By default, the first client joined to a room is the room operator.

When the client leaves the room the operator status goes to the next person that has joined the room. As a room operator a client can kick users from the room or ban them from the server, provided the operator's user permissions (as set in ES Admin) allow this to be done. If the kick succeeds, all users in the room get a UserEvictedFromRoomEvent giving the name of the user kicked and the reason.

var eur:EvictUserFromRoomRequest = new EvictUserFromRoomRequest();
eur.userName = userToKick;
eur.ban = false;
eur.duration = -1;
eur.roomId = _room.id;
eur.zoneId = _room.zoneId;
eur.reason = "you smell";
_es.engine.send(eur);

Constructor & Destructor Documentation

Electrotank.Electroserver5.Api.EvictUserFromRoomRequest.EvictUserFromRoomRequest ( )
Electrotank.Electroserver5.Api.EvictUserFromRoomRequest.EvictUserFromRoomRequest ( TBase  t)

Member Function Documentation

override void Electrotank.Electroserver5.Api.EvictUserFromRoomRequest.FromThrift ( TBase  t_)
virtual
override TBase Electrotank.Electroserver5.Api.EvictUserFromRoomRequest.NewThrift ( )
virtual
override TBase Electrotank.Electroserver5.Api.EvictUserFromRoomRequest.ToThrift ( )
virtual

Property Documentation

bool Electrotank.Electroserver5.Api.EvictUserFromRoomRequest.Ban
getset

Set to true if the user should be banned as well.

int Electrotank.Electroserver5.Api.EvictUserFromRoomRequest.Duration
getset

The duration of the ban.

string Electrotank.Electroserver5.Api.EvictUserFromRoomRequest.Reason
getset

Reason for the kick or ban.

The target user receives this reason.

int Electrotank.Electroserver5.Api.EvictUserFromRoomRequest.RoomId
getset

Id of the room that contains the user.

string Electrotank.Electroserver5.Api.EvictUserFromRoomRequest.UserName
getset
int Electrotank.Electroserver5.Api.EvictUserFromRoomRequest.ZoneId
getset

Id of the zone that contains the room that contains the user.