Exemplo n.º 1
0
    public EnemyField(Gameplay _Game)
    {
        CriticalLeft = GameObject.FindGameObjectWithTag("EnemyCriticalFrontLeft");
        CriticalVanguard = GameObject.FindGameObjectWithTag("EnemyCriticalVanguard");
        CriticalRight = GameObject.FindGameObjectWithTag("EnemyCriticalFrontRight");

        CallEffect = GameObject.FindGameObjectWithTag("CallEffect");

        fieldInfo = new EnemyFieldInformation();
        Soul      = new List<Card>();
        Vanguard  = null;
        Left_Rear = null;
        Left_Front = null;
        Center_Rear = null;
        Right_Rear = null;
        Left_Rear = null;
        delta     = new Vector3(0.0f, 0.01f, 0.0f);

        VanguardPower   = (TextMesh)GameObject.FindGameObjectWithTag("VPEnemy").GetComponent("TextMesh");
        FrontRightPower = (TextMesh)GameObject.FindGameObjectWithTag("FRPEnemy").GetComponent("TextMesh");
        FrontLeftPower  = (TextMesh)GameObject.FindGameObjectWithTag("FLPEnemy").GetComponent("TextMesh");
        RearRightPower  = (TextMesh)GameObject.FindGameObjectWithTag("RRPEnemy").GetComponent("TextMesh");
        RearLeftPower   = (TextMesh)GameObject.FindGameObjectWithTag("RLPEnemy").GetComponent("TextMesh");
        RearCenterPower = (TextMesh)GameObject.FindGameObjectWithTag("RCPEnemy").GetComponent("TextMesh");

        VC  = (TextMesh)GameObject.FindGameObjectWithTag("VCE").GetComponent("TextMesh");
        FRC = (TextMesh)GameObject.FindGameObjectWithTag("FRCE").GetComponent("TextMesh");
        FLC = (TextMesh)GameObject.FindGameObjectWithTag("FLCE").GetComponent("TextMesh");
        RRC = (TextMesh)GameObject.FindGameObjectWithTag("RRCE").GetComponent("TextMesh");
        RLC = (TextMesh)GameObject.FindGameObjectWithTag("RLCE").GetComponent("TextMesh");
        RCC = (TextMesh)GameObject.FindGameObjectWithTag("RCCE").GetComponent("TextMesh");

        VanguardPower.text    = "";
        FrontRightPower.text  = "";
        FrontLeftPower.text   = "";
        RearRightPower.text   = "";
        RearLeftPower.text    = "";
        RearCenterPower.text  = "";

        DamageZone = new List<Card>();
        DropZone   = new List<Card>();
        BindZone   = new List<Card>();

        VanguardPower.renderer.material.color   = Color.yellow;
        FrontRightPower.renderer.material.color = Color.yellow;
        FrontLeftPower.renderer.material.color  = Color.yellow;
        RearRightPower.renderer.material.color  = Color.yellow;
        RearLeftPower.renderer.material.color   = Color.yellow;
        RearCenterPower.renderer.material.color = Color.yellow;

        VC.text = "";
        FRC.text = "";
        FLC.text = "";
        RRC.text = "";
        RLC.text = "";
        RCC.text = "";

        Game = _Game;
    }
Exemplo n.º 2
0
 public EnemyDeck()
 {
     fieldInfo = new EnemyFieldInformation();
     cards     = new List<Card>();
 }
Exemplo n.º 3
0
    // Use this for initialization
    void Start()
    {
        gameplay = this;

        _MainCamera = (Camera)gameObject.GetComponent("Camera");

        _SelectionListWindow = new SelectionListWindow(Screen.width / 2, Screen.height / 2 + 100);

        _AbilityManagerList = new SelectionListGenericWindow(Screen.width / 2, Screen.height / 2 + 100);

        _SelectionCardNameWindow = new SelectionCardNameWindow(Screen.width / 2 - 50, Screen.height / 2);
        _SelectionCardNameWindow.CreateCardList();
        _SelectionCardNameWindow.SetGame(this);

        _DecisionWindow = new DecisionWindow(Screen.width / 2, Screen.height / 2 + 100);
        _DecisionWindow.SetGame(this);

        _NotificationWindow = new NotificacionWindow(Screen.width / 2, Screen.height / 2 + 100);
        _NotificationWindow.SetGame(this);

        FromHandToBindList = new List<Card>();

        AttackedList = new List<Card>();

        UnitsCalled = new List<Card>();

        EnemySoulBlastQueue = new List<Card>();

        _PopupNumber = new PopupNumber();

        _MouseHelper = new MouseHelper(this);
        GameChat = new Chat();

        opponent = PlayerVariables.opponent;

        playerHand = new PlayerHand();
        enemyHand = new EnemyHand();

        field = new Field(this);
        enemyField = new EnemyField(this);
        guardZone = new GuardZone();
        guardZone.SetField(field);
        guardZone.SetEnemyField(enemyField);
        guardZone.SetGame(this);

        fieldInfo = new FieldInformation();
        EnemyFieldInfo = new EnemyFieldInformation();

        Data = new CardDataBase();
        List<CardInformation> tmpList = Data.GetAllCards();
        for(int i = 0; i < tmpList.Count; i++)
        {
            _SelectionCardNameWindow.AddNewNameToTheList(tmpList[i]);
        }

        //camera = (CameraPosition)GameObject.FindGameObjectWithTag("MainCamera").GetComponent("CameraPosition");
        //camera.SetLocation(CameraLocation.Hand);

        LoadPlayerDeck();
        LoadEnemyDeck();

        gamePhase = GamePhase.CHOOSE_VANGUARD;

        bDrawing = true;
        bIsCardSelectedFromHand = false;
        bPlayerTurn = false;

        bDriveAnimation = false;
        bChooseTriggerEffects = false;
        DriveCard = null;

        //Texture showed above a card when this is selected for an action (An attack, for instance)
        CardSelector = GameObject.FindGameObjectWithTag("CardSelector");
        _CardMenuHelper = (CardHelpMenu)GameObject.FindGameObjectWithTag("CardMenuHelper").GetComponent("CardHelpMenu");
        _GameHelper = (GameHelper)GameObject.FindGameObjectWithTag("GameHelper").GetComponent("GameHelper");

        bPlayerTurn = PlayerVariables.bFirstTurn;

        //ActivePopUpQuestion(playerDeck.DrawCard());
        _CardMenu = new CardMenu(this);

        _AbilityManager = new AbilityManager(this);
        _AbilityManagerExt = new AbilityManagerExt();

        _GameHelper.SetChat(GameChat);
        _GameHelper.SetGame(this);

        EnemyTurnStackedCards = new List<Card>();

        dummyUnitObject = new UnitObject();
        dummyUnitObject.SetGame(this);

        stateDynamicText = new DynamicText();
    }