trigger with an unknown

mattness
Posts: 17
Joined: Sat May 19, 2012 8:34 pm

Re: trigger with an unknown

Post by mattness »

Ok, so between here and the manual this is what I came up with:

Pattern: ^(\w+) (\w+) (is|are) here\.$
Code: [show] | [select all] lua
Targets = {
 ["bears"] = "bear",
 }
 
for k, v in pairs (Targets) do
   if k == matches[3] then
     target = v
     send("kill " .. target)
   end
 end
 

Post Reply