home · contact · privacy
Server: Make config file define to which map object type player belongs.
[plomrogue] / src / server / init.c
index 2f6428e99c283e7fe192aa3e7399224bf63fd561..89eea4f8844d1ee64f9ee243a2002ce67b8f1728 100644 (file)
@@ -89,7 +89,18 @@ extern void remake_world(uint32_t seed)
     struct MapObjDef * mod;
     for (mod = world.map_obj_defs; NULL != mod; mod = mod->next)
     {
-        add_map_objects(mod->id, mod->start_n);
+        if (world.player_type == mod->id)
+        {
+            add_map_objects(mod->id, mod->start_n);
+            break;
+        }
+    }
+    for (mod = world.map_obj_defs; NULL != mod; mod = mod->next)
+    {
+        if (world.player_type != mod->id)
+        {
+            add_map_objects(mod->id, mod->start_n);
+        }
     }
     set_cleanup_flag(CLEANUP_MAP_OBJECTS);
     if (world.turn)