Trouble with overlapping objects

Get help using Construct 2

Post » Tue May 23, 2017 1:52 am

I have been banging my head against this problem I've been having with an example file. Basically, what I did was create grid-based movement but the character sprite for some reason cannot be within one unit of a non-passable terrain (passable and non-passable terrain is determined by a boolean instance variable).

Please Help!

https://drive.google.com/file/d/0Bx3kU1 ... sp=sharing
B
26
S
8
G
4
Posts: 68
Reputation: 4,424

Post » Tue May 23, 2017 10:09 pm

Yay, finally someone providing a .capx when posting an issue!

You need to reduce the collision polygon's size of the non-passable terrain sprites by 1 pixel on each edge.
(from 16x16 to 14x14)

Image

That'll do the job.
Apparently, C2 triggers an overlap when two objects collide, i.e. sharing the same coordinates on one edge.
"We can't solve problems by using the same kind of thinking we used when we created them."
- Albert Einstein
B
27
S
11
G
8
Posts: 528
Reputation: 7,091

Post » Tue May 23, 2017 11:40 pm

That did the trick! Thanks for the help!
B
26
S
8
G
4
Posts: 68
Reputation: 4,424


Return to How do I....?

Who is online

Users browsing this forum: Fenix18, Madsoggytoast and 52 guests