C# Class YGOSharp.Game

Inheritance: IGame
Afficher le fichier Open project: IceYGO/ygosharp Class Usage Examples

Méthodes publiques

Свойство Type Description
DuelCount int

Méthodes publiques

Méthode Description
AddPlayer ( Player player ) : void
Chat ( Player player, string msg ) : void
CustomMessage ( Player player, string msg ) : void
End ( ) : void
EndDuel ( bool force ) : void
Game ( CoreServer server ) : System
HandResult ( Player player, int result ) : void
KickPlayer ( Player player, int pos ) : void
MatchIsEnd ( ) : bool
MatchKill ( ) : void
MatchSaveResult ( int player, int reason ) : void
MatchSide ( ) : void
MoveToDuelist ( Player player ) : void
MoveToObserver ( Player player ) : void
RefreshAll ( ) : void
RefreshAllObserver ( Player observer ) : void
RefreshExtra ( int player, int flag = 0x81fff ) : void
RefreshGrave ( int player, int flag = 0x81fff, Player observer = null ) : void
RefreshHand ( int player, int flag = 0x181fff, Player observer = null ) : void
RefreshMonsters ( int player, int flag = 0x81fff, Player observer = null ) : void
RefreshSingle ( int player, int location, int sequence, int flag = 0x781fff ) : void
RefreshSpells ( int player, int flag = 0x681fff, Player observer = null ) : void
RemovePlayer ( Player player ) : void
SendToAll ( BinaryWriter packet ) : void
SendToAllBut ( BinaryWriter packet, Player except ) : void
SendToAllBut ( BinaryWriter packet, int except ) : void
SendToObservers ( BinaryWriter packet ) : void
SendToPlayers ( BinaryWriter packet ) : void
SendToTeam ( BinaryWriter packet, int team ) : void
SetReady ( Player player, bool ready ) : void
SetResponse ( byte resp ) : void
SetResponse ( int resp ) : void
SetRules ( BinaryReader packet ) : void
Start ( ) : void
StartDuel ( Player player ) : void
Stop ( ) : void
Surrender ( Player player, int reason, bool force = false ) : void
TimeReset ( ) : void
TimeStart ( ) : void
TimeStop ( ) : void
TimeTick ( ) : void
TpResult ( Player player, bool result ) : void
WaitForResponse ( ) : int
WaitForResponse ( int player ) : void

Private Methods

Méthode Description
CalculateWinner ( ) : void
GetAvailablePlayerPos ( ) : int
HandleError ( string error ) : void
InitNewSpectator ( Player player ) : void
Process ( ) : void
SendDuelingPlayers ( Player player ) : void
SendHand ( ) : void
SendJoinGame ( Player player ) : void
ShuffleCards ( Random rand, IEnumerable cards ) : List

Method Details

AddPlayer() public méthode

public AddPlayer ( Player player ) : void
player Player
Résultat void

Chat() public méthode

public Chat ( Player player, string msg ) : void
player Player
msg string
Résultat void

CustomMessage() public méthode

public CustomMessage ( Player player, string msg ) : void
player Player
msg string
Résultat void

End() public méthode

public End ( ) : void
Résultat void

EndDuel() public méthode

public EndDuel ( bool force ) : void
force bool
Résultat void

Game() public méthode

public Game ( CoreServer server ) : System
server CoreServer
Résultat System

HandResult() public méthode

public HandResult ( Player player, int result ) : void
player Player
result int
Résultat void

KickPlayer() public méthode

public KickPlayer ( Player player, int pos ) : void
player Player
pos int
Résultat void

MatchIsEnd() public méthode

public MatchIsEnd ( ) : bool
Résultat bool

MatchKill() public méthode

public MatchKill ( ) : void
Résultat void

MatchSaveResult() public méthode

public MatchSaveResult ( int player, int reason ) : void
player int
reason int
Résultat void

MatchSide() public méthode

public MatchSide ( ) : void
Résultat void

MoveToDuelist() public méthode

public MoveToDuelist ( Player player ) : void
player Player
Résultat void

MoveToObserver() public méthode

public MoveToObserver ( Player player ) : void
player Player
Résultat void

RefreshAll() public méthode

public RefreshAll ( ) : void
Résultat void

RefreshAllObserver() public méthode

public RefreshAllObserver ( Player observer ) : void
observer Player
Résultat void

RefreshExtra() public méthode

public RefreshExtra ( int player, int flag = 0x81fff ) : void
player int
flag int
Résultat void

RefreshGrave() public méthode

public RefreshGrave ( int player, int flag = 0x81fff, Player observer = null ) : void
player int
flag int
observer Player
Résultat void

RefreshHand() public méthode

public RefreshHand ( int player, int flag = 0x181fff, Player observer = null ) : void
player int
flag int
observer Player
Résultat void

RefreshMonsters() public méthode

public RefreshMonsters ( int player, int flag = 0x81fff, Player observer = null ) : void
player int
flag int
observer Player
Résultat void

RefreshSingle() public méthode

public RefreshSingle ( int player, int location, int sequence, int flag = 0x781fff ) : void
player int
location int
sequence int
flag int
Résultat void

RefreshSpells() public méthode

public RefreshSpells ( int player, int flag = 0x681fff, Player observer = null ) : void
player int
flag int
observer Player
Résultat void

RemovePlayer() public méthode

public RemovePlayer ( Player player ) : void
player Player
Résultat void

SendToAll() public méthode

public SendToAll ( BinaryWriter packet ) : void
packet System.IO.BinaryWriter
Résultat void

SendToAllBut() public méthode

public SendToAllBut ( BinaryWriter packet, Player except ) : void
packet System.IO.BinaryWriter
except Player
Résultat void

SendToAllBut() public méthode

public SendToAllBut ( BinaryWriter packet, int except ) : void
packet System.IO.BinaryWriter
except int
Résultat void

SendToObservers() public méthode

public SendToObservers ( BinaryWriter packet ) : void
packet BinaryWriter
Résultat void

SendToPlayers() public méthode

public SendToPlayers ( BinaryWriter packet ) : void
packet BinaryWriter
Résultat void

SendToTeam() public méthode

public SendToTeam ( BinaryWriter packet, int team ) : void
packet BinaryWriter
team int
Résultat void

SetReady() public méthode

public SetReady ( Player player, bool ready ) : void
player Player
ready bool
Résultat void

SetResponse() public méthode

public SetResponse ( byte resp ) : void
resp byte
Résultat void

SetResponse() public méthode

public SetResponse ( int resp ) : void
resp int
Résultat void

SetRules() public méthode

public SetRules ( BinaryReader packet ) : void
packet BinaryReader
Résultat void

Start() public méthode

public Start ( ) : void
Résultat void

StartDuel() public méthode

public StartDuel ( Player player ) : void
player Player
Résultat void

Stop() public méthode

public Stop ( ) : void
Résultat void

Surrender() public méthode

public Surrender ( Player player, int reason, bool force = false ) : void
player Player
reason int
force bool
Résultat void

TimeReset() public méthode

public TimeReset ( ) : void
Résultat void

TimeStart() public méthode

public TimeStart ( ) : void
Résultat void

TimeStop() public méthode

public TimeStop ( ) : void
Résultat void

TimeTick() public méthode

public TimeTick ( ) : void
Résultat void

TpResult() public méthode

public TpResult ( Player player, bool result ) : void
player Player
result bool
Résultat void

WaitForResponse() public méthode

public WaitForResponse ( ) : int
Résultat int

WaitForResponse() public méthode

public WaitForResponse ( int player ) : void
player int
Résultat void

Property Details

DuelCount public_oe property

public int DuelCount
Résultat int