Scirra / Construct-feature-requests

A place to submit feature requests and suggestions for Construct.
https://www.construct.net
9 stars 1 forks source link

(Physics) Ability to Freeze X / Y #139

Open SalmanShhh opened 5 months ago

SalmanShhh commented 5 months ago

Reviewed guidelines

Checked for duplicate suggestions

Summary

its quite frustrating that you can only use the all or nothing with freezing physics of an object. having the ability to do set them individually is strongly needed especially to cut down on workflow bloat while working on physics driven games.

Possible workarounds or alternatives

right now its having to always add the variable for each transform variable and then doing a for each loop to reset the velocities to 0

Proposed solution

Bool option on the physics behaviour to set Freeze X , Y individually

Why is this idea important?

as I'm working on more physics driven games, its becoming very important and tidious as projects get bigger and bigger in addition to slowing down development at the start. (https://i.imgur.com/PATyNAN.mp4) (https://i.imgur.com/uGddK4W.mp4)

Additional remarks

No response

Nabu0001 commented 5 months ago

The C3 Physics "Immovable" property is already related to specific instance. No force will be applied to those instances until you set them to "Movable" again. Is this what you were talking about ?

SalmanShhh commented 5 months ago

The C3 Physics "Immovable" property is already related to specific instance. No force will be applied to those instances until you set them to "Movable" again. Is this what you were talking about ?

No I'm talking about is different, immovable freezes physics on the X AND Y axis. What I'm requesting is being able to toggle either on an instance. There's a similar feature in other engines.

biDvL.png

Nabu0001 commented 5 months ago

What do you mean exactly ? I understood that you want to freeze an object, so that physics forces don't apply on it anymore. Is that correct ? You can either toggle "Immovable" at runtime via expression or Javascript, and from the editor under an object Physics properties.

SalmanShhh commented 5 months ago

What do you mean exactly ? I understood that you want to freeze an object, so that physics forces don't apply on it anymore. Is that correct ? You can either toggle "Immovable" at runtime via expression or Javascript, and from the editor under an object Physics properties.

Any option is fine as long as it's possible to freeze either axis on a physics object, just so we don't only have the all or nothing method we have now which is setting an object to immovable.

Nabu0001 commented 5 months ago

Ok, I get it ! Then I think you could use the prismatic joint of the Physics behavior. It allows specifically to limit movement along an axis (represented by an angle) between two objects.

SalmanShhh commented 5 months ago

Ok, I get it ! Then I think you could use the prismatic joint of the Physics behavior. It allows specifically to limit movement along an axis (represented by an angle) between two objects.

Frankly it's too tedious, when an easier option could exist