Exemple #1
0
        public void fireMask()
        {
            LineProjectile proj = new LineProjectile(this, position, position + fourWayDirection() * LIGHTRANGE, LIGHTDAMAGE, LIGHTSPEED);

            proj.setTexture(new AnimatedTexture(BASETEX + "glass-hat"));
            proj.modifiers.Add(delegate(Projectile p, GameTime gameTime)
            {
                p.rotation += .003f * gameTime.ElapsedGameTime.Milliseconds;
            });
        }
Exemple #2
0
        public void startVampBuff()
        {
            LineProjectile proj = new LineProjectile(this, position, position + fourWayDirection() * LIGHTRANGE, 0, LIGHTSPEED);

            proj.setTexture(new AnimatedTexture(BASETEX + "buffer-vamp"));
            proj.modifiers.Add(delegate(Projectile p, GameTime gameTime)
            {
                p.rotation += .003f * gameTime.ElapsedGameTime.Milliseconds;
            });
            proj.collisions      = Projectile.CollisionGroup.Characters;
            proj.characterAction = delegate(Character c)
            {
                c.numVampBats++;
                c.numVampBats     = Math.Min(c.numVampBats, 5);
                c.vampBatDuration = 0;
                foreach (Character c2 in Game1.characterManager.liveCharacters)
                {
                    if (c2 != c)
                    {
                        c2.numVampBats = 0;
                    }
                }
            };
        }