Gamestudio Links
Zorro Links
Newest Posts
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/22/24 13:41
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (NnamueN, Akow, 1 invisible), 1,421 guests, and 6 spiders.
Key: Admin, Global Mod, Mod
Newest Members
LucasJoshua, Baklazhan, Hanky27, firatv, wandaluciaia
19054 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
locked to world + rotation? #327101
06/04/10 15:32
06/04/10 15:32
Joined: Apr 2010
Posts: 47
D
Darkmatters Offline OP
Newbie
Darkmatters  Offline OP
Newbie
D

Joined: Apr 2010
Posts: 47
Hi all again,

I want to lock an object to the world, and use the following code...

{vec_set(obj_mdl.x,vector(x,y,z));vec_set(obj_mdl.pan,tubey.pan); vec_for_ent(obj_mdl.x,tubey);}

Which works fine.... but I also want to rotate it, with the following line, ot the obj rotates and turns with the world.

vec_add(obj_mdl.pan,vector(x,0,0));

Whic does NOT work....probably because the parameters are holding it in position??
So.... any ideas? apart from animation???


As usual, thanks in advance....
D.

Re: locked to world + rotation? [Re: Darkmatters] #327191
06/04/10 23:52
06/04/10 23:52
Joined: Apr 2006
Posts: 737
Ottawa, Canada
O
Ottawa Offline
User
Ottawa  Offline
User
O

Joined: Apr 2006
Posts: 737
Ottawa, Canada
Hi!

If you are trying to have the object rotate with the world
so that it appears not to move you have to
make the object follow the movement of the world

so (not code)
vec_set ( your object, world pan or position....)


Hope this helps!
Ottawa laugh

Ver 7.86.2 Pro and Lite-C

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

Gamestudio download | chip programmers | 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