Adjust some function names in the script parents to be at_ instead of a_. Also re-designed the scheduling system to be a lot more pythonic and easy to use. Utilizes classes to represent events. Much easier to plug in events from within the game directory now as well.

This commit is contained in:
Greg Taylor 2009-04-06 16:19:07 +00:00
parent b3c386a2c3
commit 5a465746c5
8 changed files with 159 additions and 145 deletions

View file

@ -741,6 +741,10 @@ def cmd_destroy(command):
source_object.emit_to("That object is already destroyed.")
return
# Run any scripted things that happen before destruction.
target_obj.scriptlink.at_pre_destroy(pobject=source_object)
# Notify destroyer and do the deed.
source_object.emit_to("You destroy %s." % target_obj.get_name())
target_obj.destroy()
GLOBAL_CMD_TABLE.add_command("@destroy", cmd_destroy,