I need help with a Angled jump!

The player has a spring jump so the spring will come out of the bottem of the robot and launch it but I want it to be so when you jump you launch that way. you lean right and left when you go right and left also you can not move in the air so I want to be able to angle the jump. Right now you can press the right and left keys to lean those directions when you press A and D you move but when I jump I just go up. How do I make it so I jump the way I am leaning? Please help it is a big mechanic of my game but i dont know how to do it! Game link Flowlab Game Creator - Untitled battery game

1 Like

add a x velocity

1 Like


When I do this it does not apply ANY X force for some reason Btws I tried it with the thing going into X but this screen shot was taken when I set forward direction to right and tried do the forward input

How do I add that? I tried it but failed can you help me??

Hey @Draco_the_Dragon, here is the code you need for the spring bundle:

{"data":{"behavior":{"v":"2","nodes":[{"inputCount":0,"outputCount":0,"name":"Spring jump","behaviorType":"logic.NodeGroup","x":-540,"y":-288,"group":"1dbbf59144ac104c","id":"3e01c1d58cea3340","isMenuItem":false},{"inputCount":0,"outputCount":2,"name":"Keyboard","behaviorType":"logic.triggers.Keyboard","x":-540,"y":32,"group":"3e01c1d58cea3340","id":"3e8bf5d3d0157949","keyCode":87,"repeats":false,"delay":0},{"inputCount":3,"outputCount":3,"name":"Impulse","behaviorType":"logic.components.Impulse","x":900,"y":0,"group":"3e01c1d58cea3340","id":"3e8c071523106349"},{"inputCount":3,"outputCount":1,"name":"Number","behaviorType":"logic.logic.Value","x":720,"y":-64,"group":"3e01c1d58cea3340","id":"3e8c274fcdc73146","startVal":23,"tag":"Jump force","roundMode":1},{"inputCount":1,"outputCount":0,"name":"Message","behaviorType":"logic.components.Message","x":-180,"y":128,"group":"3e01c1d58cea3340","id":"3eb8a293123d1947","msg":"walkOff","route":"SendToSelf"},{"inputCount":3,"outputCount":1,"name":"Switch","behaviorType":"logic.logic.Switch","x":-360,"y":32,"group":"3e01c1d58cea3340","id":"3eb8c344c70ebf40","_startVal":1,"dataType":2},{"inputCount":3,"outputCount":1,"name":"Number","behaviorType":"logic.logic.Value","x":720,"y":32,"group":"3e01c1d58cea3340","id":"3eb9ed2cfea13e41","startVal":-5,"tag":"","roundMode":1},{"inputCount":2,"outputCount":3,"name":"Router","behaviorType":"logic.logic.Router","x":540,"y":32,"group":"3e01c1d58cea3340","id":"3eba01d878675146","notes":"1=straight, 2=left, 3=right","n_o":1,"loop":true,"routes":3,"mode":0},{"inputCount":3,"outputCount":1,"name":"Number","behaviorType":"logic.logic.Value","x":720,"y":128,"group":"3e01c1d58cea3340","id":"3ebb1f748bec0140","startVal":5,"tag":"","roundMode":1},{"inputCount":0,"outputCount":1,"name":"Collision","behaviorType":"logic.triggers.Collision","x":-540,"y":-96,"group":"3e01c1d58cea3340","id":"3ebc14c33f4e6048","targetClassId":0,"targetEntityId":0,"collisionFilter":2,"collideWithEntity":false,"delay":0},{"inputCount":1,"outputCount":1,"name":"Extractor","behaviorType":"logic.properties.Extractor","x":-180,"y":32,"group":"3e01c1d58cea3340","id":"3ebc40f42dc0ac4b","targetId":0,"prop":"x velocity","version":2},{"gateVal":0,"mode":"less than","inputCount":2,"outputCount":2,"name":"Filter","behaviorType":"logic.logic.Filter2","x":0,"y":32,"group":"3e01c1d58cea3340","id":"3ebc7fc619957942"},{"gateVal":0,"mode":"greater than","inputCount":2,"outputCount":2,"name":"Filter","behaviorType":"logic.logic.Filter2","x":0,"y":-64,"group":"3e01c1d58cea3340","id":"3ebc80850753b440"},{"inputCount":2,"outputCount":1,"name":"Logic Gate","behaviorType":"logic.logic.Gate","x":180,"y":160,"group":"3e01c1d58cea3340","id":"3ebd3ba951e67b44","notes":"equal to 0","n_o":1,"gateType":"AND"},{"inputCount":3,"outputCount":1,"name":"Number","behaviorType":"logic.logic.Value","x":360,"y":160,"group":"3e01c1d58cea3340","id":"3ebd7239e1daaf44","startVal":1,"tag":"","roundMode":1},{"inputCount":3,"outputCount":1,"name":"Number","behaviorType":"logic.logic.Value","x":360,"y":32,"group":"3e01c1d58cea3340","id":"3ebd93a6a397cc42","startVal":2,"tag":"","roundMode":1},{"inputCount":3,"outputCount":1,"name":"Number","behaviorType":"logic.logic.Value","x":360,"y":-64,"group":"3e01c1d58cea3340","id":"3ebdd58adc170148","startVal":3,"tag":"","roundMode":1},{"delay":1,"count":1,"version":2,"inputCount":3,"outputCount":1,"name":"Timer","behaviorType":"logic.triggers.Timer","x":-180,"y":-192,"group":"3e01c1d58cea3340","id":"3ebe101e25965b45"},{"inputCount":1,"outputCount":0,"name":"Message","behaviorType":"logic.components.Message","x":0,"y":-192,"group":"3e01c1d58cea3340","id":"3ebe3442f6d71b4f","msg":"walkOn","route":"SendToSelf"}],"links":[{"input_id":"3eb8c344c70ebf40i2","output_id":"3e8bf5d3d0157949o0"},{"input_id":"3e8c071523106349i1","output_id":"3e8c274fcdc73146o0"},{"input_id":"3ebe101e25965b45i0","output_id":"3eb8c344c70ebf40o0"},{"input_id":"3eb8c344c70ebf40i0","output_id":"3eb8c344c70ebf40o0"},{"input_id":"3ebc40f42dc0ac4bi0","output_id":"3eb8c344c70ebf40o0"},{"input_id":"3eb8a293123d1947i0","output_id":"3eb8c344c70ebf40o0"},{"input_id":"3e8c071523106349i0","output_id":"3eb9ed2cfea13e41o0"},{"input_id":"3e8c274fcdc73146i1","output_id":"3eba01d878675146o0"},{"input_id":"3e8c274fcdc73146i1","output_id":"3eba01d878675146o1"},{"input_id":"3eb9ed2cfea13e41i1","output_id":"3eba01d878675146o1"},{"input_id":"3e8c274fcdc73146i1","output_id":"3eba01d878675146o2"},{"input_id":"3ebb1f748bec0140i1","output_id":"3eba01d878675146o2"},{"input_id":"3e8c071523106349i0","output_id":"3ebb1f748bec0140o0"},{"input_id":"3eb8c344c70ebf40i1","output_id":"3ebc14c33f4e6048o0"},{"input_id":"3ebc80850753b440i1","output_id":"3ebc40f42dc0ac4bo0"},{"input_id":"3ebc7fc619957942i1","output_id":"3ebc40f42dc0ac4bo0"},{"input_id":"3ebd93a6a397cc42i1","output_id":"3ebc7fc619957942o0"},{"input_id":"3ebd3ba951e67b44i1","output_id":"3ebc7fc619957942o1"},{"input_id":"3ebdd58adc170148i1","output_id":"3ebc80850753b440o0"},{"input_id":"3ebd3ba951e67b44i0","output_id":"3ebc80850753b440o1"},{"input_id":"3ebd7239e1daaf44i1","output_id":"3ebd3ba951e67b44o0"},{"input_id":"3eba01d878675146i0","output_id":"3ebd7239e1daaf44o0"},{"input_id":"3eba01d878675146i1","output_id":"3ebd7239e1daaf44o0"},{"input_id":"3eba01d878675146i0","output_id":"3ebd93a6a397cc42o0"},{"input_id":"3eba01d878675146i1","output_id":"3ebd93a6a397cc42o0"},{"input_id":"3eba01d878675146i0","output_id":"3ebdd58adc170148o0"},{"input_id":"3eba01d878675146i1","output_id":"3ebdd58adc170148o0"},{"input_id":"3ebe3442f6d71b4fi0","output_id":"3ebe101e25965b45o0"}]}}}

Here is a picture of the slightly modified run:


(Messages and switch added.)

Just delete your old jump bundle, paste in this, then edit your run to match the picture above.

Here’s why yours didn’t work:
The player is constantly setting the x velocity when moving, so anything else changing the x velocity (the impulse) will be overridden. By adding a small stop in the movement, you can now use the impulse X when you want.

Nice game btw!

Ty I will try it out for some reason it just started working the way I did it but ■■■ was not the way I wanted it ty for telling me how to do it! Also do you think the game is fun? Idk if my game idea fun. Run out of battery = restart pickup battery = refill battery bar!

1 Like

I think it’s a good idea. Maybe adding different actions with different energy costs too. like a dash or something. Art is very good!

Tell me if it works

Umm I can move but when I jump and land I can not also I wanted it to be like you lean right with right arrow and press w and you go diaginoal or somthing this you just go up


This is the current system cuase yours did not work and this when I do the arrow key then jump I do not move any x but if I do the A and D I do!

Art looks strangely similar to an asset pack I used for Color Complex :thinking:

where is the asset pack from?

Not sure while you’re asking, but here

Wasn’t saying there weren’t original sprites you made, just the background which I thought was funny because I had used the same one before in my game
My game (Color Complex)

2 Likes

Wow! This game’s art is Amazing!

It was from an asset pack on craftpix, but both this post and mine are off-topic

2 Likes

The asset pack waas not form craft pix it was this one 16x16 Industrial Tileset by 0x72 But the background was the same I am trash at pixel art and this my first game so I am using asset packs!

1 Like

Hey, is this problem solved? Can you please mark a solution?

1 Like

idk I messaged code aplaca and has some code I do not think you understand what I was trying to do so maybe?

1 Like

heres a way codealpaca explained the problem so if you can help I want the character to jump in the direction they are going, but they cannot change directions while in mid-air. Then I want the player to be able to use Arrow keys to select a direction, but they don’t move while doing this. When you click W (Jump) + Arrow Key, you will jump in that direction.

2 Likes