示例#1
0
        //Set the value of a persona's statistic
        public static void SetPersonaStat(int personaSlot, PersonaStats personaStat, int personaStatValue)
        {
            uint address = GetPersonaStatAddress(personaSlot, personaStat);
            byte value   = Convert.ToByte(personaStatValue);

            API.WriteByte(address, value);
        }
示例#2
0
        //Get the value of a persona's statistic
        public static int GetPersonaStat(int personaSlot, PersonaStats personaStat)
        {
            uint address = GetPersonaStatAddress(personaSlot, personaStat);
            byte value   = API.ReadByte(address);

            return(Convert.ToInt16(value));
        }
示例#3
0
 //Returns the address of a persona's statistic
 public static uint GetPersonaStatAddress(int personaSlot, PersonaStats personaStat)
 {
     return(GetPersonaAddress(personaSlot) + (uint)personaStat);
 }