Example #1
0
        public AllMonsterSkills(IList <byte> bytes)
        {
            byte[] defaultBytes = FFTPatch.Context == Context.US_PSP ? PSPResources.MonsterSkillsBin : PSXResources.MonsterSkillsBin;

            MonsterSkills = new MonsterSkill[48];
            for (int i = 0; i < 48; i++)
            {
                MonsterSkills[i] = new MonsterSkill((byte)(i + 0xB0), Names[i], bytes.Sub(5 * i, 5 * i + 4),
                                                    new MonsterSkill((byte)(i + 0xB0), Names[i], defaultBytes.Sub(5 * i, 5 * i + 4)));
            }
        }
Example #2
0
 public MonsterSkill(byte value, string name, IList <byte> bytes, MonsterSkill defaults)
 {
     Default = defaults;
     Name    = name;
     Value   = value;
     bool[] flags = PatcherLib.Utilities.Utilities.BooleansFromByteMSB(bytes[0]);
     Ability1    = AllAbilities.DummyAbilities[flags[0] ? (bytes[1] + 0x100) : bytes[1]];
     Ability2    = AllAbilities.DummyAbilities[flags[1] ? (bytes[2] + 0x100) : bytes[2]];
     Ability3    = AllAbilities.DummyAbilities[flags[2] ? (bytes[3] + 0x100) : bytes[3]];
     Beastmaster = AllAbilities.DummyAbilities[flags[3] ? (bytes[4] + 0x100) : bytes[4]];
 }
Example #3
0
        public AllMonsterSkills(IList <byte> bytes, IList <byte> defaultBytes, Context context)
        {
            defaultBytes = defaultBytes ?? (context == Context.US_PSP ? PSPResources.Binaries.MonsterSkills : PSXResources.Binaries.MonsterSkills);

            MonsterSkills = new MonsterSkill[48];
            for (int i = 0; i < 48; i++)
            {
                MonsterSkills[i] = new MonsterSkill((byte)(i + 0xB0), GetNames(context)[i], bytes.Sub(5 * i, 5 * i + 4),
                                                    new MonsterSkill((byte)(i + 0xB0), GetNames(context)[i], defaultBytes.Sub(5 * i, 5 * i + 4), context), context);
            }
        }
Example #4
0
 public MonsterSkill( byte value, string name, IList<byte> bytes, MonsterSkill defaults )
 {
     Default = defaults;
     Name = name;
     Value = value;
     bool[] flags = PatcherLib.Utilities.Utilities.BooleansFromByteMSB( bytes[0] );
     Ability1 = AllAbilities.DummyAbilities[flags[0] ? ( bytes[1] + 0x100 ) : bytes[1]];
     Ability2 = AllAbilities.DummyAbilities[flags[1] ? ( bytes[2] + 0x100 ) : bytes[2]];
     Ability3 = AllAbilities.DummyAbilities[flags[2] ? ( bytes[3] + 0x100 ) : bytes[3]];
     Beastmaster = AllAbilities.DummyAbilities[flags[3] ? ( bytes[4] + 0x100 ) : bytes[4]];
 }
Example #5
0
        public AllMonsterSkills( IList<byte> bytes )
        {
            byte[] defaultBytes = FFTPatch.Context == Context.US_PSP ? PSPResources.MonsterSkillsBin : PSXResources.MonsterSkillsBin;

            MonsterSkills = new MonsterSkill[48];
            for ( int i = 0; i < 48; i++ )
            {
                MonsterSkills[i] = new MonsterSkill( (byte)( i + 0xB0 ), Names[i], bytes.Sub( 5 * i, 5 * i + 4 ),
                    new MonsterSkill( (byte)( i + 0xB0 ), Names[i], defaultBytes.Sub( 5 * i, 5 * i + 4 ) ) );
            }
        }
 private void copyAll(object sender, EventArgs e)
 {
     copiedMonsterSkill = dataGridView.CurrentRow.DataBoundItem as MonsterSkill;
 }