How does Solid work?

Just started using Construct 2? Post your questions here

Post » Tue Feb 07, 2017 5:38 pm

Nope. I haven't changed anything from the install of last night. I will just start a new project. I'll create a tiled background for the first layer, then lock it like in the tutorial. I start a new layer on top of it. On this layer, I have two objects: One solid, one 8Direction. They do not collide or stop.

The two sprite objects both have this second layer as the layer under it's properties in 'Common'. Depending on changing the Z Order, the moving object will pass over or under the solid object but won't stop.

The only events I have for the moving object are Every tick set angle towards mouse, and move forward when left button is down. The behavior I have for the moving object is 8Direction. The behavior for the solid object is Solid. That's all I have.
B
4
S
1
Posts: 6
Reputation: 314

Post » Tue Feb 07, 2017 5:51 pm

Have you disabled 8-direction behaviour? I can't see why you would need that move forward event.
B
47
S
18
G
84
Posts: 2,273
Reputation: 49,800

Post » Wed Feb 08, 2017 12:59 am

plinkie Suggested right. In 8-direction there's no disabling of solid collusion. It can be disabled only if 8-direction disabled. Also in case of manual movement like "Move at Angle", "Sprite.X+10" collusion won't work.

When dealing with collusion and having some issues always recheck:
*Make sure Solid "enabled"
*Make sure collusion with Solid objects enabled in Behavior you use for moving object
*Check collision polygons (in left-bottom of image editor) both of moving object and solid. It may be not be the reason of objects not colliding, but often reason of incorrect collusion. So don't forget always to check this one if something wrong.

Also making moving object to rotate towards mouse if that's the one that should collide with solid is not a good solution.
It's better to use invisible object for collusion with solid and visible object for everything else set to be in same position as invisible one.
I'm a Magician, not a Developer.
B
24
S
8
G
25
Posts: 107
Reputation: 14,378

Post » Wed Feb 08, 2017 1:24 am

Are you using physics by any chance?

Physics and solids do not work together.
Banned User
B
28
S
7
G
58
Posts: 1,229
Reputation: 34,830

Previous

Return to Beginner's Questions

Who is online

Users browsing this forum: No registered users and 2 guests