本文整理汇总了C#中IGame.ResetArenaCards方法的典型用法代码示例。如果您正苦于以下问题:C# IGame.ResetArenaCards方法的具体用法?C# IGame.ResetArenaCards怎么用?C# IGame.ResetArenaCards使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IGame
的用法示例。
在下文中一共展示了IGame.ResetArenaCards方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Handle
public void Handle(string logLine, IHsGameState gameState, IGame game)
{
if(!logLine.Contains("---Register"))
return;
if(logLine.Contains("---RegisterScreenBox---"))
{
if(game.CurrentGameMode == GameMode.Spectator)
gameState.GameEnd();
}
else if(logLine.Contains("---RegisterScreenForge---"))
{
gameState.GameHandler.SetGameMode(GameMode.Arena);
game.ResetArenaCards();
}
else if(logLine.Contains("---RegisterScreenPractice---"))
gameState.GameHandler.SetGameMode(GameMode.Practice);
else if(logLine.Contains("---RegisterScreenTourneys---"))
gameState.GameHandler.SetGameMode(GameMode.Casual);
else if(logLine.Contains("---RegisterScreenFriendly---"))
gameState.GameHandler.SetGameMode(GameMode.Friendly);
else if(logLine.Contains("---RegisterProfileNotices---"))
gameState.GameLoaded = true;
else if(logLine.Contains("---RegisterFriendChallenge---"))
{
gameState.GameHandler.HandleInMenu();
}
else if(logLine.Contains("---RegisterScreenCollectionManager---"))
gameState.GameHandler.ResetConstructedImporting();
}
示例2: Handle
public void Handle(string logLine, IHsGameState gameState, IGame game)
{
if (logLine[9] != 'R' && logLine[16] != 'r') // [Bob] ---Register
return;
if (logLine.Length == 29 && logLine[23] == 'B' && logLine[25] == 'x') // ---RegisterScreenBox---
{
if (game.CurrentGameMode == GameMode.Spectator)
gameState.GameEnd();
}
else if (logLine.Length == 31 && logLine[23] == 'F' && logLine[27] == 'e') // ---RegisterScreenForge---
{
gameState.GameHandler.SetGameMode(GameMode.Arena);
game.ResetArenaCards();
}
else if (logLine.Length == 34)
{
if (logLine[23] == 'P' && logLine[30] == 'e') // ---RegisterScreenPractice---
gameState.GameHandler.SetGameMode(GameMode.Practice);
else if (logLine[23] == 'T' && logLine[30] == 's') // ---RegisterScreenTourneys---
gameState.GameHandler.SetGameMode(GameMode.Casual);
else if (logLine[23] == 'F' && logLine[30] == 'y') // ---RegisterScreenFriendly---
gameState.GameHandler.SetGameMode(GameMode.Friendly);
else if (logLine[23] == 'e' && logLine[24] == 'N' && logLine[30] == 's') // RegisterProfileNotices
gameState.GameLoaded = true;
}
else if (logLine.Length == 35 && logLine[17] == 'F' && logLine[22] == 'd' && logLine[23] == 'C') // RegisterFriendChallenge
{
gameState.GameHandler.HandleInMenu();
}
else if (logLine.Length == 43 && logLine[23] == 'C' && logLine[32] == 'n' && logLine[33] == 'M' && logLine[39] == 'r')// ---RegisterScreenCollectionManager---
gameState.GameHandler.ResetConstructedImporting();
}
示例3: Handle
public void Handle(string logLine, IHsGameState gameState, IGame game)
{
var match = HsLogReaderConstants.GameModeRegex.Match(logLine);
if(!match.Success)
return;
game.CurrentMode = GetMode(match.Groups["curr"].Value);
game.PreviousMode = GetMode(match.Groups["prev"].Value);
var newMode = GetGameMode(game.CurrentMode) ?? GetGameMode(game.PreviousMode);
if(newMode.HasValue && !(game.CurrentGameMode == Ranked && newMode.Value == Casual))
game.CurrentGameMode = newMode.Value;
if(game.PreviousMode == Mode.GAMEPLAY)
gameState.GameHandler.HandleInMenu();
switch(game.CurrentMode)
{
case Mode.COLLECTIONMANAGER:
case Mode.TAVERN_BRAWL:
gameState.GameHandler.ResetConstructedImporting();
break;
case Mode.DRAFT:
game.ResetArenaCards();
break;
}
}