I was going to get started on a couple of the issues in the tracker (actually, I've done so), but the engine was so full of warnings, I had a hay day. I've created a new issue for the warnings that were my fault. The majority of the warnings were for variable-length arrays and floating point comparisons. I've corrected the floating point comparisons using a new header called <floatcomp.h>. From now on, instead of f1 == f2, include that header and use fequal(f1, f2). There is also an fnequal, fzero, and fnzero, which I trust are self-explanatory.
The only source that makes an exception is var.h in its division-by-zero checking. For that, it assumes only division by exactly zero is useful to report. If you think it's useful to strictly compare against zero elsewhere, let me know. The point of the header is mostly to make it easy to change out comparison behaviors, depending on need.
Other warnings that remain:
Universal_System/spriteinit.cpp: In function ‘void enigma::exe_loadsprs(FILE*)’:
Universal_System/spriteinit.cpp:105: warning: variable ‘collision_data’ set but not used [-Wunused-but-set-variable]
Forthevin: How are you accessing mask data in your precise collision system? It isn't being passed in from the sprite load mechanism.
Graphics_Systems/OpenGL1/glew.c:11678: warning: no previous declaration for ‘glxewContextInit’ [-Wmissing-declarations]|
Graphics_Systems/OpenGL1/glew.c:11960: warning: redundant redeclaration of ‘glxewContextInit’ [-Wredundant-decls]|
Our copy of glew is fucked up. Not touching it.
Universal_System/resource_data.cpp: In function ‘bool enigma_user::script_exists(int)’
Universal_System/resource_data.cpp:82: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
Signed-unsigned comparison in script_exists (
#228)
I'll commit this shortly.
Warnings to other developers:
Forthevin: I had to make a couple of your particle methods static.
Polygone: I tore the shit out of your grid functions.