private void HandleMoves(global::Event e)
            {
                Debug.Assert(e.GetType() == typeof(MoveEvent), "Non-MoveEvent in HandleMoves");

                MoveEvent moveEvent = e as MoveEvent;

                Context.ToggleMoveNotice(moveEvent.movingObj.GetComponent <DefenderSandbox>(), Indicate.Stop);

                if (ranger.ReportGridLoc().x == 0 && ranger.ReportGridLoc().z == 3)
                {
                    if (guardian.ReportGridLoc().x == 5 && guardian.ReportGridLoc().z == 3)
                    {
                        if (brawler.ReportGridLoc().x == 8 && brawler.ReportGridLoc().z == 3)
                        {
                            Context.ToggleMoveNotice(null, Indicate.Stop);                             //sanity check; make sure all notices are off
                            Services.Board.HighlightAll(BoardBehavior.OnOrOff.Off);
                            Services.UI.SetButtonText(THERE_MSG);
                            Services.UI.TogglePhaseButton(ChatUI.OnOrOff.On);
                            Services.UI.ToggleUndoButton(ChatUI.OnOrOff.Off);
                        }
                    }
                }
            }
Exemple #2
0
 protected override void Init()
 {
     Services.Board.HighlightAllAroundSpace(ranger.ReportGridLoc().x, ranger.ReportGridLoc().z, BoardBehavior.OnOrOff.On, true);
     Services.UI.OpponentStatement(ROCK_MSG);
     Services.Events.Register <InputEvent>(PutDownBlock);
 }
Exemple #3
0
    /////////////////////////////////////////////
    /// Functions
    /////////////////////////////////////////////


    //constructor
    public PutDownBlockTask(RangerBehavior ranger)
    {
        this.ranger = ranger;
        rangerX     = ranger.ReportGridLoc().x;
        rangerZ     = ranger.ReportGridLoc().z;
    }