Gamestudio Links
Zorro Links
Newest Posts
FXCM demo test failed
by qin. 01/13/26 13:53
Camera always moves upwards?
by NeoDumont. 01/12/26 09:39
Alpaca Plugin v1.5.2 Release
by kzhao. 01/11/26 13:42
Alpaca Plugin v1.4.0
by kzhao. 01/11/26 13:38
separating groups of 3 digits by a comma
by joe_kane. 01/11/26 00:01
MRC.c and WFO
by joe_kane. 01/10/26 23:58
BarOffset (default = 940 for daily bars?
by joe_kane. 01/10/26 23:46
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
0 registered members (), 5,502 guests, and 4 spiders.
Key: Admin, Global Mod, Mod
Newest Members
promfast, joe_kane, Namitha_NN, Syndrela, agasior
19190 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Camera.genius #250881
02/10/09 13:44
02/10/09 13:44
Joined: Sep 2005
Posts: 75
CA, Orange County
Gerrit Offline OP
Junior Member
Gerrit  Offline OP
Junior Member

Joined: Sep 2005
Posts: 75
CA, Orange County
Hi everyone,
I am designing a game where the player is a dog (I have ENTITY* dog_player; defined at the beginning of the program)
The statements below work fine except that I continue to see the dog! I single stepped through the code and the dog does dissapear when executing the first line "camera.genius=dog_player;" but the dog re-appears when the program executes "camera.y -= (15 * sin(dog_player.pan);". I assumed that this line somehow affected the camera so I added a last line "camera.genius=dog_player;" (just to test) but to no avail the dog remains visible....

Any suggestions?

camera.genius=dog_player;
vec_set(camera.x,dog_player.x);
camera.z += 5;
camera.arc=20;
camera.tilt -=25;
camera.pan= dog_player.pan;
camera.y -= (15 * sin(dog_player.pan));
camera.x -= (15 * sin(dog_player.pan));
camera.genius=dog_player;

Re: Camera.genius [Re: Gerrit] #251004
02/11/09 07:53
02/11/09 07:53
Joined: Nov 2008
Posts: 28
Athens, Greece
NeoJT Offline
Newbie
NeoJT  Offline
Newbie

Joined: Nov 2008
Posts: 28
Athens, Greece
Hi Gerrit.

the camera.genius work fine...
The entity is INVISIBLE ONLY if the camera position is INSIDE the entity (like 1st person).

When program execute "camera.y -= (15 * sin(dog_player.pan));" send the camera outside from the entity and make the dog_player VISIBLE.

Re: Camera.genius [Re: NeoJT] #251441
02/13/09 04:12
02/13/09 04:12
Joined: Sep 2005
Posts: 75
CA, Orange County
Gerrit Offline OP
Junior Member
Gerrit  Offline OP
Junior Member

Joined: Sep 2005
Posts: 75
CA, Orange County
NeoJT

I did not realize that the camera has to be in the entity for camera.genius to work. Now it makes sence.
Thank you for your help
Gerrit


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