lua/wrappers/game/lua_character.cpp
/**
	 * Removes a body part with the same name from the character.
	 *
	 * @param string part_name The body part to remove.
	 * @returns boolean True if the body part was removed.
	 */
Removes a body part with the same name from the character.
@param string part_name The body part to remove.
@returns boolean True if the body part was removed.
Removes a body part with the same name from the character . @param string part_name The body part to remove . @returns boolean True if the body part was removed .
int Character_remove_body_part(lua_State *lua)
	{
		Character *obj = castUData<Character>(lua, 1);
		if (obj)
		{
			if (lua_isstr(lua, 2))
			{
				lua_pushboolean(lua, obj->removeBodyPart(lua_tostring(lua, 2)));
				return 1;
			}
			else
			{
				BodyPart *part = castUData<BodyPart>(lua, 2);
				if (part)
				{
					lua_pushboolean(lua, obj->removeBodyPart(part));
					return 1;
				}
			}
			return LuaState::expectedArgs(lua, "remove_body_part", 2, "string part_name", "am.body_part part");
		}
		return LuaState::expectedContext(lua, "remove_body_part", "am.character");
	}
int Character_remove_body_part ( lua_State * lua ) { Character * obj = castUData < Character > ( lua , 1 ) ; if ( obj ) { if ( lua_isstr ( lua , 2 ) ) { lua_pushboolean ( lua , obj -> removeBodyPart ( lua_tostring ( lua , 2 ) ) ) ; return 1 ; } else { BodyPart * part = castUData < BodyPart > ( lua , 2 ) ; if ( part ) { lua_pushboolean ( lua , obj -> removeBodyPart ( part ) ) ; return 1 ; } } return LuaState :: expectedArgs ( lua , " " , 2 , " " , " " ) ; } return LuaState :: expectedContext ( lua , " " , " " ) ; }
Removes a body part with the same name from the character.
Removes a body part with the same name from the character .