forked from Mirrors/openclonk
Make arrows burn (#1983)
parent
4dd97d266e
commit
f39ce4f25c
|
@ -10,6 +10,7 @@
|
|||
*/
|
||||
|
||||
#include Library_Stackable
|
||||
#include Library_Flammable
|
||||
|
||||
|
||||
protected func Construction()
|
||||
|
@ -167,3 +168,5 @@ local Name = "$Name$";
|
|||
local Description = "$Description$";
|
||||
local Collectible = 1;
|
||||
local Components = {Wood = 3};
|
||||
local BlastIncinerate = 5;
|
||||
local ContactIncinerate = 1;
|
||||
|
|
|
@ -35,6 +35,14 @@ public func HasExplosionOnImpact() { return !!GetEffect("InFlight", this); }
|
|||
|
||||
public func IsExplosive() { return true; }
|
||||
|
||||
private func OnBurnDown()
|
||||
{
|
||||
// Got burned? Explode based on stack size.
|
||||
Explode(10 + Random(3) + 23 * GetStackCount() / MaxStackCount());
|
||||
_inherited(...);
|
||||
return true; // Do not create burned object
|
||||
}
|
||||
|
||||
|
||||
/*-- Properties --*/
|
||||
|
||||
|
|
Loading…
Reference in New Issue