X-Git-Url: https://plomlompom.com/repos/condition_descriptions?a=blobdiff_plain;f=roguelike-server;h=7f5f9c79c467d41ecf691f528d59f5de158832bf;hb=59505b103d3521be1f72b4ee65fe74efaa092ad9;hp=e723339a46bdad1e0c121cdb1b41e69537c9f77d;hpb=6e92d2bab27353c21390abcf07eeee3d51fc64da;p=plomrogue diff --git a/roguelike-server b/roguelike-server index e723339..7f5f9c7 100755 --- a/roguelike-server +++ b/roguelike-server @@ -109,7 +109,8 @@ def obey(command, prefix, replay=False, do_record=False): is called (and io_db["record_chunk"] written) if 15 seconds have passed since the last time it was called. The prefix string is inserted into the server's input message between its beginning 'input ' and ':'. All activity - is preceded by a server_test() call. + is preceded by a server_test() call. Commands that start with a lowercase + letter are ignored when world_db["WORLD_ACTIVE"] is False/0. """ server_test() if io_db["verbose"]: @@ -123,6 +124,8 @@ def obey(command, prefix, replay=False, do_record=False): and len(tokens) == commands_db[tokens[0]][0] + 1: if commands_db[tokens[0]][1]: commands_db[tokens[0]][2](*tokens[1:]) + elif tokens[0][0].islower() and not world_db["WORLD_ACTIVE"]: + print("Ignoring lowercase-starting commands when world inactive.") elif replay: print("Due to replay mode, reading command as 'go on in record'.") line = io_db["file_record"].readline() @@ -1313,6 +1316,8 @@ def command_worldactive(worldactive_string): if 0 == id: update_map_memory(world_db["Things"][id], False) world_db["WORLD_ACTIVE"] = 1 + else: + print("Ignoring: Not all conditions for world activation met.") def test_for_id_maker(object, category):