- Joined
- Jul 25, 2007
- Messages
- 382
- Reaction score
- 38
Can someone show me a simple NPC script just respond based on what the player says. Not just one keyword like I see all the scripts or: "would you like blah" player -> "yes" , something happens. I tried doing:
Player says quest, npc responds with the proper message but also adds "Come again~" instead of waiting for a response. I can't find any resource on NPC scripting. Help is appreciated.
Lua:
if msgcontains(msg, 'quest') then
selfSay('Huh? Quest? Just a simple post office here. That all?', cid)
if msgcontains(msg, 'no') then
selfSay('Gonna have to be more specific than that lad', cid)
else
selfSay('Come again! -wisper- not that you have other options', cid)
end
end
Player says quest, npc responds with the proper message but also adds "Come again~" instead of waiting for a response. I can't find any resource on NPC scripting. Help is appreciated.