A
/ \ _ Play Now Nemesis on
| | | | _______ _ _ _______ _______ _ _______
| |\ | | | ____| | \ / | | ____| / ____| | | / ____|
/-------/-------------------------------------------------------------------,
O= Home <=XX| About News Pics Adventurers Wizards Download Connect >
\-------\-------------------------------------------------------------------'
| | \ | | |____ | | | | | |____ ___ \ \ | | ___ \ \
| | \_| |_______| |_| |_| |_______| |_______/ |_| |_______/
\ /
V
Documentation Area
Document Path: /doc/object/can_put_and_get
Lfun: can_put_and_get - enable an object to have an inventory
Synopsis:
int can_put_and_get(string look_at)
Description:
Define this function if you want to make it possible for a player
to put items into it or get items from it.
If the look_at argument is given a player tries to look at the
inventory of the object.
Return value:
Return 1 if it is ok, to get or take items from the object, or
if it is ok to look at its inventory. Otherwise return 0.
This means that it is not possible to put/get something into/from
an object per default.
This is trivial for containers. If the are open, they return 1.
If the id function accepts other things, like "lock" (in a chest for
example), then "lock" will be sent to can_put_and_get, which should
return 0, because the lock has no inventory (of course).
See also:
This page was generated in LPC
Imprint / Impressum