Difference between revisions of "NpcMsgName"

From OpenKore Wiki
Jump to: navigation, search
(Add EventMacro event condition: NpcMsgName)
 
 
Line 1: Line 1:
Is checked on npc conversation messages, is true when the message matches the given regex and the name of the npc which sent it also matches it's given regex.
+
{{Template:NpcMsgName}}
  
: Syntax:
+
[[Category:EventMacro_Automacros]]
NpcMsgName <[[EventMacro#Regex|Regex]]> <[[EventMacro#Regex|Regex]]>
+
 
+
: The first regex is for the message, the second one is for the npc name
+
 
+
: Example:
+
NpcMsgName /You don't have zeny/ /kafra/
+
 
+
: Set variables:
+
$.NpcMsgNameLastName => Saves the name of the npc which message activated NpcMsgName
+
$.NpcMsgNameLastMsg => Saves the message which activated NpcMsgName
+
 
[[Category:EventMacro_Conditions_Event]]
 
[[Category:EventMacro_Conditions_Event]]

Latest revision as of 05:55, 5 July 2019

NpcMsgName
  • Description: Is checked on npc conversation messages, is true when the message matches the given regex and the name of the npc which sent it also matches it's given regex.
Syntax:
NpcMsgName <Regex> <Regex>
The first regex is for the message, the second one is for the npc name
Example:
NpcMsgName /You don't have zeny/ /kafra/
Set variables:
$.NpcMsgNameLastName => Saves the name of the npc which message activated NpcMsgName
$.NpcMsgNameLastMsg => Saves the message which activated NpcMsgName