How do I set the HitBox (Platform Behaviour) size every tick

Get help using Construct 2

Post » Wed Feb 08, 2017 9:39 am

Hi there, i've been following a lot of tutorials on platforming games and one thing that I need to understand (but haven't found the right tutorial yet) is how to set the PlayerBox object (the one i'm using for collision detection) to the same size as the Player Animations object?

Many thanks!
B
12
S
3
Posts: 59
Reputation: 870

Post » Wed Feb 08, 2017 10:19 am

PlayerBox set size Player.width, Player.height
Last edited by plinkie on Wed Feb 08, 2017 11:33 am, edited 1 time in total.
B
47
S
17
G
82
Posts: 2,232
Reputation: 48,611

Post » Wed Feb 08, 2017 10:32 am

Thank you, I tried that but get the screen shaking all the time

The Player Box object is called PlayerBox

The Player Animations object is called PlayerAnimations

So would the expression be

PlayerBox srt size

Width = PlayerAnimations.X
Height = PlayerAnimations.Y

Isn't that placing the object along the X and Y index rather than it's dimensions?
B
12
S
3
Posts: 59
Reputation: 870

Post » Wed Feb 08, 2017 10:59 am

Yeah set width and height, sorry not had coffee yetttt
B
47
S
17
G
82
Posts: 2,232
Reputation: 48,611


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 9 guests