Implemented default object's at_give() hook

Calls a new hook on the default object, at_give(), which passes the giving and receiving objects as arguments.
This commit is contained in:
BattleJenkins 2017-03-22 00:22:52 -07:00 committed by Griatch
parent 4e25c93888
commit 96ba31f858

View file

@ -353,6 +353,8 @@ class CmdGive(COMMAND_DEFAULT_CLASS):
caller.msg("You give %s to %s." % (to_give.key, target.key))
to_give.move_to(target, quiet=True)
target.msg("%s gives you %s." % (caller.key, to_give.key))
# Call the object script's at_give() method.
obj.at_give(caller, target)
class CmdDesc(COMMAND_DEFAULT_CLASS):