9
3

SapswillVillageHappy.lua 702 B

123456789101112131415161718192021222324252627282930313233
  1. --[[
  2. Script Name : SapswillVillageHappy.lua
  3. Script Purpose : Spawn script for a happy Sapswill villager.
  4. Script Author : Scatman
  5. Script Date : 2009.01.11
  6. Script Notes :
  7. --]]
  8. local ADiplomaticMission = 166
  9. function spawn(NPC)
  10. SpawnSet(NPC, "visual_state", 11150)
  11. end
  12. function respawn(NPC)
  13. spawn(NPC)
  14. end
  15. function hailed(NPC, Spawn)
  16. if HasQuest(Spawn, ADiplomaticMission) and not QuestStepIsComplete(Spawn, ADiplomaticMission, 5) then
  17. SetStepComplete(Spawn, ADiplomaticMission, 5)
  18. end
  19. FaceTarget(NPC, Spawn)
  20. choice = math.random(1, 3)
  21. if choice == 1 then
  22. Say(NPC, "Get some swill, diplomat! Is good!")
  23. else
  24. Say(NPC, "Dishpan hands? Huh? Oh! Dip-lo-mat! Ha! Funny!")
  25. end
  26. end