Phantasmal MUD Lib for DGD

Phantasmal Site > Phantasmal API > API Listing > can_pass

API Function: can_pass

Summary:
query whether somebody can pass through the exit

Defined In LPC Object:
/usr/common/lib/exit.c

Prototype:
string can_pass(object user, object pass_through)

Can Be Called By:
Anybody

Description:

This function should return a string reason why the user or mobile can't pass through, if they can't. If they can pass through, it should return nil.

If a non-user mobile is passing through, 'user' will be nil. In any case, pass_through should be the body of the user or mobile attempting to pass through.

The default implementation will check is_open to see if the exit is open, but do no other checking.

This function isn't access-protected. You should access-protect your version of this and all other inherited functions, including upgraded() and destructed().

Return Value:

The reason the mobile can't pass, or nil.

Errors:
Usually none.

See Also:
is_open , pass