Ejemplo n.º 1
0
    //propUI发生点击后,调用该方法。会回调选中与取消选中(先调用取消选中,然后再调用选中)
    public void MouseClickProp(string propName)
    {
        if (thePropDataManager.GetIsPropChosen())
        {
            if (thePropDataManager.GetNowChosenProp() == propName)
            {
                thePropDataManager.SetNowChosenState(false, "None");

                nowProp.ObjTrigger(NormalTriggers.cancelChosen);
                nowProp = null;
            }
            else
            {
                thePropDataManager.SetNowChosenState(true, propName);

                nowProp.ObjTrigger(NormalTriggers.cancelChosen);
                nowProp = uiPropDic[propName];
                nowProp.ObjTrigger(NormalTriggers.beChosen);
            }
        }
        else
        {
            thePropDataManager.SetNowChosenState(true, propName);

            nowProp = uiPropDic[propName];

            nowProp.ObjTrigger(NormalTriggers.beChosen);
        }
    }
Ejemplo n.º 2
0
 private void OnMouseUpAsButton()
 {
     if (GameManager.gameManagerInstance.GetIsGlobalObjRespondMouse())
     {
         theListener.ObjTrigger(eventName);
     }
 }
 public void CallBack()
 {
     theCallBackObj.ObjTrigger(CallBackEventName);
 }