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

Automatically set RequiredDisenchantSkill & DisenchantID (item_template) #25

Closed
NotCoffee418 opened this issue Oct 25, 2017 · 1 comment

Comments

@NotCoffee418
Copy link
Owner

NotCoffee418 commented Oct 25, 2017

Add a checkbox on the right (auto check when weapon/armor is chosen, uncheck when not weapon/armor)
if checked set required skill = level * 5
You can slap the DisenchantID (loot) into the program with data from the following query.

SELECT DISTINCT Quality, RequiredLevel, DisenchantID FROM item_template WHERE RequiredLevel > 0 AND DisenchantID > 0 ORDER BY RequiredLevel ASC

@NotCoffee418 NotCoffee418 changed the title Automatically set RequiredDisenchantSkill (item_template) Automatically set RequiredDisenchantSkill & DisenchantID (item_template) Oct 25, 2017
@NotCoffee418
Copy link
Owner Author

NotCoffee418 commented Jul 9, 2020

This is the full query that works with atleast Trinity Latest. Make sure to default to 0 if it fails.
SELECT Quality, RequiredLevel, DisenchantID, RequiredDisenchantSkill FROM item_template WHERE RequiredLevel <= 80 AND Quality = 3 AND DisenchantID > 0 GROUP BY Quality, RequiredLevel ORDER BY RequiredLevel DESC, DisenchantId ASC LIMIT 1

Replace 80 with level and 4 with quality.

NotCoffee418 added a commit that referenced this issue Jul 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant