private void checker_BitMaskAdded(object sender, SpellFamilyChecker.BitMaskChangedArgs e) { _maskA |= e.BitMask[0]; _maskB |= e.BitMask[1]; _maskC |= e.BitMask[2]; UpdateMask(); }
private void InitSpellList() { for (int i = 0; i != 32; ++i) { SpellFamilyChecker checker = new SpellFamilyChecker(_spell, i, (_maskA & (1 << i)) != 0); checker.BitMaskAdded += checker_BitMaskAdded; checker.BitMaskRemoved += checker_BitMaskRemoved; maskedSpells.Children.Add(checker); } for (int i = 0; i != 32; ++i) { SpellFamilyChecker checker = new SpellFamilyChecker(_spell, i + 32, (_maskB & (1 << i)) != 0); checker.BitMaskAdded += checker_BitMaskAdded; checker.BitMaskRemoved += checker_BitMaskRemoved; maskedSpells.Children.Add(checker); } for (int i = 0; i != 32; ++i) { SpellFamilyChecker checker = new SpellFamilyChecker(_spell, i + 64, (_maskC & (1 << i)) != 0); checker.BitMaskAdded += checker_BitMaskAdded; checker.BitMaskRemoved += checker_BitMaskRemoved; maskedSpells.Children.Add(checker); } }