How do I user overlapping at offset?

Get help using Construct 2

Post » Wed Jun 11, 2014 11:10 am

I want to detect if my Hero is standing next to a Healer.

2014-06-11_6-59-50.png


I thought I could do this by checking "overlapping at offset", granted, I would need to do it at every angle. I'm just testing one angle right now, and can't seem to get that to work.

2014-06-11_7-05-21.png


The collision box of the Hero is offset by 1, while the Healers covers the entire sprite.

What am I missing here to make this work? Is there a better way?
You do not have the required permissions to view the files attached to this post.
B
17
S
3
Posts: 33
Reputation: 1,646

Post » Wed Jun 11, 2014 1:12 pm

Just taking a quick guess but are you sprites 16x16?

If so just try changing the offset check to Hero.X + 8 and see if that works.
B
46
S
23
G
7
Posts: 459
Reputation: 6,763

Post » Wed Jun 11, 2014 2:36 pm

No, the overapping at offset is already taking in account the hero origin, replace your hero.x and hero.y by 0
Game design is all about decomposing the core of your game so it becomes simple instructions.
B
52
S
22
G
18
Posts: 2,122
Reputation: 17,093

Post » Sat Jun 14, 2014 11:44 am

Thanks @Aphrodite! That was the trick! I did not realize it already took into account the origin.
B
17
S
3
Posts: 33
Reputation: 1,646


Return to How do I....?

Who is online

Users browsing this forum: megatronx, RetrocadeMedia and 1 guest