diff options
author | Thorbjørn Lindeijer <thorbjorn@lindeijer.nl> | 2013-04-14 15:10:06 +0200 |
---|---|---|
committer | Thorbjørn Lindeijer <thorbjorn@lindeijer.nl> | 2013-04-14 15:10:06 +0200 |
commit | 080ddbe822b03416934a875b2d949e3afc84fb96 (patch) | |
tree | 8915d1c92fdd0e609952afc492cbc3ea1152d1ae /src/scripting/script.h | |
parent | 3a132996f798dbf552ac858b06fa656b6790a501 (diff) | |
download | manaserv-080ddbe822b03416934a875b2d949e3afc84fb96.tar.gz manaserv-080ddbe822b03416934a875b2d949e3afc84fb96.tar.bz2 manaserv-080ddbe822b03416934a875b2d949e3afc84fb96.tar.xz manaserv-080ddbe822b03416934a875b2d949e3afc84fb96.zip |
Removed NPC and character parameters from NPC functions
These functions can only be used in the context of a character talking
to an NPC, so these parameters can be deduced from that context rather
than passing them explicitly all the time.
Simplifies NPC scripting.
Diffstat (limited to 'src/scripting/script.h')
-rw-r--r-- | src/scripting/script.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/scripting/script.h b/src/scripting/script.h index 694deed6..7cf457cc 100644 --- a/src/scripting/script.h +++ b/src/scripting/script.h @@ -43,9 +43,13 @@ class Script : public sigc::trackable struct Context { MapComposite *map; + Entity *npc; + Entity *character; Context() : map(0) + , npc(0) + , character(0) {} }; |