Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Trigular Motion
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
TheZsterBunny




PostPosted: Sat Jan 15, 2005 10:30 pm   Post subject: Trigular Motion

So I'm putting off doing a biology project by playing with turing again.

I've decided that i'mma gonna make an asteroids ripoff.

'cept its gonna be 2 player.

Right now i"m working on the motion of the ships.

I have a parameter called 'orientation' which stores the angle of rotation of the ship (degrees).

How would I go about having a ship drift and alter course?

--edit--

Question still stands, but i'm going to do this in java.

Move me plz?

-Z
Sponsor
Sponsor
Sponsor
sponsor
Cervantes




PostPosted: Sat Jan 15, 2005 11:19 pm   Post subject: (No subject)

Zster wrote:
So I'm putting off doing a biology project by playing with turing again.

Bah! I put off four projects (three of which are ISU's) all day, due to playing with Turing. 8)

Anyways, to your question:
Check out Zylum's tutorial on ship movement for Asteroid type games. It should help you greatly.
Actually, what exactly do you mean by, "drift and alter course"? If you mean something other than what Zylum has done in his tutorial, please clarify. Smile
-Cervantes
TheZsterBunny




PostPosted: Sat Jan 15, 2005 11:51 pm   Post subject: (No subject)

Right.

Forgot about that, but i've already some similar code.

I'll bet you've played EVNova before. In this game, you can change the direction you're facing (ship) without moving in that direction. Sort of like a drifting car.

I've attached some prelim. turing code to show what the game'll look like.

Of course, i don't yet know the equiv. of array char of boolean in java Embarassed

-Z

--edit--

lol. reviewing code. Seems i'm more used to having many procedures now. thanks java Wink



Ship War.t
 Description:

Download
 Filename:  Ship War.t
 Filesize:  5.62 KB
 Downloaded:  125 Time(s)

Cervantes




PostPosted: Sun Jan 16, 2005 9:54 am   Post subject: (No subject)

Never played EVNova before.
Perhaps you could have six buttons for each player. Forward, back, turn left, turn right, strafe left (move perpindicular to the direction you're facing) and strafe right.
That seems to easy, you must have thought of that already. I guess I'm still not understanding the question Confused
TheZsterBunny




PostPosted: Sun Jan 16, 2005 11:13 am   Post subject: (No subject)

Alright, I'll try to explain in a more general sense.

When you drive a car, your wheels apply force to the road to move you foreward. Because of this design, cars can only move in the direction that the wheels dictate.

In space, however, once you're moving, there is very little that slows you down. Once you've accelerated in a certain direction, regardless of where you're aiming at, you will continue in your direction untill you accelerate (thrusters) again.

?

-Z
Cervantes




PostPosted: Sun Jan 16, 2005 12:32 pm   Post subject: (No subject)

Wow. When I first ran your program, I thought to myself, "He should really fix it so that your ship doesn't always move in the direction it's facing."
Here's my mod:



Ship War Drift.t
 Description:

Download
 Filename:  Ship War Drift.t
 Filesize:  5.93 KB
 Downloaded:  119 Time(s)

TheZsterBunny




PostPosted: Sun Jan 16, 2005 1:41 pm   Post subject: (No subject)

domo

^_^

-Z
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 7 Posts ]
Jump to:   


Style:  
Search: