コード例 #1
0
    static public void RemoveTrap(Trap trap)
    {
        // Ejection traps
        int trapID = s_singleton.m_ejectionTraps.IndexOf(trap as EjectionTrap);

        if (trapID >= 0)
        {
            s_singleton.RpcRemoveEjectionTrap(trapID);
            s_singleton._RemoveEjectionTrap(trapID);
        }

        // Inversion traps
        trapID = s_singleton.m_inversionTraps.IndexOf(trap as InversionTrap);
        if (trapID >= 0)
        {
            s_singleton.RpcRemoveInversionTrap(trapID);
            s_singleton._RemoveInversionTrap(trapID);
        }
    }