Gamestudio Links
Zorro Links
Newest Posts
ZorroGPT
by mistery. 12/05/26 12:48
contractUpdate() is filtering if >2 rows
by mistery. 12/04/26 19:03
Removing outliers from files
by AndrewAMD. 12/02/26 15:26
SGT_FW
by Aku_Aku. 11/30/26 08:19
Experiences with cTrader
by JeyKey II. 11/27/26 09:04
make a complaint
by EW_bytes. 11/26/26 23:00
FXCM => AVA Trade Plugin???
by Martin_HH. 11/25/26 21:59
No connection to MT4
by Martin_HH. 11/23/26 06:38
AUM Magazine
Latest Screens
Dorifto samurai
Shadow 2
Rocker`s Revenge
Stug 3 Stormartillery
Who's Online Now
1 registered members (mistery), 2,680 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
EvanTJ, rht, MaliceTheMaker, Haitao_Ren, JimSimons
19250 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Camera #199695
04/01/08 01:22
04/01/08 01:22
Joined: Jun 2007
Posts: 43
Montréal
J
Julientdc Offline OP
Newbie
Julientdc  Offline OP
Newbie
J

Joined: Jun 2007
Posts: 43
Montréal
Hello,

We can make camera that can't pass across an other entity?

Or use the camera direcly with a collision function?

Thank you,
Julien

Re: Camera [Re: Julientdc] #199698
04/01/08 01:27
04/01/08 01:27
Joined: Feb 2008
Posts: 337
V
Vadim647 Offline
Senior Member
Vadim647  Offline
Senior Member
V

Joined: Feb 2008
Posts: 337
Something like that:
 Code:
vec_set(t_v2,vector(my.x,my.y,my.z+my.max_z));
			vec_set(t_v,vector(-384,0,0));vec_rotate(t_v,vector(camera.pan,my.tilt-30,my.roll));vec_add(t_v,t_v2);
			vec_set(camera.pan,vector(camera.pan,my.tilt-30,my.roll));
			c_trace(t_v2,t_v,IGNORE_ME|IGNORE_PASSABLE);
			if (trace_hit == 1)
			{
				vec_set(t_v,target);
				vec_sub(t_v,t_v2);
				vec_normalize(t_v,vec_length(t_v)-5);
				vec_add(t_v,t_v2);
			}
			vec_set(camera.x,t_v);

to use free camera with collision detection, attach it to moving small entity (maybe a ball)


I switched to other account since marth 2010. Guess which.

Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1