C# Class SteamBot.AdminUserHandler

A user handler class that implements basic text-based commands entered in chat or trade chat.
Inheritance: UserHandler
Mostrar archivo Open project: natoshi/steamdogebot

Public Methods

Method Description
AdminUserHandler ( Bot bot, SteamID sid ) : System
OnAcceptedFriend ( SteamID id ) : void
OnAddedFriend ( SteamID id ) : void
OnFriendAdd ( ) : bool

Called when a the user adds the bot as a friend.

OnFriendRemove ( ) : void
OnGroupAdd ( ) : bool

Triggered when a clan invites the bot.

OnLoginCompleted ( ) : bool

Called when the bot is fully logged in.

OnMessage ( string message, EChatEntryType type ) : void

Called whenever a message is sent to the bot. This is limited to regular and emote messages.

OnTradeAccept ( ) : void
OnTradeAddItem ( Schema schemaItem, Inventory inventoryItem ) : void
OnTradeError ( string error ) : void
OnTradeInit ( ) : void
OnTradeMessage ( string message ) : void
OnTradeReady ( bool ready ) : void
OnTradeRemoveItem ( Schema schemaItem, Inventory inventoryItem ) : void
OnTradeRequest ( ) : bool

Called whenever a user requests a trade.

OnTradeSuccess ( ) : void
OnTradeTimeout ( ) : void

Private Methods

Method Description
AddAllItems ( ) : void
AddCrateBySeries ( string series, uint amount ) : void
AddItemsByCraftType ( string typeToAdd, uint amount ) : void
GetAddAmount ( string data ) : uint
GetSubCommand ( string data, string &subCommand ) : bool
HandleAddCommand ( string command ) : void
HandleRemoveCommand ( string command ) : void
PrintHelpMessage ( ) : void
ProcessTradeMessage ( string message ) : void

Method Details

AdminUserHandler() public method

public AdminUserHandler ( Bot bot, SteamID sid ) : System
bot Bot
sid SteamKit2.SteamID
return System

OnAcceptedFriend() public method

public OnAcceptedFriend ( SteamID id ) : void
id SteamKit2.SteamID
return void

OnAddedFriend() public method

public OnAddedFriend ( SteamID id ) : void
id SteamKit2.SteamID
return void

OnFriendAdd() public method

Called when a the user adds the bot as a friend.
public OnFriendAdd ( ) : bool
return bool

OnFriendRemove() public method

public OnFriendRemove ( ) : void
return void

OnGroupAdd() public method

Triggered when a clan invites the bot.
public OnGroupAdd ( ) : bool
return bool

OnLoginCompleted() public method

Called when the bot is fully logged in.
public OnLoginCompleted ( ) : bool
return bool

OnMessage() public method

Called whenever a message is sent to the bot. This is limited to regular and emote messages.
public OnMessage ( string message, EChatEntryType type ) : void
message string
type EChatEntryType
return void

OnTradeAccept() public method

public OnTradeAccept ( ) : void
return void

OnTradeAddItem() public method

public OnTradeAddItem ( Schema schemaItem, Inventory inventoryItem ) : void
schemaItem Schema
inventoryItem Inventory
return void

OnTradeError() public method

public OnTradeError ( string error ) : void
error string
return void

OnTradeInit() public method

public OnTradeInit ( ) : void
return void

OnTradeMessage() public method

public OnTradeMessage ( string message ) : void
message string
return void

OnTradeReady() public method

public OnTradeReady ( bool ready ) : void
ready bool
return void

OnTradeRemoveItem() public method

public OnTradeRemoveItem ( Schema schemaItem, Inventory inventoryItem ) : void
schemaItem Schema
inventoryItem Inventory
return void

OnTradeRequest() public method

Called whenever a user requests a trade.
public OnTradeRequest ( ) : bool
return bool

OnTradeSuccess() public method

public OnTradeSuccess ( ) : void
return void

OnTradeTimeout() public method

public OnTradeTimeout ( ) : void
return void