Saturday, April 24, 2010

Aquarium v1.12

- Bug Fix: Fish getting "stuck"

I'm not sure how often this actually happens, but I have gotten a couple reports of fish "swimming off" then never coming back.  Going through the fish AI (heh) with a fine tooth comb, I did find a couple possibilities and managed to reproduce one of them.  Basically, when fish turn around, they didn't have any deceleration on their turn speed.  It was possible that depending on your framerate, they could overshoot their goal angle, try again, overshoot it again, etc.  I know this could happen for a long time if your framerate was low, though I've only ever seen it when running debug, personally (with a <10 framerate).  I fixed this by having their turn speed decelerate when they got close to their goal angle.

I also found a situation where if their movement delta had a length of 0, a division I was doing could end up NaN (not a number), which would work its way into their origin, which would mean future updates would forever be invalid.  This always resulted in the fish being teleported to the center of the screen though, so shouldn't be the same problem as them swimming off and vanishing.

Either way, I closed up a couple of holes here, we'll see if I get any more "my fish swam off and never came back" reports.


  1. Very nice wall paper. A feature where the sun and sky color changed based on time of day would be a great addition (maybe put it in the pay version?)

  2. I'm still seeing fish disappear with version 1.3.

    Usually after a call or when I am in the sms app. Have to restart the screen saver to get them back.

  3. Congratulations on the best background

    Now what we need is some crabs/lobsters crawling on the bottom

  4. I've downloaded fish wallpaper but can't find it on my Galaxy Tab. Any suggestions?

  5. Great wallpaper. Just got it running on my galaxy tab 8.9, btw what is the use mipmaps option? And also, i cant seem to feed the fishes when i double tap. What gives?