public static int StopBattle(IntPtr l)
    {
        int result;

        try
        {
            BattleTeam battleTeam = (BattleTeam)LuaObject.checkSelf(l);
            bool       win;
            LuaObject.checkType(l, 2, out win);
            battleTeam.StopBattle(win);
            LuaObject.pushValue(l, true);
            result = 1;
        }
        catch (Exception e)
        {
            result = LuaObject.error(l, e);
        }
        return(result);
    }