Jump to content

Organize work around joints


photo

Recommended Posts

Hello, I want to create a test turret, for that I created 2 bodies and added hindge joint.

image.thumb.png.97157ab8818813c1d2d03040bab06077.png

But as you can see it's hard to work with thing you can't see, so I tried to check it closely:

image.thumb.png.c6d964f8425b107804fba5f64b52b5f2.png

Connecting to this I have couple questions:

1. As I been trying to change joint parameters and see nothing changed in viewport, I presume visible representation on constraints is not presented?

2. I can't change joint position, looks like it attached to origin of node, but if node is not aligned to it's rotation center, how can I handle to place joint where I need it to be?

 

Link to comment
50 minutes ago, morbid said:

Are you sure you want turret to be physical? Usually such things are done with simple node rotation or with animations.

Well, it must have at least convex hull for collision detection, but for rotation yes, it could be just node connection. But I needs to set constraints for thing like that (also origins for rotations), for turrets and for barrels to limit it's borders. Bones not a good choise I presume, it attaches skinninig for static geometry? And also I ma not sure if constraints for bones exports with all animations since it's more up to physics ragdolls.

So I had thought to use physics like that

image.thumb.png.70f733c57351168f79cd72e695483c46.png

Otherwise I need to create some plugin for Editor (I am not sure it's so simpe) to create constraints like that or export it from outside, but this will make pipeline more complex.

 

Link to comment
39 minutes ago, morbid said:

Well, you don't need physics here, it's an overkill.

Well, this depends on what needs to be done, for expamle if I want to be possible to blow up turret in air with physics - best way to make it with physics joints, so I am not agree with overkill.

But this is not necessary for now, it should be game ship model - turret must rotate, barrel recoild and move back. Main point here - this is not only one model, for example we could have a small turret gun attached multiple times to different places so better if turret could be Node Reference too. Needs to create confortable enough workflow for adding models of ships, weapons and control logic of it's animation. API is C++.

Link to comment

image.thumb.png.3024f25c3068a9f7e503184a6bf94c27.png

Example of how it works now - without physics but with custom constraints, looking for way to recreate similar logic into Unigine Editro to simplify development.

Link to comment
On 4/24/2020 at 4:19 PM, oleg.ferapontov said:

Well, this depends on what needs to be done, for expamle if I want to be possible to blow up turret in air with physics - best way to make it with physics joints

I'd say if you need a solution to destroy a turret in-game you still don't need joints. You need a collider body and a model to imitate a broken turret.

On 4/24/2020 at 4:27 PM, oleg.ferapontov said:

Example of how it works now - without physics but with custom constraints, looking for way to recreate similar logic into Unigine Editro to simplify development.

Hmm, can you clarify the task again? Because now I don't understand why regular move/rotation gizmos wouldn't work for you in UnigineEditor. In the first place I thought you're looking for a code that will rotate your guns in the application.

How to submit a good bug report
---
FTP server for test scenes and user uploads:

Link to comment
37 minutes ago, morbid said:

I'd say if you need a solution to destroy a turret in-game you still don't need joints.

Let's forget about that for now)

38 minutes ago, morbid said:

In the first place I thought you're looking for a code that will rotate your guns in the application.

Code is not the problem, tool to create: 1) center of rotation or movement 2) constraints for it. Gizmo is not exactly the thing. 

Link to comment
×
×
  • Create New...