public static BossAttack <BurningKnight> GetNext(BossPatternSet <BurningKnight> p)
        {
            if (Rnd.Chance(100f / (PatternRegistry.Count + 1)))
            {
                return((BossAttack <BurningKnight>)Activator.CreateInstance(Attacks[Rnd.Int(Attacks.Length)]));
            }

            return(p.GetNext());
        }
Ejemplo n.º 2
0
        public override void SelectAttack()
        {
            if (set == null)
            {
                set = BurningKnightAttackRegistry.PatternSetRegistry.Generate(Run.Level.Biome.Id);
            }

            base.SelectAttack();
            GetComponent <StateComponent>().PushState(BurningKnightAttackRegistry.GetNext(set));
        }