Exemple #1
0
        public JassGameRound CreateOneRound()
        {
            var allCards = new List <JassCard>(JassCard.CompleteSet);

            var player1 = new JassPlayer("Player 1");
            var player2 = new JassPlayer("Player 2");
            var player3 = new JassPlayer("Player 3");
            var player4 = new JassPlayer("Player 4");

            var players = new List <JassPlayer>
            {
                player1,
                player2,
                player3,
                player4
            };

            while (allCards.Count > 0)
            {
                var randomCardIndex = RandomSingleton.Instance.Next(allCards.Count);
                var card            = allCards.ElementAt(randomCardIndex);
                allCards.RemoveAt(randomCardIndex);

                var playerWithoutNineCards = players.First(f => f.JassHand.Cards.Count < 9);
                playerWithoutNineCards.JassHand.AddCard(card);
            }

            player1.AssignPartner(player3);
            player2.AssignPartner(player4);
            player3.AssignPartner(player1);
            player4.AssignPartner(player2);

            return(new JassGameRound(players));
        }
Exemple #2
0
 private static JassRealRet RequestExtraRealData(JassInteger dataType, JassPlayer whichPlayer, JassStringArg param1, JassStringArg param2, JassBoolean param3, JassInteger param4, JassInteger param5, JassInteger param6) => 0;
Exemple #3
0
 private static JassStringRet RequestExtraStringData(JassInteger dataType, JassPlayer whichPlayer, JassStringArg param1, JassStringArg param2, JassBoolean param3, JassInteger param4, JassInteger param5, JassInteger param6) => string.Empty;
Exemple #4
0
 private static JassStringRet DzAPI_Map_GetGuildName(JassPlayer whichPlayer) => string.Empty;
Exemple #5
0
 public virtual void CreateCorpseCallback(JassUnit unit, JassPlayer owner, JassObjectId id, Single x, Single y, Single facing)
 {
 }
Exemple #6
0
 private static JassInteger DzAPI_Map_GetLadderRank(JassPlayer whichPlayer) => 0;
Exemple #7
0
 private static JassInteger DzAPI_Map_GetServerValueErrorCode(JassPlayer whichPlayer) => 0;
Exemple #8
0
 private static void DzAPI_Map_Stat_SetStat(JassPlayer whichPlayer, JassStringArg key, JassStringArg value)
 {
 }
Exemple #9
0
 private static void DzAPI_Map_UseConsumablesItem(JassPlayer whichPlayer, JassStringArg key)
 {
 }
Exemple #10
0
 private static JassStringRet DzAPI_Map_GetPublicArchive(JassPlayer whichPlayer, JassStringArg key) => string.Empty;
Exemple #11
0
 private static JassBoolean DzAPI_Map_SavePublicArchive(JassPlayer whichPlayer, JassStringArg key, JassStringArg value) => true;
Exemple #12
0
 private static JassBoolean DzAPI_Map_HasMallItem(JassPlayer whichPlayer, JassStringArg key) => false;
Exemple #13
0
 private static void DzAPI_Map_MissionComplete(JassPlayer whichPlayer, JassStringArg key, JassStringArg value)
 {
 }
Exemple #14
0
 private static JassInteger DzAPI_Map_GetGuildRole(JassPlayer whichPlayer) => 0;
Exemple #15
0
 private static JassBoolean DzAPI_Map_SaveServerValue(JassPlayer whichPlayer, JassStringArg key, JassStringArg value) => true;
Exemple #16
0
 private static JassStringRet DzAPI_Map_GetServerValue(JassPlayer whichPlayer, JassStringArg key) => string.Empty;
Exemple #17
0
 private static void DzAPI_Map_OrpgTrigger(JassPlayer whichPlayer, JassStringArg key)
 {
 }
Exemple #18
0
 private static void DzAPI_Map_Ladder_SetPlayerStat(JassPlayer whichPlayer, JassStringArg key, JassStringArg value)
 {
 }
Exemple #19
0
 private static JassStringRet DzAPI_Map_GetServerArchiveDrop(JassPlayer whichPlayer, JassStringArg key) => string.Empty;
Exemple #20
0
 private static JassBoolean DzAPI_Map_IsBlueVIP(JassPlayer whichPlayer) => false;
Exemple #21
0
 private static JassInteger DzAPI_Map_GetServerArchiveEquip(JassPlayer whichPlayer, JassStringArg key) => 0;
Exemple #22
0
 private static JassInteger DzAPI_Map_GetMapLevelRank(JassPlayer whichPlayer) => 0;
Exemple #23
0
 private static JassInteger DzAPI_Map_GetPlatformVIP(JassPlayer whichPlayer) => 0;
Exemple #24
0
 public JassPlayerWithJassSuiteInHand(JassPlayer player, JassSuiteInHand suiteInHand)
 {
     Player      = player;
     SuiteInHand = suiteInHand;
 }
Exemple #25
0
 private static JassBoolean RequestExtraBooleanData(JassInteger dataType, JassPlayer whichPlayer, JassStringArg param1, JassStringArg param2, JassBoolean param3, JassInteger param4, JassInteger param5, JassInteger param6) => false;