Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pre-WoD 4.3.4.15595 SpellPower and TalentTab field mistakes #52

Closed
Ovahlord opened this issue Jan 26, 2020 · 8 comments
Closed

Pre-WoD 4.3.4.15595 SpellPower and TalentTab field mistakes #52

Ovahlord opened this issue Jan 26, 2020 · 8 comments

Comments

@Ovahlord
Copy link

Ovahlord commented Jan 26, 2020

So I've been doing a full portover of the 4.3.4 dbc field names on a previous struct and during renaming everything by hand I stumbled accross some errors that might be worth looking into:

TalentTab.dbc
This one is pretty simple. In the 434 def the 4th field is currently named as RaceMask while it's actually ClassMask. Simply checked the field values and tried to make any sense from it when it comes to talent restriction checks. In fact a simple check would be a shaman talent tab with value 64 which simply translates into 1<<(CLASS_SHAMAN-1). The class value for that comes from ChrClasses.dbc

SpellPower.dbc
This is where the fun begins. Field 8 is named as PowerCostPct but after looking into the dbc files and checking several entries of multiple spells with percentage mana costs, the tests have shown that field 4 (PowerType) is actually PowerCostPct. As for the current field I have no idea what it actually stands for. In many cases the value in field 8 is identical with field 4 but there are also many cases where field 8 is set to 0 while field 4 has value.

A example for that problem would be any demon summoning spell which is suposed to use up 100% of the base mana of a warlock. If you would trust the field 8 you would end up with 0% while the field 4 is having the correct field value. See image below

unknown

These test is also confirmed by the ingame mana cost displays so yeah.

@bloerwald
Copy link
Collaborator

I'm sorry, but SpellPower does not have a definition for 4.3.4.15595 and neither does https://wowdev.wiki/DB/SpellPower. The same goes for TalentTab, which has no definition on here or at https://wowdev.wiki/DB/TalentTab.

I'm not sure what bug you're reporting here. Would you like to share those files you're reporting on, as those appear not to be files from this repository?

@funjoker
Copy link
Contributor

@bloerwald #27

@Ovahlord
Copy link
Author

@bloerwald you might consider reading the title again. There is a branch specifically for client builds prior to WoD:
https://github.com/wowdev/WoWDBDefs/tree/pre-wod

There you find all 4.x definitions and there's where I've dug up my named concerns

@bloerwald
Copy link
Collaborator

I see, I forgot about that branch. We may want to move this discussion over to the merge request for it.

On TalentTab I fully agree.

On SpellPower it appears to be a result of trying to match the only float value in there. Your observation is right, the powertype column sure isn’t that. I guess we have a column type change across versions?!

@Marlamin
Copy link
Collaborator

Keep in mind said branch isn't quite up to date or supported/battle-tested like master is.

@Ovahlord
Copy link
Author

Ovahlord commented Jan 27, 2020

@bloerwald I just got a helping hand and received a reversed spell power cost calculation function from the client and I have the answer now. Field 4 and 8 are both PowerCostPct. Field 4 is the fallback field if 8 is 0.f. I guess that's another of these functions that Blizz had implemented halfway for future expansions. So yeah. I guess field 8 is PowerCostPct and field 4 is PowerCostPct2 or other way arround.

@Marlamin I am aware of that. So I think it's a great opportunity to change that now that I had the pleasure to dig through every single field. And as far as I am aware, most of the namings are actually very accurate.

@Marlamin
Copy link
Collaborator

Hmk, will see if I can properly diff these and merge in any changes manually because it might have diverged a bit too far from master to be easily mergeable the usual way.

barncastle added a commit that referenced this issue Aug 19, 2020
@barncastle
Copy link
Collaborator

Thank you for looking into this and letting us know.

RE: SpellPower; you are right, they moved from just a numeric field PowerCost (x/100) to using PowerCostPct as a fallback if PowerCost was 0, to just using PowerCostPct - full change history is here if anyone is interested.

This has all been merged into master now along with the rest of that branch.
Any PRs and issues are more than welcome for any other changes/fixes!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants