Two cameras (switching)

People, help me solve the problem with two cameras.
The first camera operates on arcball.
Second camera with a walkigenerator.
When you move the active camera, the inactive one also moves. This disturbs the view of the inactive camera.
I don’t know how to program.
The solution is probably simple)

thanks!
Cam_trouble

Hi!

In this case, the Set Trait Paused node should help, in which we specify Trait and the value, but it works only for logical nodes, it will not work on Bundle and Trait. Although I think that we need to expand the capabilities of such a site or call it differently.

As a result, the simplest solution, as I see it, is to remember the position of the camera when switching and to set it back when returning.

Sample: switch_move_camera.blend

3 Likes

thanks for the direction!
Did almost what I wanted

The file contains not a blend, but a zip archive (change the extension)

Switch_cam.blend (134.2 KB)

can you tell me what node design can replace the code?
“object.transform.rotate (object.transform.world.right (), -mouse.movementY / 100);”
difficulty with “object.transform.world.right”.

Trying to intercept the slider action when hovering over it. To disable scene rotation.
I collect my own arcball on the nodes. the hex script is not paused.

I apologize for the offtopic. I would not like to post a new topic because of this question

If I’m not mistaken, the Get World Orientation site should help.

Got this message when opening your file:
File written by newer Blender binary (290.0), expect loss of data!

For Armory3D to work correctly, you need to use Blender 2.83 LTS version.

I tried. Probably I’m doing something wrong

It seems that there is nothing to lose)

accidentally overwritten part of the code

Alternative:

switch_move_camera.blend (830.9 KB)

P.S. Могли ведь обсудить и без переводчика =)

1 Like

Я аж глаза потёр )))

Thanks for the ideas!

Here, in examples, work on scripts and on nodes

normas
nenormas

3 Likes

Made a node for turning using the ArcBall algorithm from the Bundle. It works for me similarly in the example. In this case, it will be possible to pause.

Scripts:

  • Node to add to all: LN_rotate_object_arcball.zip
    In this case:

    • python file is added to ..\ArmorySDK\armory\blender\arm\logicnode\transform\
    • haxe file is added to ..\ArmorySDK\armory\Sources\armory\logicnode\
  • An example of a project with its own nodes (the description and file name in python are slightly different):
    switch_move_camera_custom_node.zip
    Blender can be unstable with custom nodes.

I don’t know whether to add such a node to the engine source, whether it is necessary or possible to modify the Rotate Object node. This is how others see fit.

I wonder in your example how the variant with the node will work?

1 Like

Great!

You are a wizard!

Everything works as intended. Pauses when you hover over the slider.

Good

1 Like

I am glad to help! =)

3 Likes

Perhaps it would be more logical to refine the canvas so that it would have priority over the rest. I have only a special case.
Thanks again!

2 Likes

Demonstration
Demo

Files (.blend rename .zip)Base_For_Web.blend (237.1 KB)

3 Likes