protected override void OnTick()
{
if (cycles == 15)
{
new MovingEffectInfo(new Point3D(corpse.X, corpse.Y, 100), corpse, corpse.Map, 3823, 0, 10,
EffectRender.Lighten)
.MovingImpact(
e =>
{
int amount = Utility.RandomMinMax(200, 400);
if (amount <= 0)
{
return;
}
var g = new Gold(amount);
g.MoveToWorld(e.Target.Location, e.Map);
new EffectInfo(e.Target, e.Map, 14202, 51, 10, 40, EffectRender.Lighten).Send();
Effects.PlaySound(e.Target, e.Map, g.GetDropSound());
});
Stop();
return;
}
if (count == 9)
{
count = 1;
cycles++;
}
corpse.Hue = Utility.RandomBrightHue();
corpse.Direction = (Direction)count;
count++;
}