Пример #1
0
    public void Start()
    {
        DraftController.Get().subBeginChooseForeign.Subscribe(cbStartForeignSelection);
        DraftController.Get().subBeginChooseLocally.Subscribe(cbStartLocalSelection);

        DraftController.Get().subEndChooseForeign.Subscribe(cbEndSelection);
        DraftController.Get().subEndChooseLocally.Subscribe(cbEndSelection);
    }
Пример #2
0
    public void cbStartLocalSelection(Object tar, params object[] args)
    {
        DraftController.DraftAction curDraftStep = DraftController.Get().GetNextDraftPhaseStep();

        if (curDraftStep.draftactionType == DraftController.DraftAction.DRAFTACTIONTYPE.BAN)
        {
            txtDraftPrompt.text = string.Format("Ban a character for Player {0}", curDraftStep.iPlayer);
        }
        else if (curDraftStep.draftactionType == DraftController.DraftAction.DRAFTACTIONTYPE.DRAFT)
        {
            txtDraftPrompt.text = string.Format("Draft a character for Player {0}", curDraftStep.iPlayer);
        }
    }
Пример #3
0
    public void cbStartForeignSelection(Object tar, params object[] args)
    {
        DraftController.DraftAction curDraftStep = DraftController.Get().GetNextDraftPhaseStep();

        if (curDraftStep.draftactionType == DraftController.DraftAction.DRAFTACTIONTYPE.BAN)
        {
            txtDraftPrompt.text = string.Format("Waiting for Player {0} to ban", curDraftStep.iPlayer);
        }
        else if (curDraftStep.draftactionType == DraftController.DraftAction.DRAFTACTIONTYPE.DRAFT)
        {
            txtDraftPrompt.text = string.Format("Waiting for Player {0} to draft", curDraftStep.iPlayer);
        }
    }
    public void onClick()
    {
        Debug.Log("Clicked on " + chrInSlot);

        DraftController.Get().OnDraftableChrClicked(chrInSlot);
    }