View Single Post
  #1  
Old 03-15-2013, 09:32 PM
Maceblade
Hill Giant
 
Join Date: Jun 2010
Posts: 231
Default Need a proof reader please...

Seems I cant get this to work at all. I know its a bit cut up, but its a mash up of a few different scripts;

Code:
sub EVENT_SPAWN {
	quest::setnexthpevent(90);
	}
}

sub EVENT_COMBAT {
	if($combat_state == 0) {
		$npc->SetHP(885000);
	}
}

sub EVENT_HP {  # adds does not aggro unless within aggro range
	if($hpevent == 90) {
		$npc->CastSpell(13882,0);
		quest::setnexthpevent(88);
		quest::emote("shakes with laughter and says, 'You are much stronger than I thought. Looks like I'm gonna have to use all the tricks of the trade!' He then shouts a mystical word of power and suddenly his skin begins to take on a rock like appearance.");
		quest::modifynpcstat("ac", "5587");
	}

	if ($hpevent == 88) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(86);
	}

	if ($hpevent == 86) {	
		$npc->CastSpell(2823, $target->GetID());
		quest::setnexthpevent(84);
	}
	if ($hpevent == 84) {	
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(82);
	}
	if ($hpevent == 82) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(80);
	}


	if ($hpevent == 80) {
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(78);
		quest::emote("shakes with laughter and says, 'You are much stronger than I thought. Looks like I'm gonna have to use all the tricks of the trade!' He then shouts a mystical word of power and is suddenly surrrounded by a magical glowing aura.");
		quest::modifynpcstat("ac", "0");
		quest::modifynpcstat("mr", "2500");
		quest::modifynpcstat("cr", "2500");
		quest::modifynpcstat("fr", "2500");
	}

	if ($hpevent == 78) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(76);
	}

	if ($hpevent == 76) {	
		$npc->CastSpell(2823, $target->GetID());
		quest::setnexthpevent(74);
	}
	if ($hpevent == 74) {	
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(72);
	}
	if ($hpevent == 72) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(70);
	}

  	if($hpevent == 70) {
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(68);
		quest::emote("shakes with laughter and says, 'You are much stronger than I thought. Looks like I'm gonna have to use all the tricks of the trade!' He then shouts a mystical word of power and suddenly his muscles bulge with incomprehensible strength.");
		quest::modifynpcstat("mr", "144");
		quest::modifynpcstat("fr", "144");
		quest::modifynpcstat("cr", "144");
		quest::modifynpcstat("max_hit", "850");
	} 
	if ($hpevent == 68) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(66);
	}

	if ($hpevent == 66) {	
		$npc->CastSpell(2823, $target->GetID());
		quest::setnexthpevent(64);
	}
	if ($hpevent == 64) {	
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(62);
	}
	if ($hpevent == 62) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(60);
	}

	if($hpevent == 60) {
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(58);
		quest::emote("shakes with laughter and says, 'You are much stronger than I thought. Looks like I'm gonna have to use all the tricks of the trade!' He then shouts a mystical word of power and is suddenly surrrounded by a magical glowing aura.");
		quest::modifynpcstat("max_hit", "900");
		quest::modifynpcstat("mr", "2250");
	}

	if ($hpevent == 58) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(56);
	}

	if ($hpevent == 56) {	
		$npc->CastSpell(2823, $target->GetID());
		quest::setnexthpevent(54);
	}
	if ($hpevent == 54) {	
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(52);
	}
	if ($hpevent == 52) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(50);
	}
	if ($hpevent == 50) {
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(48);
		quest::spawn2(999245,0,0,668,733,347,253); # Mayong's Twisted Nightmare
		quest::spawn2(999245,0,0,697,733,347,253); # Mayong's Twisted Nightmare
		quest::spawn2(999245,0,0,749,732,347,253); # Mayong's Twisted Nightmare
		quest::spawn2(999245,0,0,790,732,347,253); # Mayong's Twisted Nightmare
		quest::emote("shakes with laughter and says, 'You are much stronger than I thought. Looks like I'm gonna have to use all the tricks of the trade!' He then shouts a mystical word of power and suddenly his muscles bulge with incomprehensible strength.");
		quest::modifynpcstat("special_attacks",ABfHG);
	    	quest::settimer(1,60);
    		$npc->WipeHateList();
	}

	if ($hpevent == 48) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(46);
	}

	if ($hpevent == 46) {	
		$npc->CastSpell(2823, $target->GetID());
		quest::setnexthpevent(44);
	}
	if ($hpevent == 44) {	
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(42);
	}
	if ($hpevent == 42) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(40);
	}
 	if($hpevent == 40) {
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(38);
		quest::emote("shakes with laughter and says, 'You are much stronger than I thought. Looks like I'm gonna have to use all the tricks of the trade!' He then shouts a string of mystical words and is suddenly surrounded by a magical glowing aura and his skin takes on a rock like appearance.");
		quest::modifynpcstat("max_hit", "700");
		quest::modifynpcstat("ac", "0");
		quest::modifynpcstat("mr", "250");
	}

	if ($hpevent == 38) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(36);
	}

	if ($hpevent == 36) {	
		$npc->CastSpell(2823, $target->GetID());
		quest::setnexthpevent(34);
	}
	if ($hpevent == 34) {	
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(32);
	}
	if ($hpevent == 32) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(30);
	}
	if($hpevent == 30) {
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(28);
		quest::emote("shakes with laughter and says, 'You are much stronger than I thought. Looks like I'm gonna have to use all the tricks of the trade!' He then shouts a string of mystical words and is suddenly surrounded by a magical glowing aura and his attacks become a blur as he launches into a quickened attack routine.");
		quest::modifynpcstat("ac", "1087");
		quest::modifynpcstat("attack_speed", "-50");
		quest::modifynpcstat("max_hit", "150");
	}
	if ($hpevent == 28) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(26);
	}

	if ($hpevent == 26) {	
		$npc->CastSpell(2823, $target->GetID());
		quest::setnexthpevent(24);
	}
	if ($hpevent == 24) {	
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(22);
	}
	if ($hpevent == 22) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(20);
	}

	if ($hpevent == 20) {
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(18);
		quest::emote("shakes with laughter and says, 'You are much stronger than I thought. Looks like I'm gonna have to use all the tricks of the trade!' He then shouts a string of mystical words and is suddenly surrounded by a magical glowing aura and his muscles bulge with incomprehensible strength. ");
		quest::modifynpcstat("attack_speed", "0");
		quest::modifynpcstat("max_hit", "1050");
	}

	if ($hpevent == 18) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(16);
	}

	if ($hpevent == 16) {	
		$npc->CastSpell(2823, $target->GetID());
		quest::setnexthpevent(14);
	}
	if ($hpevent == 14) {	
		$npc->CastSpell(13882, $target->GetID());
		quest::setnexthpevent(12);
	}
	if ($hpevent == 12) {	
		$npc->CastSpell(6539, $target->GetID());
		quest::setnexthpevent(10);
	}
 	if($hpevent == 10) {
		$npc->CastSpell(13882, $target->GetID());
		quest::emote("shakes with laughter and says, 'You are much stronger than I thought. Looks like I'm gonna have to use all the tricks of the trade!' He then shouts a string of mystical words and suddenly his skin takes on a rock like apppearance and he enters a defensive stance!");
		quest::modifynpcstat("ac", "6587");
		quest::modifynpcstat("mr", "1044");
		quest::modifynpcstat("cr", "1044");
		quest::modifynpcstat("dr", "1044");
		quest::modifynpcstat("fr", "1044");
		quest::modifynpcstat("pr", "1044");
		quest::modifynpcstat("max_hit", "450");
	}
}

sub EVENT_SIGNAL {
  if($signal == 1) {
    CheckForRavs();
	}
}

sub CheckForRavs {
  if((!$entity_list->GetMobByNpcTypeID(999245))) {
     quest::modifynpcstat("special_attacks",SRTMCNIDf);
	 quest::stoptimer(1);
	}
}

sub EVENT_TIMER {
	if($timer == "timeup") {
		quest::depop();
	}
}

sub EVENT_DEATH {
	quest::stoptimer("engaged");
	}
}
Any suggestions is appreciated lol
Reply With Quote