Fix water and lava animation overlay

Fixes: bug #512
Make member function const
Remove unused function prototype
Add drawLine2D() overload taking vectors
Fix signed/unsigned integer comparison
Add a debug view to identify textures