X-Git-Url: https://git.jsancho.org/?a=blobdiff_plain;f=Source%2FDevtools%2FConsoleCmds.cpp;h=baa1463893dae10c5dbab20b068de2002900c766;hb=7d2f9d40d94d14a61ecdaaa2c41f964029815bc2;hp=6b30e3f038d6ae08b0d162bb3c73263ab3cd31c6;hpb=5dfd07829a5eecc87d100dd8825a81eafbaa86be;p=lugaru.git diff --git a/Source/Devtools/ConsoleCmds.cpp b/Source/Devtools/ConsoleCmds.cpp index 6b30e3f..baa1463 100644 --- a/Source/Devtools/ConsoleCmds.cpp +++ b/Source/Devtools/ConsoleCmds.cpp @@ -52,7 +52,6 @@ extern float slomofreq; extern int tutoriallevel; extern int hostile; extern int maptype; -extern Objects objects; extern int slomo; extern float slomodelay; extern bool skyboxtexture; @@ -210,11 +209,11 @@ void ch_save(const char *args) fpackf(tfile, "Bi", environment); - fpackf(tfile, "Bi", objects.numobjects); + fpackf(tfile, "Bi", Object::objects.size()); - for (int k = 0; k < objects.numobjects; k++) - fpackf(tfile, "Bi Bf Bf Bf Bf Bf Bf", objects.type[k], objects.yaw[k], objects.pitch[k], - objects.position[k].x, objects.position[k].y, objects.position[k].z, objects.scale[k]); + for (int k = 0; k < Object::objects.size(); k++) + fpackf(tfile, "Bi Bf Bf Bf Bf Bf Bf", Object::objects[k]->type, Object::objects[k]->yaw, Object::objects[k]->pitch, + Object::objects[k]->position.x, Object::objects[k]->position.y, Object::objects[k]->position.z, Object::objects[k]->scale); fpackf(tfile, "Bi", Hotspot::hotspots.size()); for (unsigned i = 0; i < Hotspot::hotspots.size(); i++) { @@ -717,7 +716,7 @@ void ch_skytint(const char *args) SetUpLighting(); terrain.DoShadows(); - objects.DoShadows(); + Object::DoShadows(); } void ch_skylight(const char *args) @@ -727,7 +726,7 @@ void ch_skylight(const char *args) SetUpLighting(); terrain.DoShadows(); - objects.DoShadows(); + Object::DoShadows(); } void ch_skybox(const char *args) @@ -737,5 +736,5 @@ void ch_skybox(const char *args) SetUpLighting(); terrain.DoShadows(); - objects.DoShadows(); + Object::DoShadows(); }