]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/t_items.qc
Finally, the mine behavior. The projectile will now stick to the first surface it...
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / t_items.qc
index c291e79a009f715fb67e0decc66d0cde175fb809..c2b2deb8713cc919e32c450f30b3ebfdb009dc62 100644 (file)
@@ -233,8 +233,13 @@ void Item_ScheduleRespawnIn(entity e, float t)
 
 void Item_ScheduleRespawn(entity e)
 {
-       Item_Show(e, 0);
-       Item_ScheduleRespawnIn(e, ITEM_RESPAWNTIME(e));
+       if(e.respawntime > 0)
+       {
+               Item_Show(e, 0);
+               Item_ScheduleRespawnIn(e, ITEM_RESPAWNTIME(e));
+       }
+       else // if respawntime is -1, this item does not respawn
+               Item_Show(e, -1);
 }
 
 void Item_ScheduleInitialRespawn(entity e)