How do I Jump Strength for Varying Tile Heights

Get help using Construct 2

Post » Fri Oct 23, 2015 6:38 am

Hi everyone,

I was thinking of having an enemy jump when next to a tile map wall and having said enemy adjust its jump strength accordingly to the height of the wall. how would you find the highest tile co-ordinate?
B
37
S
11
G
3
Posts: 279
Reputation: 8,396

Post » Fri Oct 23, 2015 6:17 pm

Here's a capx:
https://dl.dropboxusercontent.com/u/542 ... _jump.capx

To find the height of the wall you can use a loop with either "overlaps at offset" or looking at the tile itself with "tile at".

To calculate the jumpstrength use this formula:
jumpstrength = sqrt(2*gravity*height)
B
91
S
31
G
102
Posts: 5,234
Reputation: 67,254

Post » Sat Oct 24, 2015 4:46 am

wow you are beast R0J0hound! thank you so much!! this is exactly what I was having trouble with. I think that I lack an understanding of how to approach such problems. I must study your examples thoroughly so that I can store them in my brain! Thanks again
B
37
S
11
G
3
Posts: 279
Reputation: 8,396


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 4 guests