public MatchStateShowSkillGuide(MatchStateMachine owner)
     : base(owner)
 {
     m_eState   = MatchState.State.eShowSkillGuide;
     timer      = new GameUtils.Timer(new IM.Number(3), OnTimer);
     timer.stop = true;
 }
Пример #2
0
    static int SetState(IntPtr L)
    {
        int count = LuaDLL.lua_gettop(L);

        if (count == 2)
        {
            MatchStateMachine obj  = (MatchStateMachine)LuaScriptMgr.GetNetObjectSelf(L, 1, "MatchStateMachine");
            MatchState.State  arg0 = (MatchState.State)LuaScriptMgr.GetNetObject(L, 2, typeof(MatchState.State));
            bool o = obj.SetState(arg0);
            LuaScriptMgr.Push(L, o);
            return(1);
        }
        else if (count == 3)
        {
            MatchStateMachine obj  = (MatchStateMachine)LuaScriptMgr.GetNetObjectSelf(L, 1, "MatchStateMachine");
            MatchState.State  arg0 = (MatchState.State)LuaScriptMgr.GetNetObject(L, 2, typeof(MatchState.State));
            bool arg1 = LuaScriptMgr.GetBoolean(L, 3);
            bool o    = obj.SetState(arg0, arg1);
            LuaScriptMgr.Push(L, o);
            return(1);
        }
        else
        {
            LuaDLL.luaL_error(L, "invalid arguments to method: MatchStateMachine.SetState");
        }

        return(0);
    }
Пример #3
0
    static int GameUpdate(IntPtr L)
    {
        LuaScriptMgr.CheckArgsCount(L, 2);
        MatchStateMachine obj = (MatchStateMachine)LuaScriptMgr.GetNetObjectSelf(L, 1, "MatchStateMachine");

        IM.Number arg0 = (IM.Number)LuaScriptMgr.GetNetObject(L, 2, typeof(IM.Number));
        obj.GameUpdate(arg0);
        return(0);
    }
Пример #4
0
    static int GetEnumerator(IntPtr L)
    {
        LuaScriptMgr.CheckArgsCount(L, 1);
        MatchStateMachine obj = (MatchStateMachine)LuaScriptMgr.GetNetObjectSelf(L, 1, "MatchStateMachine");
        IEnumerator       o   = obj.GetEnumerator();

        LuaScriptMgr.Push(L, o);
        return(1);
    }
Пример #5
0
    static int ViewUpdate(IntPtr L)
    {
        LuaScriptMgr.CheckArgsCount(L, 2);
        MatchStateMachine obj  = (MatchStateMachine)LuaScriptMgr.GetNetObjectSelf(L, 1, "MatchStateMachine");
        float             arg0 = (float)LuaScriptMgr.GetNumber(L, 2);

        obj.ViewUpdate(arg0);
        return(0);
    }
Пример #6
0
    static int GetState(IntPtr L)
    {
        LuaScriptMgr.CheckArgsCount(L, 2);
        MatchStateMachine obj = (MatchStateMachine)LuaScriptMgr.GetNetObjectSelf(L, 1, "MatchStateMachine");

        MatchState.State arg0 = (MatchState.State)LuaScriptMgr.GetNetObject(L, 2, typeof(MatchState.State));
        MatchState       o    = obj.GetState(arg0);

        LuaScriptMgr.PushObject(L, o);
        return(1);
    }
Пример #7
0
    public void OnActivate(MatchStateMachine matchStateMachine)
    {
        if (EnvironmentHelper.StaticEnvironment == EnvironmentHelper.Environment.LOCAL)
        {
            //matchStateMachine.InitializeUdpClient("34.242.151.135", 2448);
            matchStateMachine.InitializeUdpClient("127.0.0.1", 2448);
            matchStateMachine.ChangeMatchState(new TimeSyncMatchState());
            return;
        }

        this.matchStateMachine = matchStateMachine;
        string joinMatchPath = EnvironmentHelper.HTTPServerUrl + "/joinmatch/" + playerCount;

        findMatchRequest = UnityWebRequest.Get(joinMatchPath);
        findMatchRequest.SendWebRequest();
        DIContainer.Logger.Debug("Started to join match with url: " + joinMatchPath);
    }
    static int _CreateMatchStatePlayerCloseUp(IntPtr L)
    {
        int count = LuaDLL.lua_gettop(L);

        if (count == 1)
        {
            MatchStateMachine       arg0 = (MatchStateMachine)LuaScriptMgr.GetNetObject(L, 1, typeof(MatchStateMachine));
            MatchStatePlayerCloseUp obj  = new MatchStatePlayerCloseUp(arg0);
            LuaScriptMgr.PushObject(L, obj);
            return(1);
        }
        else
        {
            LuaDLL.luaL_error(L, "invalid arguments to method: MatchStatePlayerCloseUp.New");
        }

        return(0);
    }
Пример #9
0
    static int get_m_owner(IntPtr L)
    {
        object            o   = LuaScriptMgr.GetLuaObject(L, 1);
        MatchStateMachine obj = (MatchStateMachine)o;

        if (obj == null)
        {
            LuaTypes types = LuaDLL.lua_type(L, 1);

            if (types == LuaTypes.LUA_TTABLE)
            {
                LuaDLL.luaL_error(L, "unknown member name m_owner");
            }
            else
            {
                LuaDLL.luaL_error(L, "attempt to index m_owner on a nil value");
            }
        }

        LuaScriptMgr.PushObject(L, obj.m_owner);
        return(1);
    }
Пример #10
0
 public MatchStateSlotMachineUltimate21(MatchStateMachine owner)
     : base(owner)
 {
     m_eState = MatchState.State.eSlotMachineUltimate21;
     match    = m_match as GameMatch_Ultimate21;
 }
Пример #11
0
 public MatchStateBegin_PVP(MatchStateMachine owner)
     : base(owner)
 {
     m_eState = MatchState.State.eBegin;
 }
Пример #12
0
 public MatchStateTipOff(MatchStateMachine owner)
     : base(owner)
 {
     m_eState = MatchState.State.eTipOff;
 }
 public MatchStatePlaying_PVP(MatchStateMachine owner)
     : base(owner)
 {
     m_eState = MatchState.State.ePlaying;
 }
Пример #14
0
 public MatchStateOverTime(MatchStateMachine owner)
     : base(owner)
 {
     m_eState = MatchState.State.eOverTime;
 }
Пример #15
0
 public MatchStateGoal(MatchStateMachine owner)
     : base(owner)
 {
     m_eState = MatchState.State.eGoal;
 }
Пример #16
0
 public MatchStateOpening(MatchStateMachine owner)
     : base(owner)
 {
     m_eState = MatchState.State.eOpening;
 }
 public MatchStateSlotMachineBullFight(MatchStateMachine owner)
     : base(owner)
 {
     m_eState = MatchState.State.eSlotMachineBullFight;
     match    = m_match as GameMatch_BullFight;
 }
Пример #18
0
 public MatchState(MatchStateMachine owner)
 {
     m_stateMachine = owner;
     m_eState       = State.eNone;
     m_match        = m_stateMachine.m_owner;
 }
Пример #19
0
 public MatchStateShowRule(MatchStateMachine owner)
     : base(owner)
 {
     m_eState = MatchState.State.eShowRule;
 }
Пример #20
0
 public void OnActivate(MatchStateMachine matchStateMachine)
 {
 }
Пример #21
0
 public MatchStateOver_PVP(MatchStateMachine owner)
     : base(owner)
 {
     m_eState = State.eOver;
 }
 public MatchStateFreeThrowStart(MatchStateMachine owner)
     : base(owner)
 {
     m_eState = MatchState.State.eFreeThrowStart;
 }
Пример #23
0
 public MatchStatePlot(MatchStateMachine owner, State state)
     : base(owner)
 {
     m_eState = state;
 }
Пример #24
0
 public MatchStateFoul(MatchStateMachine owner)
     : base(owner)
 {
     m_eState = MatchState.State.eFoul;
 }
 public MatchStatePlayerCloseUp(MatchStateMachine owner)
     : base(owner)
 {
     m_eState = MatchState.State.ePlayerCloseUp;
 }