# Weight in Physics

0 Favourites
• 9 posts
• Hello, Dcrew here!

I'm wondering how to have an object wait, because I have box 1 and box 2 colliding with each other (top-down game) and box 2 is supposed to be triple box 1's weight and therefore harder and less farther to be pushed, I thought this could be done with the density settings but that doesn't seem to do anything!?

• ## Try Construct 3

Develop games in your browser. Powerful, performant & highly capable.

Construct 3 users don't see these ads
• Yeah any ideas how to set weight?

I have simple game with throwing darts and rocks, throwing to the boxes little dart have pin behaviour. Dart has more power than a rock knock when stuck in a box

Chceck this out: dl.dropbox.com/u/44710358/angrynerds.capx

throw in long pole... weird huh? :D

• I believe density is the way to go, but it depends how you interact with physics, if you have a 8 direction character with physics on it just to activate collision, you won't be able to slow down the character.

The character must be driven by physics only for the density to work on him... I guess :D

Delgado, seriously... I... don't understand what you said.

• The object's mass is density x area of collision mask. If one object's density is 3x another object's density, it only has 3x the mass if they have exactly the same area in their collision masks. Are you sure both objects have the same collision mask?

• Hey Ashley, would be possible to add a Mass parameter to the physics that overrides the mass of an object? Or that sets the density to match a specific mass?

I recognize that the mass based on the density x area have the benefit of adding realism to the simulation, but it also takes away control. It's very hard to design a game based on weight ratios among objects, because it's impossible to calculate the mass since we don't know the area value. If it's based on specific weights then it's just not possible to implement it right now.

• I second Animmaniac's idea!

• If I understood delgado correctly, I think you don't really need the mass here.

What you can do is on collision between the dart and the rock, create a distance joint between the two (not a pin, pin isn't relied to physics, it might end up with funny results). You can also add an impulse to the rock, that is a ratio of the dart's velocity.

From there, I think it would make the rock/dart move as a single object and give the impression that the momentum of the dart was transfered to the rock.

• mass of object is one thing but when i pin projectile to another physics object this object behaves strangely.

Yann sorry for my english ;/

Also is difficult to me to understand when I read in English.

I think Kyatric is closest :)

wants to achieve two things:

First-arrow sticks to every object

and stone as the ball bounces

Is it difficult?

Capx is updated and add arrow

Choice weapon with 1 and 2 key

• kyatric has it right.

rock & box collide: don't do anything

dart & box collide: create a distance joint between dart & box

dart density: small number

box density: medium number

rock density: big number

Keep increasing rock density & box density until it looks right.