static int OnClickItem(IntPtr L)
    {
        LuaScriptMgr.CheckArgsCount(L, 2);
        UIStoreFashion obj  = (UIStoreFashion)LuaScriptMgr.GetNetObjectSelf(L, 1, "UIStoreFashion");
        uint           arg0 = (uint)LuaScriptMgr.GetNumber(L, 2);

        obj.OnClickItem(arg0);
        return(0);
    }
Esempio n. 2
0
    private void Click(GameObject go)
    {
        _uiStoreFashion.OnClickItem(_fdItem._fashionID);

        int captainGender = GameSystem.Instance.RoleBaseConfigData2.GetConfigData(MainPlayer.Instance.CaptainID).gender;

        if (_fdItem._gender != 0)
        {
            if (captainGender != _fdItem._gender)
            {
                CommonFunction.ShowTip(CommonFunction.GetConstString("UI_FASHION_DRY_DRESSON_FAILED_FOR_GENDER"));
                // _toggle.value = false;
                return;
            }
        }

        //if (0 == _state && a_isTry )
        //{
        //    dressUpdate(false);
        //    return;
        //}

        if (!_clientDressedOn && 1 == _state && !_configItem.isUsed() && !_fdItem._isDressOn && !_configItem.isForver())
        {
            CommonFunction.ShowPopupMsg(CommonFunction.GetConstString("UI_FASHON_START_TO_DRESS"), null, _voidStartDress
                                        , _voidStartDressCancle);

            return;
        }


        // dressUpdate(!_fdItem._isTry);
        if (_configItem.isMine() || _clickCounter != 0)
        {
            dressUpdate(!a_isTry);
        }
    }