From: Mircea Kitsune Date: Wed, 4 Apr 2012 19:55:49 +0000 (+0300) Subject: Warn the player when no physics engine exists and physical items are therefore disabled X-Git-Tag: xonotic-v0.7.0~111^2~3 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=3b75b57ac236d38d653da1e21216dd2a876e621f;p=xonotic%2Fxonotic-data.pk3dir.git Warn the player when no physics engine exists and physical items are therefore disabled --- diff --git a/qcsrc/server/mutators/mutator_physical_items.qc b/qcsrc/server/mutators/mutator_physical_items.qc index 9dcab5b2e2..60d5a09038 100644 --- a/qcsrc/server/mutators/mutator_physical_items.qc +++ b/qcsrc/server/mutators/mutator_physical_items.qc @@ -100,8 +100,12 @@ MUTATOR_HOOKFUNCTION(item_spawning) MUTATOR_DEFINITION(mutator_physical_items) { + // check if we have a physics engine if not(autocvar_physics_ode && checkextension("DP_PHYSICS_ODE")) + { + dprint("Warning: Physical items are enabled but no physics engine can be used. Reverting to old items.\n"); return FALSE; + } MUTATOR_HOOK(Item_Spawn, item_spawning, CBC_ORDER_ANY);