From: | Andrew Crowe |
Date: | 1 Aug 99 at 21:29:05 |
Subject: | [amos-list] Re: 2nd mouse & Floating point |
From: Andrew Crowe <andrewcrowe@enterprise.net>
Hi Everybody,
> Also, I found on Aminet a doc on optimising AMOS
> code. One
> suggestion was that floating point calculations,
> which is supposed
> involved with arrays like: PLAYER#() are _very_
> slow. I've been
> using these arrays heaps in my new tank code! I can
> not afford
> for the game to be slow. What do other people know
> about this?
Ah, floating point no's are around 3 to 4 times slower then integer when compiled, but so what? My James Bond game uses a lot of floating point stuff and that runs fine, if it didn't have to contend with the blitter's speed it'd run at 50fps ;).
If you want the game to remain at the same speed, add an automatic frame skipper, and store stuff like sin/cos's in a table instead of calling them directly.
See ya.
--------------------------- ONElist Sponsor ----------------------------
ONElist now has T-SHIRTS!
For details and to order, go to:
http://www.onelist.com/store/tshirts.html
------------------------------------------------------------------------
Official AMOS WWW: http://members.xoom.com/AmosFactory/front.html