Beispiel #1
0
    public static Runestone Factory(int cellID)
    {
        Runestone runestone = Runestone.Factory();

        runestone.Cell = Cell.FromId(cellID);
        return(runestone);
    }
Beispiel #2
0
    public static Runestone Factory()
    {
        GameObject runestoneGo = PhotonNetwork.Instantiate("Prefabs/Tokens/Runestone", Vector3.zero, Quaternion.identity, 0);
        Runestone  rs          = runestoneGo.GetComponent <Runestone>();

        rs.Cell = null;
        return(rs);
    }
Beispiel #3
0
        public void Runestone_Id_Test()
        {
            Runestone runestone = new Runestone(1);

            int test = 1;

            int actual = runestone.Id;


            Assert.AreEqual(test, actual);
        }
Beispiel #4
0
    public override void ApplyEffect()
    {
        if (PhotonNetwork.IsMasterClient)
        {
            int[] runestoneCells = GameManager.instance.narrator.runestoneCells;

            int firstRunestoneCell  = runestoneCells[0];
            int secondRunestoneCell = runestoneCells[1];
            int thirdRunestoneCell  = runestoneCells[2];
            int fourthRunestoneCell = runestoneCells[3];
            int fifthRunestoneCell  = runestoneCells[4];
            //Debug.Log(firstRunestoneCell + "  " + secondRunestoneCell + "  " + thirdRunestoneCell + "  " + fourthRunestoneCell + "  " + fifthRunestoneCell);
            Runestone runestone1 = Runestone.Factory(firstRunestoneCell);
            Runestone runestone2 = Runestone.Factory(secondRunestoneCell);
            Runestone runestone3 = Runestone.Factory(thirdRunestoneCell);
            Runestone runestone4 = Runestone.Factory(fourthRunestoneCell);
            Runestone runestone5 = Runestone.Factory(fifthRunestoneCell);
        }
    }