Okay I have a simple question that’s been bugging me for a while. I’m new to java game development and I made a simple game on a PC. All it does is you control a little ship and move around shooting the alien ships.
When I compiled on PC it worked just as expected, but when I ran the jar file on my Mac, everything in the game was happening a lot faster!
One day when I make a full-blown real game, I would like it to be able to run the same on both Mac & PC. So my question is, is there any way to have it run the same? Maybe detect what OS its running on and change the code accordingly? Any help would be appreciated. Thanks
- Mac
https://dl.dropbox.com/u/4826855/img.png
EDIT:
So what I’ve learned from ya’ll:
-
[quote]The mac is giving a better performance then your windows.
[/quote] -
I could either use Delta or Fixed Rate.
-
princec(Cas) makes [quote]hundreds of thousands of dollars! xD
[/quote] -
[quote]Delta - complex (just try doing collision detection properly, go on), mercy of floating point, jerky movement. Absolutely horrible for 2D, in any form.
Fixed rate - easy, can use integers all over the place, glassy smooth movement, perfect for 2D.
[/quote] -
[quote]The basic idea is to link your game to real time, not computer execution speed.
[/quote]
Thanks very much for all your help
P.S. Any Code examples on how to actually do this would come in handy xD
- Mac