Ambiera Forum

Discussions, Help and Support.

Ambiera Forum > CopperCube > Help with CopperCube
Camera following 2 objects

abunimer
Registered User
Quote
2023-02-26 17:23:13

Hi , i just wanna know how to make the camera follows 2 objects at the same time just like in the fighting games ?


Aiming_bullets
Guest
Quote
2023-02-26 18:36:08

you can calculate the middle point between two objects with the help of javascript and use that as a target position for your camera.


just_in_case
Moderator
Quote
2023-02-26 20:07:15

@Aiming_bullets is correct, but you also need to calculate the distance of the camera and the objects, so that your objects always remain in the view of the camera, by moving the camera close or further from the object.


Abunimer
Guest
Quote
2023-02-27 02:49:26

Im not good at programing , i just wanna know how the code look like


Create reply:


Posted by: (you are not logged in)


Enter the missing letter in: "Internatio?al" (you are not logged in)


Text:

 

  

Possible Codes


Feature Code
Link [url] www.example.com [/url]
Bold [b]bold text[/b]
Image [img]http://www.example.com/image.jpg[/img]
Quote [quote]quoted text[/quote]
Code [code]source code[/code]

Emoticons


   






Copyright© Ambiera e.U. all rights reserved.
Privacy Policy | Terms and Conditions | Imprint | Contact