Advertisement
Guest User

Monster script

a guest
Oct 26th, 2021
383
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.36 KB | None | 0 0
  1. return function(newENV)
  2. _ENV = newENV
  3. ----- DO NOT MODIFY ABOVE -----
  4.  
  5. -- A basic Enemy Entity script skeleton you can copy and modify for your own creations.
  6. comments = { "Proceed..." }
  7. commands = { "Check", "Taunt", "Console" }
  8. randomdialogue = { ". . ." }
  9.  
  10. AddAct("Check", "", 0)
  11. AddAct("Taunt", "", 0)
  12. AddAct("Console", "", 0)
  13.  
  14. Tauntcount = 0
  15. Consolecount = 0
  16.  
  17. name = "Noelle"
  18. hp = 500
  19. atk = 10
  20. def = 50000
  21. dialogbubble = "DRBubble" -- See documentation for what bubbles you have available.
  22. canspare = false
  23. check = "Check message goes here."
  24.  
  25. -- CYK variables
  26. mag = 9001 -- MAGIC stat of the enemy
  27. targetType = "single" -- Specifies how many (or which) target(s) this enemy's bullets will target
  28.  
  29. -- Check the "Special Variables" page of the documentation to learn how to modify this mess
  30. animations = {
  31. Hurt = { { 0 }, 1 , { next = "Idle" } },
  32. Idle = { { 0, 1, 2, 3, 4 }, 1 / 5, { } },
  33. Sad = { { 0, 1, 2, 3, 4 }, 1 / 5, { } },
  34. Angry = { { 0, 1, 2, 3, 4 }, 3, { } },
  35. }
  36.  
  37. -- Triggered when a Player attacks (or misses) this enemy in the ATTACKING state
  38. function HandleAttack(attacker, attackstatus)
  39. if attackstatus == -1 then
  40. -- Player pressed fight but didn't press Z afterwards
  41. else
  42. -- Player did actually attack
  43. canspare = false
  44. end
  45. end
  46.  
  47. -- Triggered when a Player uses an Act on this enemy.
  48. -- You don't need an all-caps version of the act commands here.
  49. function HandleCustomCommand(user, command)
  50. local text = { "help" }
  51. if command == "Check" then
  52. BattleDialog({"Noelle\nAttack: 100\nDefence: ?", "A monster you created..."})
  53. elseif command == "Taunt" then
  54. Tauntcount = Tauntcount + 1
  55. if Tauntcount == 1 then
  56. BattleDialog({"You remind Noelle of Birldy's frozen corpse." })
  57. elseif Tauntcount == 2 then
  58. BattleDialog({"You remind Noelle that SHE, killed Catty." })
  59. currentdialogue = {"[voice:v_noelle]I-I, No!"}
  60. elseif Tauntcount == 3 then
  61. BattleDialog({"You remind Noelle about Snowgrave, and the death of Ralsei." })
  62. currentdialogue = {"[voice:v_noelle]Stop it Kris!"}
  63. elseif Tauntcount == 4 then
  64. BattleDialog({"You remind Noelle about Susie's murder by her hands..." })
  65. Audio.stop()
  66. currentdialogue = {"[voice:v_noelle]...Susie...", "[voice:v_noelle]Kris, [w:10]what did you make me do!?"}
  67. elseif Tauntcount == 5 then
  68. BattleDialog({"You tell Noelle you enjoyed watching the life drain from Susies eyes as Noelle froze her." })
  69. currentdialogue = {"[voice:v_noelle]I... no! I-I Wouldn't do that!"}
  70. elseif Tauntcount == 6 then
  71. SetCYKAnimation("Angry")
  72. BattleDialog({"You tell Noelle Susie was fun to slaughter.", "She seems unphazed." })
  73. currentdialogue = {"[voice:v_noelle]I'm... I'm going to Proceed Kris.", "[voice:v_noelle]I'll make your death quick!"}
  74. Audio.LoadFile("Proceeding")
  75. nextwaves = {"SnowTarget"}
  76. Proceeding.SetVar("Pissedoff", true)
  77. elseif Tauntcount == 7 then
  78. BattleDialog({"She isn't listening..." })
  79. currentdialogue = {"[voice:v_noelle]I'm... so sorry...!"}
  80. end
  81.  
  82. elseif command == "Console" then
  83. Consolecount = Consolecount + 1
  84. if Consolecount == 1 then
  85. BattleDialog({"You apologize to Noelle for making her comit multiple murders." })
  86. elseif Consolecount == 2 then
  87. BattleDialog({"You say that your going to set things right." })
  88. currentdialogue = {"[voice:v_noelle]. . ."}
  89. elseif Consolecount == 3 then
  90. BattleDialog({"You tell Noelle that your going to bring everyone back." })
  91. currentdialogue = {"[voice:v_noelle]. . ."}
  92. elseif Consolecount == 4 then
  93. BattleDialog({"You tell Noelle that your going to fix your mistake" })
  94. currentdialogue = {"[voice:v_noelle]. . ."}
  95. elseif Consolecount == 5 then
  96. BattleDialog({"You tell Noelle that she's going to see susie again." })
  97. currentdialogue = {"[voice:v_noelle]. . ."}
  98. Audio.stop()
  99. SetCYKAnimation("Sad")
  100. elseif Consolecount == 6 then
  101. BattleDialog({"You tell Noelle that your [w:10]S[w:10]O[w:10]R[w:10]R[w:10]Y" })
  102. currentdialogue = {"[voice:v_noelle]Kris...", "[voice:v_noelle]If...[w:15]\nYour telling the truth...", "[voice:v_noelle]Then please...", "[voice:v_noelle]I just wan't to see her again..."}
  103. canspare = true
  104. end
  105. end
  106. end
  107.  
  108. ----- DO NOT MODIFY BELOW -----
  109. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement