Advertisement
Guest User

Untitled

a guest
May 20th, 2018
133
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.73 KB | None | 0 0
  1. -- Set the name of the NPC. This will be displayed on the top of the panel.
  2. NPC.name = "Rezeption"
  3.  
  4. -- Uncomment to make the NPC sit.
  5. --NPC.sequence = "sit"
  6.  
  7. -- This is the function that gets called when the player presses <E> on the NPC.
  8. function NPC:onStart()
  9. -- self:addText(<text>) adds text that comes from the NPC.
  10. self:addText("Willkommen im 'THE TIDES'-Hotel. Wie kann ich Ihnen helfen?")
  11.  
  12. -- self:addOption(<text>, <callback>) is a button that you can pick and it will
  13. -- run the callback function.
  14. self:addOption("Ich möchte ein Apartment mieten.", function()
  15. -- This code is inside a function that gets ran after pressing the option.
  16. self:addText("Okay, was ist Ihr derzeitiges Budget, das Sie für eine 3 Tage Miete eines Apartments zahlen würden?")
  17.  
  18. self:addOption("~ 250.000", function()
  19. self:addText("Hierzu kommen folgende Apartments infrage:")
  20. self:addText("'Apartment 1' direkt links an der Ecke.")
  21. self:addText("'Apartment 2' direkt links hinten am Ende des Gangs.")
  22.  
  23. self:addOption("~ 500.000", function()
  24. self:addText("Hierzu kommen folgende Apartments infrage:")
  25. self:addText("'Premium Suite' direkt rechts hinter der Rezeption.")
  26.  
  27. -- self:addLeave(<leave text>) adds a button that closes the dialogue.
  28. self:addLeave("Ich muss gehen.")
  29. end)
  30.  
  31. self:addOption("Was macht ihr Hotel so besonders?", function()
  32. -- This code is inside a function that gets ran after pressing the option.
  33. self:addText("Wir bieten unseren Kunden vornehm eingerichtete Apartments mit einfacher Bedienung der Mitbesitzer, Türen, Props an. Außerdem verfügen Sie über eine eigene Türklingel.")
  34.  
  35. -- Add a leave.
  36. self:addLeave("Ouch!")
  37. end)
  38. self:addLeave("No thanks.")
  39. end)
  40. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement