Overlapping?

Get help using Construct 2

Post » Tue Jul 02, 2013 8:32 pm

Hi!
Who will explain me about overlapping?

how i use this condition?

thanks
B
10
S
2
G
2
Posts: 81
Reputation: 1,757

Post » Tue Jul 02, 2013 11:43 pm

Each object have a collision mesh or mask, whatever you want to call it, and if they are overlapping the condition will be true. Its a bit easier to explain if you take 2 sprites, and open them in the C2 paint editor. In the left side at the bottom, there is a collision button, if you press that, you can see the collision mesh for the sprite.

You can manipulate the collision mask here, or you can right click the sprite, and choose set as box I think its called and it will make the whole sprite a collision mask, or you can choose guess collision (Cant remember the name) and C2 will base the collision mask on what is in the image. Guess collision is only really useful if your sprite have transparency.

When you use the overlapping condition, its not the actual sprite or whats painted in it, that it uses. but the collision mask. So if two of these mask overlap the overlapping condition will be true and whatever action you have specified for that condition will be triggered.nimos1002013-07-02 23:44:01
B
44
S
11
G
2
Posts: 1,182
Reputation: 6,838

Post » Wed Jul 03, 2013 12:04 am



When whe talk about overlapping , we talk about multiple objects touching each others , as described on the picture above

There's 2 primary events when talking about collision

Is overlapping

and

On Collision

And the main difference between the two is that ...

On Collision only fires once , when the two collision boxes enter in collision

While ...

is Overlapping fires when the two collision boxes are overlapping
and will continue triggering until the two boxes aren't overlapping anymore ...

You could say that on collision is a Is overlapping with a trigger once but that's another subject

Cheers !

P.S: Read further on the manual and get a free badge ! ;)Whiteclaws2013-07-03 00:08:05
B
42
S
17
G
17
Posts: 2,247
Reputation: 17,461


Return to How do I....?

Who is online

Users browsing this forum: David181, OBLIVION, Rayth and 14 guests