public void SetFuse(float timeToExplode) { FuseTimer t = HUDCameraScript.Instance.mobTimer; t.IsActive = true; t.Monitor = this; countdownTimer = timeToExplode; }
public override void Delete() { //stop the fuse first, before beginning the delete process! if (_FuseTimer != null) { _FuseTimer.Stop(); _FuseTimer = null; } base.Delete(); }
public void Explode( BlastDirection inhibitdirection ) { if( _FuseTimer != null ) { _FuseTimer.Stop(); _FuseTimer = null; } if( BombBag != null ) { BombBag.Bombs.Remove( this ); } //sound effect of explosion Effects.PlaySound( Location, Map, Utility.RandomList( 0x11B, 0x305, 0x306, 0x307, 0x11C, 0x308, 0x11D, 0x309, 0x4CF, 0x11E, 0x207 ) ); //bomb explosion graphics effect: 0x36CB Effects.SendLocationEffect( new Point3D( X + 1, Y + 1, Z ), Map, 0x36CB, 10 ); //set off fire blowout foreach( int blastdirection in Enum.GetValues( typeof( BlastDirection ) ) ) { BlastDirection curdirection = (BlastDirection)blastdirection; if( curdirection != BlastDirection.None && curdirection != inhibitdirection ) { BombBlast blast = new BombBlast( Location, Map, curdirection, BombBag, Planter, _Strength - 1, _BaddaBoom != null ); } } //check for damagable at spot if( BombBag != null && !BombBag.Deleted ) { BombBag.ControlItem.CheckForMobileVictims( Location, Map, BombBag ); } Delete(); }
public void Explode(BlastDirection inhibitdirection) { if (_FuseTimer != null) { _FuseTimer.Stop(); _FuseTimer = null; } if (BombBag != null) { BombBag.Bombs.Remove(this); } //sound effect of explosion Effects.PlaySound(Location, Map, Utility.RandomList(0x11B, 0x305, 0x306, 0x307, 0x11C, 0x308, 0x11D, 0x309, 0x4CF, 0x11E, 0x207)); //bomb explosion graphics effect: 0x36CB Effects.SendLocationEffect(new Point3D(X + 1, Y + 1, Z), Map, 0x36CB, 10); //set off fire blowout foreach (int blastdirection in Enum.GetValues(typeof(BlastDirection))) { var curdirection = (BlastDirection)blastdirection; if (curdirection != BlastDirection.None && curdirection != inhibitdirection) { var blast = new BombBlast(Location, Map, curdirection, BombBag, Planter, _Strength - 1, _BaddaBoom != null); } } //check for damagable at spot if (BombBag != null && !BombBag.Deleted) { BombBag.ControlItem.CheckForMobileVictims(Location, Map, BombBag); } Delete(); }
//start the timer for the explosion public void StartFuse() { _FuseTimer = new FuseTimer( this ); _FuseTimer.Start(); }
public override void Delete() { //stop the fuse first, before beginning the delete process! if( _FuseTimer != null ) { _FuseTimer.Stop(); _FuseTimer = null; } base.Delete(); }
//start the timer for the explosion public void StartFuse() { _FuseTimer = new FuseTimer(this); _FuseTimer.Start(); }
void Start() { mobCountdownTimer = GetComponentInChildren <FuseTimer>(); }
void Start() { mobCountdownTimer = GetComponentInChildren<FuseTimer>(); }