You are welcome :)
To fix the gray rectangles of the numbers, you can change line 32 in the Number class to:
tile.drawRect(1,1,42,42);
With (0,0,45,45), the bottom and right edge is outside the image = not visible. In theory, the same applies to line 40. In practice, drawing something in gray on an image which was filled in gray right before, doesn't have a big impact anyway though.
The alternative is to draw those rectangles on the background of the world.
Nope, seems to be as laggy as before....
@MajorCL: Thank you for the suggestion. The sharks are only moving randomly without any purpose to eat something. If I wanted to make that, I would probably adjust the Fish's movement, so they don't avoid the Sharks perfectly. (Technically, the Sharks are able to "catch" Fish when they would team up, but they usually don't.)
But this was never really meant to be something complex to be honest.
If you want to see some population simulation, you can try out my two ecosystem scenarios. Well, I have to update them first, though. They are currently not working...
2019/6/14
Match or Ten
2019/6/14
Match or Ten
2019/6/7
Swarms
2019/6/7
Swarms
2019/6/7
Swarms
2019/6/6
Game of Life
2019/6/6
Particles
2019/6/6
Pac-Man
2019/6/6
trick-the-turtle with highscore