Quest – Defeat Enemies

Type: Assembly Brain
Level: not in gallery
Pages: 4
Description: Found in the Assemblies gallery. Assembly contains a female villager who asks you to kill 3 goblins which are spawned when you accept the quest. Kill the goblins, return to villager and receive a coin.

Kode

Create Goblin Point (logic cube)

  1. WHEN [started to][has power]
  2. …WHEN DO [play fx][fx:Poof][at position][position]
  3. …WHEN DO [objvar:Created Goblin][equals][Goblin Bruiser][at position][position]
  4. …WHEN DO [iwp:Quest Giver][#Goblins alive][increment by][1]
  5. WHEN [started to][objvar:Created Goblin][is dead] DO [iwp:Quest Giver][#Goblins Alive][decfrement by][1]

Quest Giver

page 1 @Interacted – Give Quest

  1. WHEN [not detect][player]
  2. …WHEN DO [emote][Greet]
  3. …WHEN DO [iwp:Exclamation Point A][visible][equals][true]
  4. WHEN [detect][player]
  5. …WHEN DO [turn][toward][it]
  6. …WHEN DO [iwp:Exclamation Point A][visible][equals][false]
  7. …WHEN DO [emote][Talk]
  8. …WHEN DO [say][Goblins are coming…]
  9. …WHEN [interacted] DO [switch page][page: @Accepting Quest]
  10. WHEN [#Goblins Alive][decreased]
  11. …WHEN DO [iwp:Exclamation Point A][visible][equals][false]
  12. …WHEN DO [switch page][page:@Quest Active]

page 2 @Quest Active

  1. WHEN [detect][player] DO [turn][toward][it]
  2. …WHEN [#Goblins Alive][greater then][0]
  3. …/…WHEN DO [say][text:There are still some…]
  4. …/…WHEN DO [emote][Disagree]
  5. …WHEN [#Goblins Alive][equal to][0]
  6. …/…WHEN DO [say][text: Did you kill all of them?]
  7. …/…WHEN DO [emote][Agree]
  8. …/…WHEN [interacted] DO [switch page][page:@Quest Complete]
  9. WHEN [#Goblins Alive][greater than][0]
  10. …WHEN DO [display][screen top right][text:Goblins remaining]
  11. …WHEN DO [display][screen top right][#Goblins Alive]
  12. WHEN [#Goblins Aluve][equal to][0]
  13. …WHEN DO [Question Mark A][visible][equals][true]
  14. …WHEN DO [display][screen top right][text:Return for a reward]

page 3 @Quest Complete

  1. WHEN [page entered] DO [Question Mark A][visible][equals][false]
  2. …WHEN DO [emote][Agree]
  3. WHEN [detect][player] DO [turn][toward][it]
  4. WHEN [countdown timer][0.5][hold time][4]
  5. …WHEN DO [say][text:Thank you so much…]
  6. …WHEN DO [emote][Talk]
  7. WHEN [started to][countdown timer][2] DO [throw][Coin][at][player]

page 4 @Accepting Quest

  1. WHEN [duration timer][2] DO [emote][cheer]
  2. WHEN DO [say][text:Good luck]
  3. WHEN [countdown timer][1] DO [power on]
  4. WHEN [countdown timer][2] DO [switch page][@Quest Active]

Alterations

Give the option to not take quest.

Although she asks you if you would defeat the goblins there isnt an option to say no. Change it like this for that option.

page 1 @Interacted Give Quest

  1. WHEN [not detect][player]
  2. …WHEN DO [emote][Greet]
  3. …WHEN DO [iwp:Exclamation Point A][visible][equals][true]
  4. WHEN [detect][player] DO [objvar:player][equals][it]
  5. …WHEN DO [turn][toward][it]
  6. …WHEN DO [objvar:player][brain is active][equals][false]
  7. …WHEN DO [iwp:Exclamation Point A][visible][equals][false]
  8. …WHEN DO [emote][Talk]
  9. …WHEN DO [say][Goblins are coming…]
  10. …WHEN DO [display][icon:A][text:No thanks][screen bottom center][HUD stack right]
  11. …WHEN DO [display][icon:B][text:Yes, okay][screen bottom center][HUD stack right]
  12. …WHEN [button:A]pressed] DO [switch page][page: @Refuse Quest]
  13. …WHEN [button:B]pressed] DO [switch page][page: @Accepting Quest]
  14. WHEN [#Goblins Alive][decreased]
  15. …WHEN DO [iwp:Exclamation Point A][visible][equals][false]
  16. …WHEN DO [switch page][page:@Quest Active]

page 4 @Accepting Quest

Add as childline to line 3

WHEN DO [objvar:player][brain is active][equals][true]

page 5  (New Page) @Refuse Quest

  1. WHEN [duration timer][4] DO [say][text: Oh well, if you change your mind talk to me again]
  2. …WHEN DO [emote][sad]
  3. …WHEN DO [objvar:player][brain is active][equals][true]
  4. WHEN [countdown timer][4]
  5. …WHEN DO [switch page][1]

 

Comments are closed.

Website Powered by WordPress.com.

Up ↑

%d bloggers like this: