Gamestudio Links
Zorro Links
Newest Posts
Z9 getting Error 058
by k_ivan. 04/25/26 19:13
ZorroGPT
by TipmyPip. 04/25/26 16:09
Stooq now requires an API key
by jcl. 04/13/26 09:42
Strange "Alien" Skull created with >Knubber<
by NeoDumont. 04/10/26 18:58
400 free seamless texture pack downl. here !
by NeoDumont. 04/08/26 19:55
AUM Magazine
Latest Screens
Dorifto samurai
Shadow 2
Rocker`s Revenge
Stug 3 Stormartillery
Who's Online Now
1 registered members (AndrewAMD), 3,675 guests, and 8 spiders.
Key: Admin, Global Mod, Mod
Newest Members
valino, juergenwue, VladMak, Geir, ondrej
19209 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
help with camera position #138377
06/27/07 10:43
06/27/07 10:43
Joined: Mar 2006
Posts: 6
D
developerno1 Offline OP
Newbie
developerno1  Offline OP
Newbie
D

Joined: Mar 2006
Posts: 6
hi guys ,
i am new to gamestudio and dont know much about camerapositioning , i am trying to simulate a game reading fighting game workshop tutor from aum resources.
there the camera has to be positioned b/w the 2 players and below is the code given for it in the tutor but when i do this in A6.5 PRO the camera shows somewhere in the air . please help.................
Code:
 function pos_camera()
{
camera.z = 90;
camera.x = ((right.x+left.x)/2);
camera.y = - ((right.x-left.x) + 50);
wait (1);
}


right and left are the two fighters

Re: help with camera position [Re: developerno1] #138378
06/27/07 11:07
06/27/07 11:07
Joined: Mar 2007
Posts: 776
Poor village - Poland ;)
tompo Offline
User
tompo  Offline
User

Joined: Mar 2007
Posts: 776
Poor village - Poland ;)
Quote:

camera.y = - ((right.x-left.x) + 50);



I don't know this tut but try change to:
camera.y = - ((right.y-left.y) + 50);


Never say never.
Re: help with camera position [Re: tompo] #138379
06/27/07 18:37
06/27/07 18:37
Joined: Jul 2006
Posts: 150
Deutschland/Germany, nahe Hamb...
dennis Offline
Member
dennis  Offline
Member

Joined: Jul 2006
Posts: 150
Deutschland/Germany, nahe Hamb...
Hi developerno1!

I think I've seen the tutorial a bit ago.....

The camera should be positioned between th etwo players (camera.x) and
the camera should be so far away on the y-axis that you can see the two players at the left and the right border of your screen. (camera.y)

I think it has worked in my project with some "very little" problems....

To solve your problem it would be good to know if the camera is...
1.) ...placed in the air and you see the air and any fighter
2.) ...placed in the air and you see the fighters

You should be aware of the following things...

1.) Using this code your fighters have to be positioned on the x-axis
2.) You have to set the correct angle of the camera (try: pan=90,tilt=0,roll=0)
3.) You should check if the camera is on the same height as the fighters (z=90)
4.) The "pos_camera()"-function should be in a loop

Hope that helps you..;)


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