]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Add engine extension check: fullspawndata
authorbones_was_here <bones_was_here@xonotic.au>
Thu, 21 Mar 2024 07:10:40 +0000 (17:10 +1000)
committerbones_was_here <bones_was_here@xonotic.au>
Wed, 17 Apr 2024 14:49:40 +0000 (00:49 +1000)
This one isn't supported by checkextension().

qcsrc/common/checkextension.qc
qcsrc/server/main.qc

index 3e1a69f005810f70cd15504b700e6d2141a2df62..9e53159578ef9f1c2fcf042732ed10cc7422e07c 100644 (file)
@@ -45,6 +45,9 @@ void CheckEngineExtensions(void)
                // DP_QC_NUDGEOUTOFSOLID fixes many cases WarpZoneLib_MoveOutOfSolid() can't, usually in less CPU time
                nudgeoutofsolid = WarpZoneLib_MoveOutOfSolid;
        }
+
+       if (!world.fullspawndata)
+               LOG_WARN("Engine lacks entity fullspawndata, on Quake 3 maps some entities will malfunction.");
 #endif
 
 #ifdef GAMEQC
index a6a771795f29bb76ddda023bfe9f640285f5fc82..72e3dac3dd039a9131d7d7c76dd100f5a226988c 100644 (file)
@@ -436,6 +436,7 @@ void SV_OnEntityPreSpawnFunction(entity this)
  * Avoids the need to declare fields just to read them once :)
  *
  * Returns the last instance of the field to match DarkPlaces behaviour.
+ *
  * Path support: converts \ to / and tests the file if a third (bool, true) arg is passed.
  * Returns string_null if the entity does not have the field, or the file is not in the VFS.
  *
@@ -445,11 +446,8 @@ string GetField_fullspawndata(entity e, string f, ...)
 {
        string v = string_null;
 
-       if (!e.fullspawndata)
-       {
-               //LOG_WARNF("^1EDICT %s (classname %s) has no fullspawndata, engine lacks support?", ftos(num_for_edict(e)), e.classname);
+       if (!e.fullspawndata) // Engine lacks support, warning spam in CheckEngineExtensions()
                return v;
-       }
 
        if (strstrofs(e.fullspawndata, "//", 0) >= 0)
        {