Shut down server.
THINGS_HERE [0 to 255] [0 to 255]
-Write line-by-line list of items at y position of first argument, x position of
-second argument into ./server/out file, enclosed by two lines "THINGS_HERE START"
-and "THINGS_HERE END".
+If world exists, write line-by-line list of things at y position of first
+argument, x position of second argument of map into ./server/out file, enclosed
+by two lines "THINGS_HERE START" and "THINGS_HERE END".
Player commands
---------------
char * tok2 = token_from_line(NULL);
if (tok1&&tok2 && !parsetest_int(tok1, '8')&&!parsetest_int(tok2, '8'))
{
+ if (!world.exists)
+ {
+ err_line(1, "Command only works on existing worlds.");
+ return 0;
+ }
send_to_outfile("THINGS_HERE START\n", 1);
struct Thing * t;
for (t = world.things; t; t = t->next)
}
else if (!world.replay)
{
- err_line(1, "Unknown command/argument or bad number of tokens.");
+ err_line(1, "Invalid command/argument or bad number of tokens.");
}
}
free(msg_copy);