Turn off Lerpz Jumping, and turn it back on when he picks up a specific fuel cell?

I'd like to start the player off with no jumping ability... which I know is just making canjump false at first. Additionally, when the player hits the space bar a sound plays and a short spark particle emits from the jetpack to further signify it isn't working yet. When the player picks up a specific fuel cell... I want the jetpack to work as it normally does.... so basically make canjump in the ThirdPersonController script true.

I know exactly what I want to do and how to do it in theory, but not really knowing much about the Java language is killing me.

Any ideas would be appreciated.

1 Answer

1

You'd create a fuel cell like the others, but in the pickup code, you'd also have code to tun on jump on Lerpz.

Have a look at the code for the other fuel cells and see if it makes sense.

Thanks! I know that... but what code exactly would be needed to access lerpz and turn on jumping from the pickup script?