Mutton.lua 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. --[[
  2. Script Name : SpawnScripts/EnchantedLands/Mutton.lua
  3. Script Purpose : Mutton
  4. Script Author : Cynnar
  5. Script Date : 2015.02.24
  6. Script Notes : Auto-Generated Conversation from PacketParser Data
  7. --]]
  8. function spawn(NPC)
  9. SetPlayerProximityFunction(NPC, 10, "InRange", "LeaveRange")
  10. end
  11. function respawn(NPC)
  12. spawn(NPC)
  13. end
  14. function InRange(NPC, Spawn)
  15. end
  16. function LeaveRange(NPC, Spawn)
  17. end
  18. function hailed(NPC, Spawn)
  19. FaceTarget(NPC, Spawn)
  20. conversation = CreateConversation()
  21. local choice = math.random(1,3)
  22. if choice == 1 then
  23. PlayFlavor(NPC, "", "Woof?", "", 1689589577, 4560189, Spawn)
  24. elseif choice == 2 then
  25. PlayFlavor(NPC, "", "Woof! Woof!", "", 1689589577, 4560189, Spawn)
  26. elseif choice == 3 then
  27. PlayFlavor(NPC, "", "Woof! Woof! Woof!", "", 1689589577, 4560189, Spawn)
  28. else
  29. end
  30. PlayFlavor(NPC, "", "", "", 0, 0, Spawn)
  31. AddConversationOption(conversation, "Good dog. Don't bite me!", "dlg_1_1")
  32. StartConversation(conversation, NPC, Spawn, "Woof!")
  33. if convo==2 then
  34. PlayFlavor(NPC, "", "", "", 0, 0, Spawn)
  35. AddConversationOption(conversation, "Good dog. Don't bite me!", "dlg_2_1")
  36. StartConversation(conversation, NPC, Spawn, "Woof!")
  37. end
  38. if convo==4 then
  39. PlayFlavor(NPC, "", "", "", 0, 0, Spawn)
  40. AddConversationOption(conversation, "Mutton? Where've you been? Can you show me?", "dlg_4_1")
  41. AddConversationOption(conversation, "Good dog. Don't bite me!")
  42. StartConversation(conversation, NPC, Spawn, "Woof!")
  43. end
  44. if convo==7 then
  45. PlayFlavor(NPC, "", "", "", 0, 0, Spawn)
  46. AddConversationOption(conversation, "Good dog. Don't bite me!", "dlg_7_1")
  47. StartConversation(conversation, NPC, Spawn, "Woof!")
  48. end
  49. end
  50. --[[ raw_conversations
  51. PlayFlavor(NPC, "", "Woof?", "", 1689589577, 4560189, Spawn)
  52. PlayFlavor(NPC, "", "Woof! Woof!", "", 1689589577, 4560189, Spawn)
  53. PlayFlavor(NPC, "", "Woof! Woof! Woof!", "", 1689589577, 4560189, Spawn)
  54. --]]