How do I get information for the current colliding wall?

Get help using Construct 2

Post » Wed Nov 09, 2016 8:04 pm

Hi all,
I was just wondering if there was a way to get the information of the 'thing' or 'wall' in this example that you're currently colliding with. I've set up a platformer that's got some wall grabbing on it, but since I don't want this to be apparent on every wall, I figured I'd just use an instance variable or something.

After a bit of tinkering I had no luck. If this isn't possible, I'm thinking of just doing some sort of checking sprite that'll overlap the wall and I'll get hold of things that way.

Anyone ever had a similar scenario?

Cheers
B
5
Posts: 22
Reputation: 283

Post » Wed Nov 09, 2016 8:39 pm

There are a few ways. When you do player on collision with wall, that particular wall then becomes the picked object. You could then use a sub event to compare if the wall instance variable 'grab' is true or false and go from there.
B
46
S
16
G
78
Posts: 2,166
Reputation: 46,349

Post » Thu Nov 10, 2016 6:37 pm

Hi Plinkie, thanks for the advice! Worked a treat in the end. I'll try to remember to post up the event sheet in case anyone else might need it in future.

Cheers
B
5
Posts: 22
Reputation: 283


Return to How do I....?

Who is online

Users browsing this forum: R0J0hound, volumetv and 14 guests