SHOW:
|
|
- or go back to the newest paste.
| 1 | local item_id = 90001 | |
| 2 | ||
| 3 | - | function Item_Trigger(item, pPlayer) |
| 3 | + | local T = {}
|
| 4 | - | Item_menu(item, pPlayer) |
| 4 | + | T.Warrior = {47436, 47450, 11578, 47465, 47502, 34428, 1715, 2687, 71, 7386, 355, 72, 47437, 57823, 694, 2565, 676, 47520, 20230, 12678, 47471, 1161, 871, 2458, 20252, 47475, 18499, 1680, 6552, 47488, 1719, 23920, 47440, 3411, 64382, 55694, 57755, 674, 750, 5246}
|
| 5 | T.Paladin = {750, 48942, 48782, 48932, 20271, 498, 853, 1152, 10278, 48788, 53408, 48950, 48936, 31789, 62124, 54043, 25780, 1044, 20217, 48819, 48801, 48785, 5502, 20164, 10326, 1038, 53407, 48943, 20165, 48945, 642, 48947, 20166, 4987, 48806, 6940, 48817, 48934, 48938, 25898, 25899, 32223, 31884, 54428, 61411, 53601, 33388, 33391, 34769, 34767}
| |
| 6 | T.Hunter = {8737, 1494, 13163, 48996, 49001, 49045, 53338, 5116, 27044, 883, 2641, 6991, 982, 1515, 19883, 20736, 48990, 2974, 6197, 1002, 14327, 5118, 49056, 53339, 49048, 19884, 34074, 781, 14311, 1462, 19885, 19880, 13809, 13161, 5384, 1543, 19878, 49067, 3034, 13159, 19882, 58434, 49071, 49052, 19879, 19263, 19801, 34026, 34600, 34477, 61006, 61847, 53271, 60192, 62757}
| |
| 7 | - | function Item_menu(event, item, pPlayer) |
| 7 | + | T.Rogue = {674, 48668, 48638, 1784, 48657, 921, 1776, 26669, 51724, 6774, 11305, 1766, 48676, 48659, 1804, 8647, 48691, 51722, 48672, 1725, 26889, 2836, 1833, 1842, 8643, 2094, 1860, 57993, 48674, 31224, 5938, 57934, 51723}
|
| 8 | T.Priest = {2053, 48161, 48123, 48125, 48066, 586, 48068, 48127, 48171, 48168, 10890, 6064, 988, 48300, 6346, 48071, 48135, 48078, 453, 9484, 10909, 8129, 48073, 605, 48072, 48169, 552, 1706, 48063, 48162, 48170, 48074, 48158, 48120, 34433, 48113, 32375, 64843, 64901, 53023}
| |
| 9 | - | --if (pPlayer:IsInCombat() == true) then |
| 9 | + | T["Death Knight"] = {50842, 49941, 49930, 47476, 45529, 3714, 56222, 48743, 48263, 49909, 66188, 47528, 45524, 48792, 57623, 56815, 47568, 49895, 50977, 49576, 49921, 46584, 49938, 48707, 48265, 61999, 42650, 53428, 53331, 54447, 53342, 54446, 53323, 53344, 70164, 62158, 33391, 48778, 51425, 49924, 49924}
|
| 10 | - | --pPlayer:SendAreaTriggerMessage("You are in combat!")
|
| 10 | + | T.Shaman = {8737, 49273, 49238, 10399, 49231, 58753, 2484, 49281, 58582, 49233, 58790, 58704, 58643, 49277, 61657, 8012, 526, 2645, 57994, 8143, 49236, 58796, 58757, 49276, 57960, 131, 58745, 6196, 58734, 58774, 58739, 58656, 546, 556, 66842, 51994, 8177, 58749, 20608, 36936, 58804, 49271, 8512, 6495, 8170, 66843, 55459, 66844, 3738, 2894, 60043, 51514}
|
| 11 | - | --else |
| 11 | + | T.Mage = {42995, 42833, 27090, 42842, 33717, 42873, 42846, 12826, 28271, 61780, 61721, 28272, 61305, 42917, 43015, 130, 42921, 42926, 43017, 475, 1953, 42940, 12051, 43010, 43020, 43012, 42859, 2139, 42931, 42985, 43008, 45438, 43024, 43002, 43046, 42897, 42914, 66, 58659, 30449, 42956, 47610, 61316, 61024, 55342, 53142}
|
| 12 | - | --item:GossipCreateMenu(100, pPlayer, 0) |
| 12 | + | T.Warlock = {696, 47811, 47809, 688, 47813, 50511, 57946, 47864, 6215, 47878, 47855, 697, 47856, 47857, 5697, 47884, 47815, 47889, 47820, 698, 712, 126, 5138, 5500, 11719, 132, 60220, 18647, 61191, 47823, 691, 47865, 47891, 47888, 17928, 47860, 47825, 1122, 47867, 18540, 47893, 47838, 29858, 58887, 47836, 61290, 48018, 48020, 33388, 33391, 23161}
|
| 13 | - | item:GossipMenuAddItem(0, "Teach Me My Class Spells", 895, 0) |
| 13 | + | T.Druid = {48378, 48469, 48461, 48463, 48441, 53307, 53308, 5487, 48560, 6795, 48480, 53312, 18960, 5229, 48443, 50763, 8983, 8946, 1066, 48562, 783, 770, 16857, 18658, 768, 1082, 16979, 49376, 5215, 48477, 49800, 48465, 48572, 26995, 48574, 2782, 50213, 2893, 33357, 5209, 48575, 48447, 48577, 48579, 5225, 22842, 49803, 9634, 20719, 48467, 29166, 62600, 22812, 48470, 48564, 48566, 33891, 33943, 49802, 48451, 48568, 33786, 40120, 62078, 52610, 50464, 48570}
|
| 14 | - | item:GossipMenuAddItem(0, "Teach Me My Riding Skills", 896, 0) |
| 14 | + | local skills = {
|
| 15 | - | item:GossipMenuAddItem(0, "Teach Me My Weapon Skills", 897, 0) |
| 15 | + | 201, -- One-Handed Swords |
| 16 | - | item:GossipMenuAddItem(0, "Advance All My Skills", 898, 0) |
| 16 | + | 202, -- Two-Handed Swords |
| 17 | - | item:GossipMenuAddItem(0, "Reset My Talents", 899, 0) |
| 17 | + | 196, -- One-Handed Axes |
| 18 | - | item:GossipMenuAddItem(0, "Thank You.", 999, 0) |
| 18 | + | 197, -- Two-Handed Axes |
| 19 | - | item:GossipSendMenu(1, pPlayer) |
| 19 | + | 227, -- Staves |
| 20 | - | --end |
| 20 | + | 200, -- Polearms |
| 21 | 266, -- Guns | |
| 22 | 264, -- Bows | |
| 23 | 5011, -- Crossbows | |
| 24 | - | function Item_Select(item, event, pPlayer, id, intid, code) |
| 24 | + | 3018, -- Shoot (Bow, Crossbow or Gun, |
| 25 | 198, -- One-Handed Maces | |
| 26 | - | --[ Class Spells Submenu Begin ]-- |
| 26 | + | 199, -- Two-Handed Maces |
| 27 | - | if (intid == 895) then |
| 27 | + | 1180, -- Daggers |
| 28 | - | --item:GossipCreateMenu(101, pPlayer, 0) |
| 28 | + | 2567, -- Thrown |
| 29 | - | if (pPlayer:GetpPlayerClass() == "Warrior") then |
| 29 | + | 2764, -- Throw (With Thrown, |
| 30 | - | item:GossipMenuAddItem(0, "Teach me all my spells!", 1, 0) |
| 30 | + | 5009, -- Wands |
| 31 | - | elseif (pPlayer:GetpPlayerClass() == "Paladin") then |
| 31 | + | 5019, -- Shoot (Wands) |
| 32 | - | item:GossipMenuAddItem(0, "Teach me all my spells!", 2, 0) |
| 32 | + | } |
| 33 | - | elseif (pPlayer:GetpPlayerClass() == "Hunter") then |
| 33 | + | |
| 34 | - | item:GossipMenuAddItem(0, "Teach me all my spells!", 3, 0) |
| 34 | + | local function ItemHello(event, player, item) |
| 35 | - | elseif (pPlayer:GetpPlayerClass() == "Rogue") then |
| 35 | + | player:GossipMenuAddItem(0, "Teach Me My Class Spells", 0, 0) |
| 36 | - | item:GossipMenuAddItem(0, "Teach me all my spells!", 4, 0) |
| 36 | + | player:GossipMenuAddItem(0, "Teach Me My Riding Skills", 0, 1) |
| 37 | - | elseif (pPlayer:GetpPlayerClass() == "Priest") then |
| 37 | + | player:GossipMenuAddItem(0, "Teach Me My Weapon Skills", 0, 2) |
| 38 | - | item:GossipMenuAddItem(0, "Teach me all my spells!", 5, 0) |
| 38 | + | player:GossipMenuAddItem(0, "Advance All My Skills", 0, 3) |
| 39 | - | elseif (pPlayer:GetpPlayerClass() == "Death Knight") then |
| 39 | + | player:GossipMenuAddItem(0, "Reset My Talents", 0, 4) |
| 40 | - | item:GossipMenuAddItem(0, "Teach me all my spells!", 6, 0) |
| 40 | + | player:GossipSendMenu(1, item) |
| 41 | - | elseif (pPlayer:GetpPlayerClass() == "Shaman") then |
| 41 | + | |
| 42 | - | item:GossipMenuAddItem(0, "Teach me all my spells!", 7, 0) |
| 42 | + | |
| 43 | - | elseif (pPlayer:GetpPlayerClass() == "Mage") then |
| 43 | + | local function ItemSelect(event, player, item, id, intid, code) |
| 44 | - | item:GossipMenuAddItem(0, "Teach me all my spells!", 8, 0) |
| 44 | + | if (intid == 0) then |
| 45 | - | elseif (pPlayer:GetpPlayerClass() == "Warlock") then |
| 45 | + | local class = player:GetClassAsString() |
| 46 | - | item:GossipMenuAddItem(0, "Teach me all my spells!", 9, 0) |
| 46 | + | if(not T[class]) then return end |
| 47 | - | elseif (pPlayer:GetpPlayerClass() == "Druid") then |
| 47 | + | for k, spell in ipairs(T[class]) do |
| 48 | - | item:GossipMenuAddItem(0, "Teach me all my spells!", 10, 0) |
| 48 | + | player:LearnSpell(spell) |
| 49 | - | end |
| 49 | + | end |
| 50 | - | item:GossipMenuAddItem(0, "Main Menu", 998, 0) |
| 50 | + | |
| 51 | - | item:GossipSendMenu(1, pPlayer) |
| 51 | + | if (class == "Warrior") then -- Warrior |
| 52 | if (player:HasSpell(12294)) then | |
| 53 | player:LearnSpell(47486) | |
| 54 | end | |
| 55 | - | --[ Class Spells Begin ]-- |
| 55 | + | if (player:HasSpell(20243)) then |
| 56 | - | if (intid == 1) then -- Warrior |
| 56 | + | player:LearnSpell(47498) |
| 57 | - | pPlayer:LearnSpell(47436) |
| 57 | + | end |
| 58 | - | pPlayer:LearnSpell(47450) |
| 58 | + | elseif (class == "Paladin") then -- Paladin |
| 59 | - | pPlayer:LearnSpell(11578) |
| 59 | + | if (player:GetTeam() < 1) then |
| 60 | - | pPlayer:LearnSpell(47465) |
| 60 | + | player:LearnSpell(31801) |
| 61 | - | pPlayer:LearnSpell(47502) |
| 61 | + | else |
| 62 | - | pPlayer:LearnSpell(34428) |
| 62 | + | player:LearnSpell(53736) |
| 63 | - | pPlayer:LearnSpell(1715) |
| 63 | + | end |
| 64 | - | pPlayer:LearnSpell(2687) |
| 64 | + | if (player:HasSpell(20925)) then |
| 65 | - | pPlayer:LearnSpell(71) |
| 65 | + | player:LearnSpell(48952) |
| 66 | - | pPlayer:LearnSpell(7386) |
| 66 | + | end |
| 67 | - | pPlayer:LearnSpell(355) |
| 67 | + | if (player:HasSpell(31935)) then |
| 68 | - | pPlayer:LearnSpell(72) |
| 68 | + | player:LearnSpell(48827) |
| 69 | - | pPlayer:LearnSpell(47437) |
| 69 | + | end |
| 70 | - | pPlayer:LearnSpell(57823) |
| 70 | + | if (player:HasSpell(20473)) then |
| 71 | - | pPlayer:LearnSpell(694) |
| 71 | + | player:LearnSpell(48825) |
| 72 | - | pPlayer:LearnSpell(2565) |
| 72 | + | end |
| 73 | - | pPlayer:LearnSpell(676) |
| 73 | + | elseif (class == "Hunter") then -- Hunter |
| 74 | - | pPlayer:LearnSpell(47520) |
| 74 | + | if (player:HasSpell(19386)) then |
| 75 | - | pPlayer:LearnSpell(20230) |
| 75 | + | player:LearnSpell(49012) |
| 76 | - | pPlayer:LearnSpell(12678) |
| 76 | + | end |
| 77 | - | pPlayer:LearnSpell(47471) |
| 77 | + | if (player:HasSpell(53301)) then |
| 78 | - | pPlayer:LearnSpell(1161) |
| 78 | + | player:LearnSpell(60053) |
| 79 | - | pPlayer:LearnSpell(871) |
| 79 | + | end |
| 80 | - | pPlayer:LearnSpell(2458) |
| 80 | + | if (player:HasSpell(19306)) then |
| 81 | - | pPlayer:LearnSpell(20252) |
| 81 | + | player:LearnSpell(48999) |
| 82 | - | pPlayer:LearnSpell(47475) |
| 82 | + | end |
| 83 | - | pPlayer:LearnSpell(18499) |
| 83 | + | if (player:HasSpell(19434)) then |
| 84 | - | pPlayer:LearnSpell(1680) |
| 84 | + | player:LearnSpell(49050) |
| 85 | - | pPlayer:LearnSpell(6552) |
| 85 | + | end |
| 86 | - | pPlayer:LearnSpell(47488) |
| 86 | + | elseif (class == "Rogue") then -- Rogue |
| 87 | - | pPlayer:LearnSpell(1719) |
| 87 | + | if (player:HasSpell(16511)) then |
| 88 | - | pPlayer:LearnSpell(23920) |
| 88 | + | player:LearnSpell(48660) |
| 89 | - | pPlayer:LearnSpell(47440) |
| 89 | + | end |
| 90 | - | pPlayer:LearnSpell(3411) |
| 90 | + | if (player:HasSpell(1329)) then |
| 91 | - | pPlayer:LearnSpell(64382) |
| 91 | + | player:LearnSpell(48666) |
| 92 | - | pPlayer:LearnSpell(55694) |
| 92 | + | end |
| 93 | - | pPlayer:LearnSpell(57755) |
| 93 | + | elseif (class == "Priest") then -- Priest |
| 94 | - | pPlayer:LearnSpell(674) |
| 94 | + | if (player:HasSpell(34914)) then |
| 95 | - | pPlayer:LearnSpell(750) |
| 95 | + | player:LearnSpell(48160) |
| 96 | - | pPlayer:LearnSpell(5246) |
| 96 | + | end |
| 97 | - | |
| 97 | + | if (player:HasSpell(47540)) then |
| 98 | - | if (pPlayer:HasSpell(12294)) then |
| 98 | + | player:LearnSpell(53007) |
| 99 | - | pPlayer:LearnSpell(47486) |
| 99 | + | end |
| 100 | - | end |
| 100 | + | if (player:HasSpell(724)) then |
| 101 | - | |
| 101 | + | player:LearnSpell(48087) |
| 102 | - | if (pPlayer:HasSpell(20243)) then |
| 102 | + | end |
| 103 | - | pPlayer:LearnSpell(47498) |
| 103 | + | if (player:HasSpell(19236)) then |
| 104 | - | end |
| 104 | + | player:LearnSpell(48173) |
| 105 | - | |
| 105 | + | end |
| 106 | - | pPlayer:GossipComplete() |
| 106 | + | if (player:HasSpell(34861)) then |
| 107 | player:LearnSpell(48089) | |
| 108 | end | |
| 109 | - | if (intid == 2) then -- Paladin |
| 109 | + | if (player:HasSpell(15407)) then |
| 110 | - | pPlayer:LearnSpell(750) |
| 110 | + | player:LearnSpell(48156) |
| 111 | - | pPlayer:LearnSpell(48942) |
| 111 | + | end |
| 112 | - | pPlayer:LearnSpell(48782) |
| 112 | + | elseif (class == "Death Knight") then -- Death Knight |
| 113 | - | pPlayer:LearnSpell(48932) |
| 113 | + | if (player:HasSpell(55050)) then |
| 114 | - | pPlayer:LearnSpell(20271) |
| 114 | + | player:LearnSpell(55262) |
| 115 | - | pPlayer:LearnSpell(498) |
| 115 | + | end |
| 116 | - | pPlayer:LearnSpell(853) |
| 116 | + | if (player:HasSpell(49143)) then |
| 117 | - | pPlayer:LearnSpell(1152) |
| 117 | + | player:LearnSpell(55268) |
| 118 | - | pPlayer:LearnSpell(10278) |
| 118 | + | end |
| 119 | - | pPlayer:LearnSpell(48788) |
| 119 | + | if (player:HasSpell(49184)) then |
| 120 | - | pPlayer:LearnSpell(53408) |
| 120 | + | player:LearnSpell(51411) |
| 121 | - | pPlayer:LearnSpell(48950) |
| 121 | + | end |
| 122 | - | pPlayer:LearnSpell(48936) |
| 122 | + | if (player:HasSpell(55090)) then |
| 123 | - | pPlayer:LearnSpell(31789) |
| 123 | + | player:LearnSpell(55271) |
| 124 | - | pPlayer:LearnSpell(62124) |
| 124 | + | end |
| 125 | - | pPlayer:LearnSpell(54043) |
| 125 | + | if (player:HasSpell(49158)) then |
| 126 | - | pPlayer:LearnSpell(25780) |
| 126 | + | player:LearnSpell(51328) |
| 127 | - | pPlayer:LearnSpell(1044) |
| 127 | + | end |
| 128 | - | pPlayer:LearnSpell(20217) |
| 128 | + | elseif (class == "Shaman") then -- Shaman |
| 129 | - | pPlayer:LearnSpell(48819) |
| 129 | + | if (player:GetTeam() < 1) then |
| 130 | - | pPlayer:LearnSpell(48801) |
| 130 | + | player:LearnSpell(32182) |
| 131 | - | pPlayer:LearnSpell(48785) |
| 131 | + | else |
| 132 | - | pPlayer:LearnSpell(5502) |
| 132 | + | player:LearnSpell(2825) |
| 133 | - | pPlayer:LearnSpell(20164) |
| 133 | + | end |
| 134 | - | pPlayer:LearnSpell(10326) |
| 134 | + | if (player:HasSpell(61295)) then |
| 135 | - | pPlayer:LearnSpell(1038) |
| 135 | + | player:LearnSpell(61301) |
| 136 | - | pPlayer:LearnSpell(53407) |
| 136 | + | end |
| 137 | - | pPlayer:LearnSpell(48943) |
| 137 | + | if (player:HasSpell(974)) then |
| 138 | - | pPlayer:LearnSpell(20165) |
| 138 | + | player:LearnSpell(49284) |
| 139 | - | pPlayer:LearnSpell(48945) |
| 139 | + | end |
| 140 | - | pPlayer:LearnSpell(642) |
| 140 | + | if (player:HasSpell(30706)) then |
| 141 | - | pPlayer:LearnSpell(48947) |
| 141 | + | player:LearnSpell(57722) |
| 142 | - | pPlayer:LearnSpell(20166) |
| 142 | + | end |
| 143 | - | pPlayer:LearnSpell(4987) |
| 143 | + | if (player:HasSpell(51490)) then |
| 144 | - | pPlayer:LearnSpell(48806) |
| 144 | + | player:LearnSpell(59159) |
| 145 | - | pPlayer:LearnSpell(6940) |
| 145 | + | end |
| 146 | - | pPlayer:LearnSpell(48817) |
| 146 | + | elseif (class == "Mage") then -- Mage |
| 147 | - | pPlayer:LearnSpell(48934) |
| 147 | + | local portals |
| 148 | - | pPlayer:LearnSpell(48938) |
| 148 | + | if (player:GetTeam() < 1) then -- Alliance Portals |
| 149 | - | pPlayer:LearnSpell(25898) |
| 149 | + | portals = {32271, 49359, 3565, 33690, 3562, 3561, 11419, 32266, 11416, 33691, 11059, 49360}
|
| 150 | - | pPlayer:LearnSpell(25899) |
| 150 | + | else -- Horde Portals |
| 151 | - | pPlayer:LearnSpell(32223) |
| 151 | + | portals = {3567, 35715, 3566, 49358, 32272, 3563, 11417, 35717, 32267, 49361, 11420, 11418}
|
| 152 | - | pPlayer:LearnSpell(31884) |
| 152 | + | end |
| 153 | - | pPlayer:LearnSpell(54428) |
| 153 | + | for k, spell in ipairs(portals) do |
| 154 | - | pPlayer:LearnSpell(61411) |
| 154 | + | player:LearnSpell(spell) |
| 155 | - | pPlayer:LearnSpell(53601) |
| 155 | + | end |
| 156 | - | pPlayer:LearnSpell(33388) |
| 156 | + | if (player:HasSpell(11366)) then |
| 157 | - | pPlayer:LearnSpell(33391) |
| 157 | + | player:LearnSpell(42891) |
| 158 | - | pPlayer:LearnSpell(34769) |
| 158 | + | end |
| 159 | - | pPlayer:LearnSpell(34767) |
| 159 | + | if (player:HasSpell(11426)) then |
| 160 | - | |
| 160 | + | player:LearnSpell(43039) |
| 161 | - | if (pPlayer:GetTeam() < 1) then |
| 161 | + | end |
| 162 | - | pPlayer:LearnSpell(31801) |
| 162 | + | if (player:HasSpell(44457)) then |
| 163 | - | else |
| 163 | + | player:LearnSpell(55360) |
| 164 | - | pPlayer:LearnSpell(53736) |
| 164 | + | end |
| 165 | - | end |
| 165 | + | if (player:HasSpell(31661)) then |
| 166 | - | |
| 166 | + | player:LearnSpell(42950) |
| 167 | - | if (pPlayer:HasSpell(20925)) then |
| 167 | + | end |
| 168 | - | pPlayer:LearnSpell(48952) |
| 168 | + | if (player:HasSpell(11113)) then |
| 169 | - | end |
| 169 | + | player:LearnSpell(42945) |
| 170 | - | |
| 170 | + | end |
| 171 | - | if (pPlayer:HasSpell(31935)) then |
| 171 | + | if (player:HasSpell(44425)) then |
| 172 | - | pPlayer:LearnSpell(48827) |
| 172 | + | player:LearnSpell(44781) |
| 173 | - | end |
| 173 | + | end |
| 174 | - | |
| 174 | + | elseif (class == "Warlock") then -- Warlock |
| 175 | - | if (pPlayer:HasSpell(20473)) then |
| 175 | + | if (player:HasSpell(17877)) then |
| 176 | - | pPlayer:LearnSpell(48825) |
| 176 | + | player:LearnSpell(47827) |
| 177 | - | end |
| 177 | + | end |
| 178 | - | |
| 178 | + | if (player:HasSpell(30283)) then |
| 179 | - | pPlayer:GossipComplete() |
| 179 | + | player:LearnSpell(47847) |
| 180 | end | |
| 181 | if (player:HasSpell(30108)) then | |
| 182 | - | if (intid == 3) then -- Hunter |
| 182 | + | player:LearnSpell(47843) |
| 183 | - | pPlayer:LearnSpell(8737) |
| 183 | + | end |
| 184 | - | pPlayer:LearnSpell(1494) |
| 184 | + | if (player:HasSpell(50796)) then |
| 185 | - | pPlayer:LearnSpell(13163) |
| 185 | + | player:LearnSpell(59172) |
| 186 | - | pPlayer:LearnSpell(48996) |
| 186 | + | end |
| 187 | - | pPlayer:LearnSpell(49001) |
| 187 | + | if (player:HasSpell(48181)) then |
| 188 | - | pPlayer:LearnSpell(49045) |
| 188 | + | player:LearnSpell(59164) |
| 189 | - | pPlayer:LearnSpell(53338) |
| 189 | + | end |
| 190 | - | pPlayer:LearnSpell(5116) |
| 190 | + | if (player:HasSpell(18220)) then |
| 191 | - | pPlayer:LearnSpell(27044) |
| 191 | + | player:LearnSpell(59092) |
| 192 | - | pPlayer:LearnSpell(883) |
| 192 | + | end |
| 193 | - | pPlayer:LearnSpell(2641) |
| 193 | + | elseif (class == "Druid") then -- Druid |
| 194 | - | pPlayer:LearnSpell(6991) |
| 194 | + | if (player:HasSpell(50516)) then |
| 195 | - | pPlayer:LearnSpell(982) |
| 195 | + | player:LearnSpell(61384) |
| 196 | - | pPlayer:LearnSpell(1515) |
| 196 | + | end |
| 197 | - | pPlayer:LearnSpell(19883) |
| 197 | + | if (player:HasSpell(48505)) then |
| 198 | - | pPlayer:LearnSpell(20736) |
| 198 | + | player:LearnSpell(53201) |
| 199 | - | pPlayer:LearnSpell(48990) |
| 199 | + | end |
| 200 | - | pPlayer:LearnSpell(2974) |
| 200 | + | if (player:HasSpell(48438)) then |
| 201 | - | pPlayer:LearnSpell(6197) |
| 201 | + | player:LearnSpell(53251) |
| 202 | - | pPlayer:LearnSpell(1002) |
| 202 | + | end |
| 203 | - | pPlayer:LearnSpell(14327) |
| 203 | + | if (player:HasSpell(5570)) then |
| 204 | - | pPlayer:LearnSpell(5118) |
| 204 | + | player:LearnSpell(48468) |
| 205 | - | pPlayer:LearnSpell(49056) |
| 205 | + | end |
| 206 | - | pPlayer:LearnSpell(53339) |
| 206 | + | end |
| 207 | - | pPlayer:LearnSpell(49048) |
| 207 | + | player:SendBroadcastMessage("You have learned your spells!")
|
| 208 | - | pPlayer:LearnSpell(19884) |
| 208 | + | elseif (intid == 1) then |
| 209 | - | pPlayer:LearnSpell(34074) |
| 209 | + | if (player:GetLevel() >= 20) then |
| 210 | - | pPlayer:LearnSpell(781) |
| 210 | + | player:LearnSpell(33388) |
| 211 | - | pPlayer:LearnSpell(14311) |
| 211 | + | end |
| 212 | - | pPlayer:LearnSpell(1462) |
| 212 | + | if (player:GetLevel() >= 40) then |
| 213 | - | pPlayer:LearnSpell(19885) |
| 213 | + | player:LearnSpell(33391) |
| 214 | - | pPlayer:LearnSpell(19880) |
| 214 | + | end |
| 215 | - | pPlayer:LearnSpell(13809) |
| 215 | + | if (player:GetLevel() >= 60) then |
| 216 | - | pPlayer:LearnSpell(13161) |
| 216 | + | player:LearnSpell(34091) |
| 217 | - | pPlayer:LearnSpell(5384) |
| 217 | + | player:LearnSpell(34090) |
| 218 | - | pPlayer:LearnSpell(1543) |
| 218 | + | end |
| 219 | - | pPlayer:LearnSpell(19878) |
| 219 | + | if (player:GetLevel() >= 80) then |
| 220 | - | pPlayer:LearnSpell(49067) |
| 220 | + | player:LearnSpell(54197) |
| 221 | - | pPlayer:LearnSpell(3034) |
| 221 | + | player:LearnSpell(90265) |
| 222 | - | pPlayer:LearnSpell(13159) |
| 222 | + | end |
| 223 | - | pPlayer:LearnSpell(19882) |
| 223 | + | player:SendBroadcastMessage("You have learned your riding skills!")
|
| 224 | - | pPlayer:LearnSpell(58434) |
| 224 | + | elseif (intid == 2) then |
| 225 | - | pPlayer:LearnSpell(49071) |
| 225 | + | for k, spell in ipairs(skills) do |
| 226 | - | pPlayer:LearnSpell(49052) |
| 226 | + | player:LearnSpell(spell) |
| 227 | - | pPlayer:LearnSpell(19879) |
| 227 | + | end |
| 228 | - | pPlayer:LearnSpell(19263) |
| 228 | + | player:SendBroadcastMessage("You have learned all your weapon skills!")
|
| 229 | - | pPlayer:LearnSpell(19801) |
| 229 | + | elseif (intid == 3) then |
| 230 | - | pPlayer:LearnSpell(34026) |
| 230 | + | player:AdvanceAllSkills(450) |
| 231 | - | pPlayer:LearnSpell(34600) |
| 231 | + | player:SendBroadcastMessage("Your skills have been advanced!")
|
| 232 | - | pPlayer:LearnSpell(34477) |
| 232 | + | elseif (intid == 4) then |
| 233 | - | pPlayer:LearnSpell(61006) |
| 233 | + | player:ResetTalents(true) |
| 234 | - | pPlayer:LearnSpell(61847) |
| 234 | + | player:SendBroadcastMessage("You talents have been reset!")
|
| 235 | - | pPlayer:LearnSpell(53271) |
| 235 | + | else |
| 236 | - | pPlayer:LearnSpell(60192) |
| 236 | + | return |
| 237 | - | pPlayer:LearnSpell(62757) |
| 237 | + | end |
| 238 | - | |
| 238 | + | ItemHello(event, player, item) |
| 239 | - | if (pPlayer:HasSpell(19386)) then |
| 239 | + | |
| 240 | - | pPlayer:LearnSpell(49012) |
| 240 | + | |
| 241 | - | end |
| 241 | + | RegisterItemGossipEvent(item_id, 1, ItemHello) |
| 242 | - | |
| 242 | + | RegisterItemGossipEvent(item_id, 2, ItemSelect) |