lua/wrappers/game/lua_character.cpp
/**
	 * Attempts to pickup an item.
	 *
	 * @param am.item item The item to attempt to pickup.
	 * @returns am.code Return code for the pickup:
	 * <table class='return_codes'>
	 *  <tr><td>success</td><td>The item was picked up.</td></tr>
	 *  <tr><td>nil_parameter</td><td>The item was nil.</td></tr>
	 *  <tr><td>out_of_range</td><td>The item was out of range of this characters pickup radius.</td></tr>
	 *  <tr><td>not_enough_inventory_space</td><td>There's not enough space for the item to be picked up.</td></tr>
	 * </table>
	 */
Attempts to pickup an item.
@param am.item item The item to attempt to pickup.
@returns am.code Return code for the pickup:

successThe item was picked up.
nil_parameterThe item was nil.
out_of_rangeThe item was out of range of this characters pickup radius.
not_enough_inventory_spaceThere's not enough space for the item to be picked up.

Attempts to pickup an item . @param am . item item The item to attempt to pickup . @returns am . code Return code for the pickup : successThe item was picked up . nil_parameterThe item was nil . out_of_rangeThe item was out of range of this characters pickup radius . not_enough_inventory_spaceThere ' s not enough space for the item to be picked up .
int Character_pickup_item(lua_State *lua)
	{
		Character *obj = castUData<Character>(lua, 1);
		if (obj)
		{
			Item *item = castUData<Item>(lua, 2);
			if (item)
			{
				lua_pushinteger(lua, obj->pickupItem(item));
				return 1;
			}
			return LuaState::expectedArgs(lua, "pickup_item", "am.item item");
		}
		return LuaState::expectedContext(lua, "pickup_item", "am.character");
	}
int Character_pickup_item ( lua_State * lua ) { Character * obj = castUData < Character > ( lua , 1 ) ; if ( obj ) { Item * item = castUData < Item > ( lua , 2 ) ; if ( item ) { lua_pushinteger ( lua , obj -> pickupItem ( item ) ) ; return 1 ; } return LuaState :: expectedArgs ( lua , " " , " " ) ; } return LuaState :: expectedContext ( lua , " " , " " ) ; }
Attempts to pickup an item.
Attempts to pickup an item .