First create a mob at the wow-v website(http://wow-v.com/create.php?tool=mob) Download the Mangos Batch file and open it up with a text editor.
Remove the fields for minhealth, maxhealth, minmana, maxmana and armor. also remove the values from the bottom. at then end of the fiels add , `unit_class`)
then add the end of the values use 2 for paladin ex: , 2) or 1 for warrior.
Then save this sql file and run it in your database you shouldn't get any errors.
After that, its time to edit the values we removed. Open up a new query tab in your database and paste this: (Make sure to changed values at the top of script)
Code:
-- How to set the health etc. :
-- Set the Mobs stats and entry id under this.
SET
@NPC_ENTRY := 80000, -- Entry id
@NPC_HEALTH := 100000, -- Health
@NPC_MANA := 200, -- Mana
@NPC_ARMOR := 1000; -- Armor
-- DO NOT CHANGE ANYTHING BELOW
SET
@NPC_CLASS := (SELECT `unit_class` FROM creature_template WHERE Entry = @NPC_ENTRY),
@NPC_LEVEL := ROUND(((SELECT `minlevel` FROM creature_template WHERE Entry = @NPC_ENTRY)+(SELECT `maxlevel` FROM creature_template WHERE Entry = @NPC_ENTRY))/2, 0),
@EXP := (SELECT `exp` FROM creature_template WHERE Entry = @NPC_ENTRY);
SET
@GET_HP_COL :=
(SELECT CASE @EXP
WHEN 0 THEN (SELECT basehp0 FROM creature_classlevelstats WHERE `level` = @NPC_LEVEL and `class` = @NPC_CLASS)
WHEN 1 THEN (SELECT basehp1 FROM creature_classlevelstats WHERE `level` = @NPC_LEVEL and `class` = @NPC_CLASS)
WHEN 2 THEN (SELECT basehp2 FROM creature_classlevelstats WHERE `level` = @NPC_LEVEL and `class` = @NPC_CLASS)
END),
-- Getting base mana
@GET_MA_COL := (SELECT basemana FROM creature_classlevelstats WHERE `level` = @NPC_LEVEL and `class` = @NPC_CLASS),
-- Getting base armor
@GET_AR_COL := (SELECT basearmor FROM creature_classlevelstats WHERE `level` = @NPC_LEVEL and `class` = @NPC_CLASS);
UPDATE creature_template SET Health_mod = (@NPC_HEALTH/@GET_HP_COL), Mana_mod = (@NPC_MANA/@GET_MA_COL), Armor_mod = (@NPC_ARMOR/@GET_AR_COL) WHERE Entry = @NPC_ENTRY;
Run this twice once you have changed the values of health, armor, mana.
(Note: run it twice because sometimes it doesnt work the first time)
Credit for code and the general "Idea" goes to Rochet2 and this post http://www.ac-web.org/forums/showthread.php?t=128275