Results 1 to 23 of 23

Thread: Phisics

  1. #1

    Thread Starter
    Frenzied Member Motoxpro's Avatar
    Join Date
    Sep 2001
    Location
    Spiro, OK
    Posts
    1,211

    Phisics

    anyone know where i can learn t do this...thx
    (i know i spelled it wrong..sorry)

  2. #2
    Physics.

    Game physics vary wildly depending on the environment (FPS, flight sim, space sim, etc.). What environment specifically?

  3. #3
    DaoK
    Guest
    Fox webpage have something about Gravity and stuff like that but I do not remember the link

  4. #4
    DaoK
    Guest
    Here is the link : http://fox.acky.net/

  5. #5

    Thread Starter
    Frenzied Member Motoxpro's Avatar
    Join Date
    Sep 2001
    Location
    Spiro, OK
    Posts
    1,211
    thx DaoK
    and filburt, im making a Motocross Game and i have to make the motorcycle come of the ground when it hits the jumps and go up the hills right and stuff like that

  6. #6
    Have you taken Calculus yet?

  7. #7
    DaoK
    Guest
    Yes I used some code for my game, the gravity one is nice

  8. #8

    Thread Starter
    Frenzied Member Motoxpro's Avatar
    Join Date
    Sep 2001
    Location
    Spiro, OK
    Posts
    1,211
    Originally posted by filburt1
    Have you taken Calculus yet?
    im in middle school

  9. #9
    Frenzied Member Jotaf98's Avatar
    Join Date
    Jun 2000
    Location
    I'm not gonna give you my IP address! Ok... Portugal, South-Western Europe, 3rd rock from the sun (our star is easy to find, a 47 Ursae Majoris in the Milky Way :p )
    Posts
    1,457
    Here's some Pseudo-Code. Remember that ALL VARIABLES SHOULD BE DOUBLES AND NOT INTEGERS OR LONGS OR WHATEVER!!!

    Gravity = 0.1 'Or some other small number, you might have to experiment with this
    TerminalVelocity = 0.5 'Experiment with this too, it's the amximum falling speed

    'The following code is supposed to be ran EVERY FRAME

    1) If SpeedZ > TerminalVelocity And Player is not touching the gground Then SpeedZ = SpeedZ - Gravity
    2) PlayerZ (the player's height) = PlayerZ + SpeedZ
    3) If the player touches the ground, then
    3a) SpeedZ = 0.5*SpeedZ
    3b) If SpeedZ < 0.1 Then SpeedZ = 0

    That should do it
    (I might have forgotten some important stuff so tell me if it doesn't work)
    Code:
    Temp = Me.GetIQ()
    'Error 9: Overflow
    'DON'T PANIC! :eek:

    To learn how to use realistic effects in your games like fire, rain, snow and magic effects, read my article on particles systems here.


    Jotaf's Theories!
    "Cats land on their feet. Toast lands peanut butter side down. A cat with toast strapped to its back will hover above the ground in a state of quantum indecision."

  10. #10
    transcendental analytic kedaman's Avatar
    Join Date
    Mar 2000
    Location
    0x002F2EA8
    Posts
    7,221
    that's pseudoballistics jotaf (something you have in old super mario bros games), for real ballistics the friction is proportional to the velocity
    Use
    writing software in C++ is like driving rivets into steel beam with a toothpick.
    writing haskell makes your life easier:
    reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
    To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.

  11. #11
    Frenzied Member Jotaf98's Avatar
    Join Date
    Jun 2000
    Location
    I'm not gonna give you my IP address! Ok... Portugal, South-Western Europe, 3rd rock from the sun (our star is easy to find, a 47 Ursae Majoris in the Milky Way :p )
    Posts
    1,457
    We don't need friction, it's a motorcycles game and not a science project
    Code:
    Temp = Me.GetIQ()
    'Error 9: Overflow
    'DON'T PANIC! :eek:

    To learn how to use realistic effects in your games like fire, rain, snow and magic effects, read my article on particles systems here.


    Jotaf's Theories!
    "Cats land on their feet. Toast lands peanut butter side down. A cat with toast strapped to its back will hover above the ground in a state of quantum indecision."

  12. #12
    transcendental analytic kedaman's Avatar
    Join Date
    Mar 2000
    Location
    0x002F2EA8
    Posts
    7,221
    Originally posted by Jotaf98
    We don't need friction, it's a motorcycles game and not a science project
    without friction there would be no terminal velocity
    I'm studying computer science and physics is a very vital part.
    I have a motorcross game called action cross somewhere which includes nonelastic collision with 2d spring dynamics and rotation momentum. If you don't want physics, try archanoid
    Use
    writing software in C++ is like driving rivets into steel beam with a toothpick.
    writing haskell makes your life easier:
    reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
    To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.

  13. #13
    DaoK
    Guest
    Gravity = 0.1

    should be 9.8

  14. #14
    Fanatic Member
    Join Date
    Oct 2000
    Location
    Oregon
    Posts
    962
    9.8 would be for m/sec
    0.1 would be 5/48m/sec

    for light-years/sec, it would be one very small number.



    What I am attempting to point out is that it matters what system you are using.
    Involved in: Sentience

  15. #15
    Fanatic Member PsychoMark's Avatar
    Join Date
    Feb 2001
    Location
    Netherlands
    Posts
    540
    kedaman, you have action cross?


    Isn't that the DOS game where you drive a very flat looking motorcycle and you have to get the apples or something?

    If it isn't, ignore this post, if it is, can you send it to me? Been looking for it for three years (lost the disk )
    Teaudirenopossum.Musasapientumfixaestinaure.
    (I can't hear you. There's a banana in my ear)

  16. #16
    transcendental analytic kedaman's Avatar
    Join Date
    Mar 2000
    Location
    0x002F2EA8
    Posts
    7,221
    Yep! I have two versions of it, while the later contains an level editor I used to make levels where the motorcycle would fall and do all kinds of loops and tricks without you touching any key at all, hehe that was fun. I'll see if i can find it.
    Use
    writing software in C++ is like driving rivets into steel beam with a toothpick.
    writing haskell makes your life easier:
    reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
    To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.

  17. #17
    Fanatic Member PsychoMark's Avatar
    Join Date
    Feb 2001
    Location
    Netherlands
    Posts
    540
    Cool, I only had about 8 levels and no editor at all.... if you find it can you send it to [email protected] ?

    ....sorry for the interruption, you may now continue rambling about stuff I don't understand
    Teaudirenopossum.Musasapientumfixaestinaure.
    (I can't hear you. There's a banana in my ear)

  18. #18
    transcendental analytic kedaman's Avatar
    Join Date
    Mar 2000
    Location
    0x002F2EA8
    Posts
    7,221
    I found the earlier version (1.1) with no level editor and 24 levels, I'll search for the other one if you want.
    Use
    writing software in C++ is like driving rivets into steel beam with a toothpick.
    writing haskell makes your life easier:
    reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
    To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.

  19. #19
    Fanatic Member PsychoMark's Avatar
    Join Date
    Feb 2001
    Location
    Netherlands
    Posts
    540
    If it's not a problem for you....

    Just send all you can find
    Teaudirenopossum.Musasapientumfixaestinaure.
    (I can't hear you. There's a banana in my ear)

  20. #20
    transcendental analytic kedaman's Avatar
    Join Date
    Mar 2000
    Location
    0x002F2EA8
    Posts
    7,221
    It's 3.4M rared, should i send it in parts?
    Use
    writing software in C++ is like driving rivets into steel beam with a toothpick.
    writing haskell makes your life easier:
    reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
    To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.

  21. #21
    Fanatic Member PsychoMark's Avatar
    Join Date
    Feb 2001
    Location
    Netherlands
    Posts
    540
    I've got an average of 400 kb/sec download, I don't mind the 3.4 MB
    Teaudirenopossum.Musasapientumfixaestinaure.
    (I can't hear you. There's a banana in my ear)

  22. #22
    transcendental analytic kedaman's Avatar
    Join Date
    Mar 2000
    Location
    0x002F2EA8
    Posts
    7,221
    ok just asked in case you wouldn't have space in your mailbox
    (sent)
    Use
    writing software in C++ is like driving rivets into steel beam with a toothpick.
    writing haskell makes your life easier:
    reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
    To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.

  23. #23
    Frenzied Member Jotaf98's Avatar
    Join Date
    Jun 2000
    Location
    I'm not gonna give you my IP address! Ok... Portugal, South-Western Europe, 3rd rock from the sun (our star is easy to find, a 47 Ursae Majoris in the Milky Way :p )
    Posts
    1,457
    DaoK: I know that, but we're talking about pixels here and not meters It will depend a lot on the speed of the game and the size of the motorcycle.
    Code:
    Temp = Me.GetIQ()
    'Error 9: Overflow
    'DON'T PANIC! :eek:

    To learn how to use realistic effects in your games like fire, rain, snow and magic effects, read my article on particles systems here.


    Jotaf's Theories!
    "Cats land on their feet. Toast lands peanut butter side down. A cat with toast strapped to its back will hover above the ground in a state of quantum indecision."

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width