Quote:
Originally Posted by trevius
Unfortunately, I think there is a major issue with adding AAs to that table that causes the prereq_skill fields to get messed up. I didn't understand what was going on at first when I added some AAs, but apparently, the prereq_skill number is actually the line number in the table in order. So, if you add one to the table, it throws off all prereqs that are higher than the one at the line you added. This seems like a really horrible way for this table to work. I am going to see if there is a better way to do it. Maybe we can get it changed so that making a change there doesn't mess everything else up. It would certainly make adding non-existing AAs MUCH easier.
So, basically, you probably don't want to update that table yet until the code for prereqs is adjusted/fixed. Unless you know of a good way to have it increment all prereqs higher than that line. Like, if the AA you add is on line number 100, anything over 99 in the prereq field would need to be incremented by 1. I am trying to figure that out to correct an issue with the AAs I added. Until then, it might be best to just have those lines for the new AAs I added removed from the table. Hopefully I can find a good answer soon! Still trying to figure out what to do about it until then...
|
In regards to this problem. I have been thinking..... I believe I understand how it has to work, but correct me if I'm wrong:
The client interprets the AA Index which is why we store that value in the DB. We pull the value for each AA from the DB and send it to the client in the process ZoneDatabase:GetAASkillVars() (aa.cpp).
My question is this- would it not be a lot less of a headache to store the SKILL ID of the AA in the database and determine the so-called "index" at the time of sending it to the client? I.e:
Code:
for (int i = 0; i < MAX_AAs; i++) {
if (targetAA == AAs[i]) return i;
}
something like that??