lua/wrappers/game/lua_character.cpp
/**
	 * Sets the characters max level. If the max level is set to 0, then their
	 * effective max level will be 2^15 (32768).
	 * @param integer max_level The characters max level.
	 * @returns am.character This
	 */
Sets the characters max level. If the max level is set to 0, then their
effective max level will be 2^15 (32768).
@param integer max_level The characters max level.
Sets the characters max level . If the max level is set to 0 then their effective max level will be 2^15 ( 32768 ) . @param integer max_level The characters max level .
int Character_max_level(lua_State *lua)
	{
		Character *obj = castUData<Character>(lua, 1);
		if (obj)
		{
			if (lua_gettop(lua) == 1)
			{
				lua_pushinteger(lua, static_cast<lua_Integer>(obj->getMaxLevel()));
				return 1;
			}
			else if (lua_isnum(lua, 2))
			{
				obj->setMaxLevel(static_cast<short>(lua_tointeger(lua, 2)));
				lua_first(lua);
			}
			return LuaState::expectedArgs(lua, "max_level", "integer max_level");
		}
		return LuaState::expectedContext(lua, "max_level", "am.character");
	}
int Character_max_level ( lua_State * lua ) { Character * obj = castUData < Character > ( lua , 1 ) ; if ( obj ) { if ( lua_gettop ( lua ) == 1 ) { lua_pushinteger ( lua , static_cast < lua_Integer > ( obj -> getMaxLevel ( ) ) ) ; return 1 ; } else if ( lua_isnum ( lua , 2 ) ) { obj -> setMaxLevel ( static_cast < short > ( lua_tointeger ( lua , 2 ) ) ) ; lua_first ( lua ) ; } return LuaState :: expectedArgs ( lua , " " , " " ) ; } return LuaState :: expectedContext ( lua , " " , " " ) ; }
Sets the characters max level.
Sets the characters max level .