Mountable Wolf (with jump mount and dismount)

Creator: Unknown
Level: Advanced
As saved by Goblin360 and posted to Project Spark Team club Jan 2018

This kode allows you to jump onto a wolf’s back and ride him. It also allows you to jump with the wolf without being misplaced. You also dismount with a backward somersault. The player rides with their head down and looks better if the wolf is scaled up to 150%.

Place a wolf and delete its brain. Replace with the following:

Kode

Interacting with the wolf

  1. WHEN [interacted]
  2. …WHEN [started to]
  3. …/…WHEN DO [objvar:Rider][equals][it] // sets the player as the rider
  4. …/…WHEN DO [objvar:Rider][deactivate brain] // turns the player brain off
  5. …/…WHEN DO [power on] // acts like a boolean to indicate the wolf is being ridden
    Mounting the wolf
  6. WHEN [has power]
  7. …WHEN [started to] DO [objvar:Rider][jump][2] // if you do not want the character to have their head down remove this line. He will now pop onto the backrather than jump, but his head will be up.
  8. …WHEN DO [objvar:rider][move][toward][center][min distance][0][without deceleration]
  9. …WHEN DO [follow camera][transition easing][flat easing]
    Wolf controls
  10. …WHEN [countdown timer][0.7]
  11. …/…WHEN [left stick] DO [move][at speed][1.5]
  12. …/…WHEN [not][in air]
  13. …/…/…WHEN [button:A][pressed]
  14. …/…/…/…WHEN DO [jump]
  15. …/…/…WHEN [button X][pressed] DO [attack][light]
  16. …/…/…WHEN [button Y][pressed] DO [attack][heavy]
    Dismounting
  17. …/…/…WHEN [button B][pressed]
  18. …/…/…/…WHEN DO [objvar:Rider][pace][equals][1]
  19. …/…/…/…WHEN DO [me][detach][objvar:Rider]
  20. …/…/…/…WHEN DO [objvar:Rider][dodge][in direction][objvar:Rider][backward][with strafing][distance][4] // dismounts the player with a backward somersault
  21. …/…/…/…WHEN [started to] DO [power off]
  22. …/…/…/…/…WHEN DO [objvar:Rider][up][equals][world up]
  23. …/…/…/…/…WHEN DO [objvar:Rider][activate brain]
  24. …/…/…/…/…WHEN DO [objvar:Rider][equals][nothing]
    Rider positioning
  25. …WHEN DO [objvar:Rider][vectorvar:position][equals][me][head][position][plus][me][forward][multiplied by][2]
  26. …WHEN DO pbjvar:Rider][vectorvar:zAxis][equals][(][objvar:Rider][vectorvar:position][minus][objvar:Rider][center][)][normal]
  27. …WHEN DO [objvar:Rider][vectorvar:xaxis][equals][(][world up][cross][objvar:Rider][vectorvar:zAxis][)][normal]
  28. …WHEN DO [objvar:Rider][vectorvar:yaxis][equals][(][objvar:Rider][zAxis][cross][objvar:Rider][vectorvar:xAxis][)]normal]
  29. …WHEN DO [objvar:Rider][forward][equals][objvar:Rider][vectorvar:zAxis]
  30. …WHEN DO [objvar:Rider][right][equals][objvar:Rider][vectorvar:xAxis]
  31. …WHEN DO [objvar:Rider][up][equals][objvar:Rider][vectorvar:yAxis]
  32. …WHEN DO [objvar:Rider][emote][Cower] // or you could use your own sit emote
  33. …WHEN [countdown timer][(][3][divided by][10][)]
  34. …/…WHEN [started to] DO [objvar:Rider][pace][equals][0]
  35. …WHEN DO [objvar:Rider][position][equals][root][position][plus][world down][multiplied by][0.5]
  36. …WHEN [started to][DO][me][attach][objvar:Rider][to socket][root]

Comments are closed.

Website Powered by WordPress.com.

Up ↑

%d bloggers like this: