From 0ce24a1ce5fdb400debc0429345e37feff45d4d8 Mon Sep 17 00:00:00 2001 From: TurmoilToad Date: Tue, 16 Jan 2018 16:50:35 -0500 Subject: [PATCH] Updated Perl EVENT_WAYPOINT_DEPART (markdown) --- Perl-EVENT_WAYPOINT_DEPART.md | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Perl-EVENT_WAYPOINT_DEPART.md b/Perl-EVENT_WAYPOINT_DEPART.md index 5d559f6..f9a975f 100755 --- a/Perl-EVENT_WAYPOINT_DEPART.md +++ b/Perl-EVENT_WAYPOINT_DEPART.md @@ -17,12 +17,15 @@ EVENT_WAYPOINT_DEPART is triggered when an NPC leaves its current grid waypoint ### EVENT_WAYPOINT_DEPART in use ```perl +# This example would cause your NPC to speak as it departs a particular waypoint. +# Don't forget to count waypoint 0 (the spawn point) when using waypoint events. + sub EVENT_WAYPOINT_DEPART { - # Use == for numeric comparison to match grid waypoint entry "0" (the spawn point of the NPC) + # Use == for numeric comparison to match grid waypoint entry "0" if ($wp == 0) { - quest::say("And we're off!"); - } + quest::say("And we're off!"); + } } ``` Generated On 2018-01-15T22:07:30-08:00 \ No newline at end of file