From: Mircea Kitsune Date: Fri, 22 Apr 2011 17:29:03 +0000 (+0300) Subject: Allow func_breakable entities to respawn, using the respawntime key. Tested and works X-Git-Tag: xonotic-v0.5.0~264^2~25 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=79325abafd12f3eb098a5e75aca2bcde5369d577;p=xonotic%2Fxonotic-data.pk3dir.git Allow func_breakable entities to respawn, using the respawntime key. Tested and works --- diff --git a/qcsrc/server/func_breakable.qc b/qcsrc/server/func_breakable.qc index 51a1edf1c..436fde3f4 100644 --- a/qcsrc/server/func_breakable.qc +++ b/qcsrc/server/func_breakable.qc @@ -169,6 +169,12 @@ void func_breakable_destroy() { if(self.cnt) pointparticles(self.cnt, self.absmin * 0.5 + self.absmax * 0.5, '0 0 0', self.count); + if(self.respawntime) + { + self.think = func_breakable_restore; + self.nextthink = time + self.respawntime; + } + oldmsg = self.message; self.message = ""; SUB_UseTargets();