Gamestudio Links
Zorro Links
Newest Posts
Newbie Questions
by fairtrader. 12/05/23 14:22
Zorro Trader GPT
by TipmyPip. 12/04/23 11:34
Square root rule
by Smallz. 12/02/23 09:15
RTest not found error
by TipmyPip. 12/01/23 21:43
neural function for Python to [Train]
by TipmyPip. 12/01/23 14:47
Xor Memory Problem.
by TipmyPip. 11/28/23 14:23
Training with command line parameters
by TipmyPip. 11/26/23 08:42
Combine USD & BTC Pairs In Asset Loop
by TipmyPip. 11/26/23 08:30
AUM Magazine
Latest Screens
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Tactics of World War I
Who's Online Now
0 registered members (), 631 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
fairtrader, hus, Vurtis, Harry5, KelvinC
19019 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 2 of 3 1 2 3
Re: cameras and mouse movement [Re: Claus_N] #129266
05/10/07 18:38
05/10/07 18:38
Joined: Jun 2006
Posts: 2,640
Earth
Germanunkol Offline
Expert
Germanunkol  Offline
Expert

Joined: Jun 2006
Posts: 2,640
Earth
Voyager! Cardassians!! awesome!
I get what you mean now...

If I'm right you'll need to give us your code which moves the ship, because that needs to be changed. once in fps mode, you'll need to not make the ship move any more... if(camera_numer ==2) ??

Micha


~"I never let school interfere with my education"~
-Mark Twain
Re: cameras and mouse movement [Re: Claus_N] #129267
05/10/07 19:39
05/10/07 19:39
Joined: Nov 2005
Posts: 1,007
jigalypuff Offline OP
Serious User
jigalypuff  Offline OP
Serious User

Joined: Nov 2005
Posts: 1,007
i`m getting a possible endless loop in c_ship, would the wait be in the wrong place perhaps? should it be at the end?


Why does everyone like dolphins? Never trust a species which smiles all the time!
Re: cameras and mouse movement [Re: jigalypuff] #129268
05/10/07 19:50
05/10/07 19:50
Joined: May 2004
Posts: 1,510
Denmark
Claus_N Offline
Serious User
Claus_N  Offline
Serious User

Joined: May 2004
Posts: 1,510
Denmark
Oh sorry, yeah it should be at the end of the loop

Re: cameras and mouse movement [Re: Claus_N] #129269
05/10/07 19:57
05/10/07 19:57
Joined: Nov 2005
Posts: 1,007
jigalypuff Offline OP
Serious User
jigalypuff  Offline OP
Serious User

Joined: Nov 2005
Posts: 1,007
ok no poss endless loop now, but i`m just getting a black screen. were you have
// FPS camera code here should i move the camera 2 code up to there?
@germanumkol, the movement code is on the first page lol,


Why does everyone like dolphins? Never trust a species which smiles all the time!
Re: cameras and mouse movement [Re: jigalypuff] #129270
05/10/07 20:01
05/10/07 20:01
Joined: May 2004
Posts: 1,510
Denmark
Claus_N Offline
Serious User
Claus_N  Offline
Serious User

Joined: May 2004
Posts: 1,510
Denmark
Aaargh, I was too fast again :S

You also need to move the ship_camera(); line outside the if(camera!=2)-statement...

Sorry I missed that Hope I haven't missed any more

Re: cameras and mouse movement [Re: Claus_N] #129271
05/10/07 20:11
05/10/07 20:11
Joined: Nov 2005
Posts: 1,007
jigalypuff Offline OP
Serious User
jigalypuff  Offline OP
Serious User

Joined: Nov 2005
Posts: 1,007
ok, were the heck do i put it lol, i`ve treid 5 different places to no avail.
and again my thanks


Why does everyone like dolphins? Never trust a species which smiles all the time!
Re: cameras and mouse movement [Re: jigalypuff] #129272
05/10/07 20:17
05/10/07 20:17
Joined: May 2004
Posts: 1,510
Denmark
Claus_N Offline
Serious User
Claus_N  Offline
Serious User

Joined: May 2004
Posts: 1,510
Denmark
That should do it...

Code:
function c_ship
{
player = my;
my.scale_x = 2.0;
my.scale_y = my.scale_x;
my.scale_z = my.scale_x;
var ship_speed;
while (1)
{
if(camera_number != 2)
{
if (key_w == on)
{
if (ship_speed.x < 1)
{
ship_speed.x += 1.3 * time;
}
}
else
{
if (ship_speed.x >= 0)
{
ship_speed.x -= 0.05 * time;
}
}
if (ship_speed.x < 0) {ship_speed.x = 0;}
if (key_a == on)
{
my.pan += 3 * time;
my.roll - = 3 * time;
}
if (key_d == on)
{
my.pan -= 3 * time;
my.roll + = 3 * time;
}
if (ship_speed.z < 0) {ship_speed.z = 0;}
if (key_q == on)
{
my.tilt + = 3 * time;
}
if (ship_speed.z < 0) {ship_speed.z = 0;}
if (key_e == on)
{
my.tilt - = 3 * time;
}
ent_move (ship_speed.x, nullvector);
}
else
{
// FPS camera code here
if(key_a)
{
camera.pan += 3 * time;
}
if(key_d)
{
camera.pan -= 3 * time;
}
}

ship_camera();
wait (1);

}
}



Re: cameras and mouse movement [Re: Claus_N] #129273
05/10/07 20:35
05/10/07 20:35
Joined: Nov 2005
Posts: 1,007
jigalypuff Offline OP
Serious User
jigalypuff  Offline OP
Serious User

Joined: Nov 2005
Posts: 1,007
woohoo dude you rock. thank you so much.


Why does everyone like dolphins? Never trust a species which smiles all the time!
Re: cameras and mouse movement [Re: jigalypuff] #129274
05/10/07 20:39
05/10/07 20:39
Joined: May 2004
Posts: 1,510
Denmark
Claus_N Offline
Serious User
Claus_N  Offline
Serious User

Joined: May 2004
Posts: 1,510
Denmark
No problem mate, I'm glad you got it working!

Re: cameras and mouse movement [Re: Claus_N] #129275
05/10/07 21:13
05/10/07 21:13
Joined: Nov 2005
Posts: 1,007
jigalypuff Offline OP
Serious User
jigalypuff  Offline OP
Serious User

Joined: Nov 2005
Posts: 1,007
spoke to soon lmao, why is it once one problem is solved another crops up????
when the ship tilts in isometric view and i switch to the new view you just sorted out the model is tilted like the ship mesh, so at times the camera view ends up outside the bridge, is there a way to lock the fps view to a spot on the bridge?


Why does everyone like dolphins? Never trust a species which smiles all the time!
Page 2 of 3 1 2 3

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