#include "radarmap.qh"
+#ifdef RADARMAP
+
#include <common/command/_mod.qh>
-#include "radarmap.qh"
#include "../g_world.qh"
-#include "../g_subs.qh"
#include <common/util.qh>
this.maxs_x = (mi_picmax.x - mi_picmin.x) / this.size.x;
this.maxs_y = (mi_picmax.y - mi_picmin.y) / this.size.y;
this.maxs_z = mi_max.z - mi_min.z;
- LOG_INFO("Picture mins/maxs: ", ftos(this.maxs.x), " and ", ftos(this.maxs.y), " should match\n");
+ LOG_INFO("Picture mins/maxs: ", ftos(this.maxs.x), " and ", ftos(this.maxs.y), " should match");
this.netname = strzone(strcat("gfx/", mi_shortname, "_radar.xpm"));
if (!(this.count & 1))
{
{
fclose(this.cnt);
- LOG_INFO(this.netname, " already exists, aborting (you may want to specify --force)\n");
+ LOG_INFO(this.netname, " already exists, aborting (you may want to specify --force)");
RadarMap_Next();
return;
}
this.cnt = fopen(this.netname, FILE_WRITE);
if (this.cnt < 0)
{
- LOG_INFO("Error writing ", this.netname, "\n");
+ LOG_INFO("Error writing ", this.netname);
delete(this);
radarmapper = NULL;
return;
}
- LOG_INFO("Writing to ", this.netname, "...\n");
+ LOG_INFO("Writing to ", this.netname, "...");
fputs(this.cnt, "/* XPM */\n");
fputs(this.cnt, "static char *RadarMap[] = {\n");
fputs(this.cnt, "/* columns rows colors chars-per-pixel */\n");
else
{
fputs(this.cnt, "\",\n");
- LOG_INFO(ftos(this.size.y - this.frame), " lines left\n");
+ LOG_INFO(ftos(this.size.y - this.frame), " lines left");
}
}
else
{
fputs(this.cnt, "\",\n");
- LOG_INFO(ftos(this.size.y - this.frame), " lines left\n");
+ LOG_INFO(ftos(this.size.y - this.frame), " lines left");
}
}
// close the file
fputs(this.cnt, "};\n");
fclose(this.cnt);
- LOG_INFO("Finished. Please edit data/", this.netname, " with an image editing application and place it in the TGA format in the gfx folder.\n");
+ LOG_INFO("Finished. Please edit data/", this.netname, " with an image editing application and place it in the TGA format in the gfx folder.");
RadarMap_Next();
}
}
-float RadarMap_Make(float argc)
+bool RadarMap_Make(float argc)
{
float i;
if (radarmapper) // after doing the arguments, see if we successfully went forward.
{
- LOG_INFO("Radarmap entity spawned.\n");
+ LOG_INFO("Radarmap entity spawned.");
return true; // if so, don't print usage.
}
}
return false;
}
+#endif