All pastes #818379 Raw Edit

Unnamed

public text v1 · immutable
·published 2007-12-16 07:50 UTC
rendered paste body


	SetUInt32Value(UNIT_FIELD_LEVEL, 70);
	_UpdateMaxSkillCounts();
	static const char * spells[DRUID+1] = {
		NULL,
			/*spells[WARRIOR] = */"81,107,196,198,201,203,204,355,469,522,668,669,670,671,672,674,676,750,813,871,1161,1680,1719,2048,2382,2457,2479,2565,2687,3050,3365,3411,5246,5301,6233,6246,6247,6477,6478,6554,6603,7266,7267,7341,7355,7620,8386,8737,9077,9078,9116,9125,11578,11585,12678,17737,18499,20230,20597,20598,20599,20600,20864,21651,21652,22027,22810,23920,25203,25208,25212,25225,25231,25236,25242,25264,25266,25275,29704,29707,29932,30357,34428,",
			/*spells[PALADIN] = */"81,107,198,203,204,522,668,669,670,671,672,750,813,1020,1038,1044,1152,2382,2479,3050,3127,3365,4987,5502,5573,6233,6246,6247,6477,6478,6603,7266,7267,7341,7355,7620,8386,8737,9077,9078,9116,9125,10278,10308,10322,10324,10326,17737,19746,19752,20271,20347,20348,20356,20598,20599,20600,20772,20773,21084,21651,21652,22027,22810,25780,25895,25898,27136,27137,27138,27139,27140,27141,27142,27143,27144,27145,27148,27149,27150,27151,27152,27153,27154,27155,27158,27169,27173,27180,27762,29932,31789,31801,31884,31895,32223,33388,33391,33776,34090,34091,",
			/*spells[HUNTER] = */"75,81,136,203,204,264,522,668,669,670,671,672,674,781,813,883,982,1002,1130,1180,1462,1494,1495,1499,1510,1513,1515,1543,1978,2382,2479,2641,2643,2973,2974,3018,3034,3043,3044,3045,3050,3111,3127,3365,3661,3662,5116,5118,5384,6197,6233,6246,6247,6477,6478,6603,6991,7266,7267,7341,7355,8386,8737,9077,9078,9125,13159,13161,13163,13165,13358,13542,13543,13544,13549,13550,13551,13552,13553,13554,13555,13795,13809,13813,14260,14261,14262,14263,14264,14265,14266,14267,14268,14269,14270,14271,14272,14273,14274,14279,14280,14281,14282,14283,14284,14285,14286,14287,14288,14289,14290,14294,14295,14302,14303,14304,14305,14310,14311,14316,14317,14318,14319,14320,14321,14322,14323,14324,14325,14326,14327,15629,15630,15631,15632,17737,19801,19878,19879,19880,19882,19883,19884,19885,20043,20190,20580,20582,20583,20585,20736,21009,21651,21652,22027,22810,24949,25294,25295,25296,27014,27015,27016,27018,27019,27020,27021,27022,27023,27025,27044,27045,27046,29932,34026,34074,34120,34477,34600,36916,",
			/*spells[ROGUE] = */"81,203,204,522,668,669,670,671,672,674,813,921,1180,1725,1787,1804,1833,1842,1860,2094,2382,2479,2567,2764,2836,2842,3050,3127,3365,5938,6233,6246,6247,6477,6478,6603,6774,7266,7267,7341,7355,8386,8643,8681,9077,9078,9125,11297,11305,16092,17737,20598,20599,20600,21184,21651,21652,22027,22810,26669,26679,26862,26863,26865,26866,26867,26884,26889,27441,27448,29932,31224,32684,38764,38768,",
			/*spells[PRIEST] = */"17,81,139,198,203,204,453,522,527,528,552,585,586,588,589,591,592,594,596,598,600,602,605,668,669,670,671,672,813,970,976,984,988,992,996,1004,1006,1243,1244,1245,1706,2006,2010,2050,2052,2053,2054,2055,2060,2061,2096,2382,2479,2767,2791,3050,3365,3747,5009,5019,6060,6063,6064,6065,6066,6074,6075,6076,6077,6078,6233,6246,6247,6477,6478,6603,7128,7266,7267,7341,7355,8092,8102,8103,8104,8105,8106,8122,8124,8129,8131,8192,8386,9078,9125,9472,9473,9474,9484,9485,9578,9579,9592,10797,10874,10875,10876,10880,10881,10888,10890,10892,10893,10894,10898,10899,10900,10901,10909,10911,10912,10915,10916,10917,10927,10928,10929,10933,10934,10937,10938,10941,10942,10945,10946,10947,10951,10952,10953,10955,10957,10960,10961,10963,10964,10965,14914,15261,15262,15263,15264,15265,15266,15267,17737,19289,19291,19292,19293,19296,19299,19302,19303,19304,19305,20580,20582,20583,20585,20770,21009,21651,21652,22027,22810,25210,25213,25217,25218,25221,25222,25233,25235,25308,25314,25315,25316,25363,25364,25367,25368,25372,25375,25379,25380,25384,25389,25429,25431,25435,25446,25450,25596,29932,32375,32379,32546,32996,33076,34433,34863,34864,34865,34866,",
			/*spells[6] = */NULL,
			/*spells[SHAMAN] = */"81,107,131,198,203,204,227,324,325,331,332,370,403,421,522,526,529,546,547,548,556,668,669,670,671,672,813,905,913,915,930,939,943,945,959,1064,1535,2008,2382,2479,2484,2645,2860,2870,3050,3365,3599,5394,5675,5730,6041,6196,6233,6246,6247,6363,6364,6365,6375,6377,6390,6391,6392,6477,6478,6495,6603,7266,7267,7341,7355,8004,8005,8008,8010,8012,8017,8024,8027,8030,8033,8038,8042,8044,8045,8046,8050,8052,8053,8056,8058,8071,8075,8134,8143,8154,8155,8160,8161,8166,8170,8177,8181,8184,8190,8227,8232,8235,8249,8386,8498,8499,8512,8737,8835,9077,9078,9116,9125,10391,10392,10395,10396,10406,10407,10408,10412,10413,10414,10427,10428,10431,10432,10437,10438,10442,10447,10448,10456,10462,10463,10466,10467,10468,10472,10473,10478,10479,10486,10495,10496,10497,10526,10537,10538,10585,10595,10600,10601,10605,10613,10622,10623,10627,11314,11315,15107,15111,15112,15207,15208,16339,16341,16342,16355,16356,16362,16387,17737,20579,20608,20609,20610,20776,20777,21651,21652,22027,22810,24398,25357,25359,25361,25391,25396,25420,25422,25423,25439,25442,25448,25449,25454,25457,25464,25469,25472,25489,25500,25505,25508,25509,25525,25528,25533,25546,25547,25557,25560,25563,25567,25570,25574,25577,25908,27763,28875,28878,28880,29228,29932,33736,36936,",
			/*spells[MAGE] = */"10,66,81,116,118,120,122,130,133,143,145,168,203,204,205,227,475,522,543,587,597,604,668,669,670,671,672,759,813,822,837,865,990,1008,1449,1459,1460,1461,1463,1953,2120,2121,2136,2137,2138,2139,2382,2479,2855,2948,3050,3140,3365,3552,3563,3566,3567,5009,5019,5143,5144,5145,5504,5505,5506,6117,6127,6129,6131,6141,6143,6233,6246,6247,6477,6478,6603,7266,7267,7300,7301,7302,7320,7322,7341,7355,8386,8400,8401,8402,8406,8407,8408,8412,8413,8416,8417,8422,8423,8427,8437,8438,8439,8444,8445,8446,8450,8451,8455,8457,8458,8461,8462,8492,8494,8495,9078,9125,10053,10054,10138,10139,10140,10144,10145,10148,10149,10150,10151,10156,10157,10159,10160,10161,10169,10170,10173,10174,10177,10179,10180,10181,10185,10186,10187,10191,10192,10193,10197,10199,10201,10202,10205,10206,10207,10211,10212,10215,10216,10219,10220,10223,10225,10230,11417,11418,11420,12051,12824,12825,12826,17737,21651,21652,22027,22782,22783,22810,25304,25306,25345,27070,27071,27072,27073,27074,27075,27078,27079,27080,27082,27085,27086,27087,27088,27101,27124,27125,27126,27128,27130,27131,28609,28612,28730,28734,28877,29932,30449,30451,30455,30482,32267,32272,32796,33717,33944,33946,35715,35717,37420,38699,",
			/*spells[WARLOCK] = */"81,126,132,172,203,204,348,522,603,668,669,670,671,672,686,687,688,689,691,693,695,696,697,698,699,702,704,705,706,707,709,710,712,755,813,980,1010,1014,1086,1088,1094,1098,1106,1108,1120,1122,1180,1454,1455,1456,1490,1714,1949,2362,2382,2479,2941,3050,3365,3698,3699,3700,5009,5019,5138,5484,5500,5676,5697,5699,5740,5782,5784,6201,6202,6205,6213,6215,6217,6219,6222,6223,6226,6229,6233,6246,6247,6353,6366,6477,6478,6603,6789,7266,7267,7341,7355,7641,7646,7648,7651,7658,7659,8288,8289,8386,9078,9125,11659,11660,11661,11665,11667,11668,11671,11672,11675,11677,11678,11683,11684,11687,11688,11689,11693,11694,11695,11699,11700,11703,11704,11707,11708,11711,11712,11713,11717,11719,11721,11722,11725,11726,11729,11730,11733,11734,11735,11739,11740,17727,17728,17737,17862,17919,17920,17921,17922,17923,17924,17925,17926,17928,17937,18540,18647,20597,20598,20599,20600,20752,20755,20756,20757,20864,21651,21652,22027,22810,23161,25307,25309,25311,27209,27210,27211,27212,27213,27215,27216,27217,27218,27219,27220,27221,27222,27223,27224,27226,27228,27229,27230,27238,27243,27259,27260,28172,28176,28189,28610,29722,29858,29893,29932,30459,30545,30908,30909,30910,32231,",
			/*spells[10] = */NULL,
			/*spells[DRUID] = */"81,99,203,204,227,339,467,522,668,669,670,671,672,740,768,769,770,774,778,779,780,782,783,813,1058,1062,1066,1075,1079,1082,1126,1178,1180,1430,1735,1822,1823,1824,1850,2090,2091,2382,2479,2637,2782,2893,2908,2912,3025,3029,3050,3137,3365,3627,5176,5177,5178,5179,5180,5185,5186,5187,5188,5189,5195,5196,5201,5209,5211,5215,5217,5221,5225,5229,5232,5234,5487,6233,6246,6247,6477,6478,6603,6756,6778,6780,6783,6785,6787,6793,6795,6798,6800,6807,6808,6809,7266,7267,7341,7355,8386,8903,8905,8907,8910,8914,8918,8921,8924,8925,8926,8927,8928,8929,8936,8938,8939,8940,8941,8946,8949,8950,8951,8955,8972,8983,8992,8998,9005,9077,9078,9125,9490,9492,9493,9634,9745,9747,9749,9750,9752,9754,9756,9758,9821,9823,9827,9829,9830,9833,9834,9835,9839,9840,9841,9845,9846,9849,9850,9852,9853,9856,9857,9858,9862,9863,9866,9867,9875,9876,9880,9881,9884,9885,9888,9889,9894,9896,9898,9901,9904,9907,9908,9910,9912,9913,16914,16952,16954,16958,16961,17401,17402,17737,18657,18658,18960,20484,20580,20582,20583,20585,20719,20739,20742,20747,20748,21009,21651,21652,22027,22568,22570,22810,22812,22827,22828,22829,22842,22895,22896,24248,25297,25298,25299,26978,26979,26980,26981,26982,26983,26984,26985,26986,26987,26988,26989,26990,26992,26993,26994,26995,26996,26997,26998,26999,27000,27001,27002,27003,27005,27006,27008,27012,27764,29166,29932,31018,33357,33745,33763,33786,33943,34090,",
	};

	// 43: Swords
	// 45: Bows
	// 46: Guns
	// 44: Axes
	// 54: Maces
	// 118: Dual Wield
	// 55: 2H Swords
	// 136: Staves
	// 160: 2H Maces
	// 172: 2H Axes
	// 173: Daggers
	// 226: Crossbows
	// 293: Plate
	// 226: Polearems
	// 413: Mail
	// 414: Leather
	// 415: Cloth
	// 433: Shield
	// 473: Fist Weapons

	static const char * skills[DRUID+1] = {
		NULL,
			/* WARRIOR */"172,43,44,55,54,118,136,160,172,173,413,414,415,433,473,",
			/* PALADIN */"43,55,160,172,293,413,414,415,433,",
			/* HUNTER */"43,45,36,44,54,118,55,136,160,172,173,226,413,414,415,",
			/* ROGUE */"118,173,473,414,415,43,",
			/* PRIEST */"54,136,160,173,415,173,",
			/* 6 */NULL,
			/* SHAMAN */"54,136,433,414,413,415,44,172,",
			/* MAGE */"136,173,43,415,",
			/* WARLOCK */"43,136,173,415,",
			/* 10 */NULL,
			/* DRUID */"43,44,54,136,173,414,415,",
	};

	vector<string> spellArr = StrSplit(string(spells[class_]), ",");
	vector<string> skillArr = StrSplit(string(skills[class_]), ",");

	for(vector<string>::iterator itr = spellArr.begin(); itr != spellArr.end(); ++itr)
	{
		uint32 id = atoi((*itr).c_str());
		if(id)
			addSpell(id);
	}

	for(vector<string>::iterator itr = skillArr.begin(); itr != skillArr.end(); ++itr)
	{
		uint32 id = atoi((*itr).c_str());
		if(id)
		{
			skilllineentry * se = dbcSkillLine.LookupEntry(id);
			switch(se->type)
			{
			case SKILL_TYPE_PROFESSION:
				break;

			case SKILL_TYPE_SECONDARY:
				break;

			case SKILL_TYPE_ARMOR:
				_AddSkillLine(id,1,1);
				break;

			case SKILL_TYPE_WEAPON:
				_AddSkillLine(id,350,350);
				break;
			}
		}
	}
	_AddSkillLine(762,300,300);

	for(SkillMap::iterator itr = m_skills.begin(); itr != m_skills.end(); ++itr)
	{
		itr->second.CurrentValue = itr->second.MaximumValue;
	}

    queue<uint32> Items;
	switch(getClass())
	{
	case WARRIOR:
		{
			Items.push(30976); // Onslaught Chestguard
			Items.push(30974); // Onslaught Greathelm
			Items.push(30970); // Onslaught Handguards
			Items.push(30978); // Onslaught Legguards
			Items.push(30980); // Onslaught Shoulderguards
			Items.push(30881); // Warp Slicer
			Items.push(30314); // Phaseshift Bulwark
			//Items.push(17075); // Vis'kag the Bloodletter
			//Items.push(19348); // Red Dragonscale Protector
			//pPlayer->addSpell(750); // Plate Mail
			//pPlayer->addSpell(674); // Dual Wield
			//Skills.push(118);
			//Skills.push(443);
			break;
		}
	case ROGUE:
		{
			for(int i = 0; i<=5; i++)
				Items.push(31026+i); // Slayer Set
			//Items.push(17075); // Vis'kag the Bloodletter
			Items.push(30311); // Warp Slicer
			Items.push(17075); // Vis'kag the Bloodletter
			//Items.push(19324); // The Lobotomizer

			Items.push(32053);
			Items.push(28310);


			//Items.push(31031); // Get rid of the stupid totem
			//Skills.push(43);
			//Skills.push(118);
			//pPlayer->addSpell(674);
			break;
		}
	case MAGE:
		{
			for(int i = 0; i<=5; i++)
				Items.push(31055+i); // Tempest Set
			Items.push(30313); // Staff of Disintegration
			break;
		}
	case WARLOCK:
		{
			for(int i = 0; i<=5; i++)
				Items.push(31050+i); // Malefic Set
			Items.push(30313); // Staff of Disintegration
			//pPlayer->addSpell(227);
			//Skills.push(136);
			break;
		}
	case HUNTER:
		{
			for(int i = 0; i<=5; i++)
				Items.push(31001+i); // Gronnstalker Set
			Items.push(18542); // Typhoon
			Items.push(30318); // Netherstrand Bow
			//Skills.push(43);
			//Skills.push(45);
			//Skills.push(55);
			// Nether Spike, 800 arrows ;)
			Item * item = objmgr.CreateItem(30319, this);
			item->SetUInt32Value(ITEM_FIELD_STACK_COUNT, 8000);
			GetItemInterface()->AddItemToFreeSlot(item);
			break;
		}
	case PALADIN:
		{
			Items.push(30990); // Lightbringer Breastplate
			Items.push(30982); // Lightbringer Gauntlets
			Items.push(30993); // Lightbringer Greaves
			Items.push(30997); // Lightbringer Shoulderbraces
			Items.push(30989); // Lightbringer WarHelm
			Items.push(30902); // Cataclysm's Edge
			Items.push(30314); // Phaseshift Bulwark
			Items.push(30311); // Warp Slicer
			//Skills.push(43);
			//Skills.push(55);
			//Skills.push(433);
			//pPlayer->addSpell(750);
			break;
		}
	case SHAMAN:
		{
			Items.push(31018); // Skyshatter Tunic
			Items.push(31011); // Skyshatter Grips
			Items.push(31015); // Skyshatter Cover
			Items.push(31021); // Skyshatter Pants
			Items.push(31024); // Skyshatter Pauldrons
			Items.push(28800); // Hammer of the Naaru
			//pPlayer->addSpell(199);
			//pPlayer->addSpell(8737);
			//Skills.push(160);
			break;
		}
	case PRIEST:
		{
			Items.push(31061); // Handguards of Absolution
			Items.push(31064); // Hood of Absolution
			Items.push(31067); // Leggings of Absolution
			Items.push(31070); // Shoulderpads of Absolution
			Items.push(31065); // Shroud of Absolution
			Items.push(30313); // Staff of Disintegration
			//pPlayer->addSpell(227);
			//Skills.push(136);
			break;
		}
	case DRUID:
		{
			Items.push(31041); // Thunderheart Tunic
			Items.push(31032); // Thunderheart Gloves
			Items.push(31037); // Thunderheart Helmet
			Items.push(31045); // Thunderheart Legguards
			Items.push(31047); // Thunderheart Spaulders
			Items.push(30313); // Staff of Disintegration
			//Items.push(30883); // Pillar of Ferocity
			break;
		}
	}
	// Mounts by Race
	switch(getRace())
	{
	case RACE_HUMAN:
		Items.push(12354);
		break;
	case RACE_DRAENEI:
		Items.push(32768);
		break;
	case RACE_GNOME:
		Items.push(18772);
		break;
	case RACE_DWARF:
		Items.push(18785);
		break;
	case RACE_NIGHTELF:
		Items.push(18766);
		break;
	case RACE_UNDEAD:
		Items.push(18791);
		break;
	case RACE_ORC:
		Items.push(18796);
		break;
	case RACE_TROLL:
		Items.push(18790);
		break;
	case RACE_TAUREN:
		Items.push(18793);
		break;
	case RACE_BLOODELF:
		Items.push(29223);
		break;

	}
	Items.push(32860);		// netherdrake

	// Add Items
	while(Items.size() > 0)
	{
		Item * item = objmgr.CreateItem(Items.front(), this);
		Items.pop();		
		GetItemInterface()->AddItemToFreeSlot(item);
	}

	ModUInt32Value(PLAYER_FIELD_COINAGE, 200000000);		// 20000 gold
	SetUInt32Value(PLAYER_CHARACTER_POINTS1, 61);

 	load_health = m_uint32Values[UNIT_FIELD_HEALTH];
 	load_mana = m_uint32Values[UNIT_FIELD_POWER1];