Quote:
Originally Posted by Kayot
My problem was the alt adv skills. The numbers don't really correlate with anything and are done in a add it as it goes. For instance:
It you boosted strength first then Intel, it would add strength then Intel. If you added Intel then strength, it would add Intel and then strength. For some reason this made reading the date hard and editing it impossible as it wouldn't take the new settings. Not sure why not, thats why you can't edit Alt Adv yet. I'll figure it out.
|
That one kinda threw me off as well. Reading wasn't too bad:
profile.php (from my
PHP-based editor, using a few custom functions):
Code:
91 // AA_Array[240]
92 for ($x = 0; $x <= 239; $x++) {
93 $aa = asc2uint(substr($profileResult,$x*8+428,4));
94 $value = asc2uint(substr($profileResult,$x*8+432,4));
95 if ($aa != 0) {
96 $Profile["aa_array"][($aa-($value-1))] = $value;
97 };
98 unset($aa);
99 unset($value);
100 };
101 unset($aa);
102 unset($value);
So, then you can pull the info by $Profile[aa_array][aa_id] => points.
For writing, it would probably be better to make an array like this:
Code:
$AA_Array => Array
(
[position_num] => Array
(
[aa_id] => #
[aa_points] => #
)
)
So, then you would have all 240 positions to work with, and then you can put it all back in at once. It might also help to put the position_num into the read array, so that way you can refer back, but still be able to locate the AAs easily by a query to the altadv_vars table:
aa.php:
Quote:
SELECT skill_id, name, cost, max_level, spellid, (classes + berserker) AS classes FROM altadv_vars WHERE type='' AND classes & '' ORDER BY skill_id
|
Anyways, just some thoughts
