Jump to content
  • 0

Announcements Request


UprisingValkyrie

Question


  • Group:  Members
  • Topic Count:  28
  • Topics Per Day:  0.01
  • Content Count:  79
  • Reputation:   1
  • Joined:  02/24/14
  • Last Seen:  

Can i request a script modified for this? all i want is everytime they create or finish a quest item it will announce to all. thanks!

 

sky_quest,54,40,3	script	Valkyrie Randgris	403,{
	for ( .@lv = 1; .@lv < .max_lv; .@lv++ ) {
		if ( countitem( getd( ".valkyrie_lv"+ .@lv ) ) ) {
			if ( .@found )
				next;
			.@found++;
			mes "You have ^0000FF"+ getitemname( getd( ".valkyrie_lv"+ .@lv ) ) +"^000000";
			mes "Requirement ->";
			.@size = getarraysize( getd( ".valkyrie_lv"+ .@lv ) );
			.@complete = 0;
			for ( .@i = 1; .@i < .@size; .@i += 2 ) {
				if ( countitem( getd( ".valkyrie_lv"+ .@lv +"["+ .@i +"]" ) ) < getd( ".valkyrie_lv"+ .@lv +"["+( .@i +1 )+"]" ) )
					.@color$ = "^FF0000";
				else {
					.@color$ = "^009900";
					.@complete++;
				}
				mes .@color$ + getd( ".valkyrie_lv"+ .@lv +"["+( .@i +1 )+"]" )+"x "+ getitemname( getd( ".valkyrie_lv"+ .@lv +"["+ .@i +"]" ) );
			}
			if ( .@complete == .@size /2 ) {
				mes " ";
				mes "^000000your "+ getitemname( getd( ".valkyrie_lv"+ .@lv ) ) +" has upgrade into "+ getitemname( getd( ".valkyrie_lv"+( .@lv +1 ) ) );
				for ( .@i = 1; .@i < .@size; .@i += 2 )
					delitem getd( ".valkyrie_lv"+ .@lv +"["+ .@i +"]" ), getd( ".valkyrie_lv"+ .@lv +"["+( .@i +1 )+"]" );
				delitem getd( ".valkyrie_lv"+ .@lv ), 1;
				getitem getd( ".valkyrie_lv"+( .@lv +1 ) ), 1;
			}
		}
	}
	if ( !.@found )
		mes "Im Sorry, you need Pure Valkyrie Helm";
		//mes "you don't have Pure Valkyrie Helm in your inventory";
	close;
OnInit:
	setarray .valkyrie_lv1, 24001, 7090,5,7838,5,7835,5,7837,5,7836,5,7511,500,7563,1000;
	setarray .valkyrie_lv2, 24002, 7090,10,7838,10,7835,10,7837,10,7836,10,7511,550,7563,1100;
	setarray .valkyrie_lv3, 24003, 7090,15,7838,15,7835,15,7837,15,7836,15,7511,600,7563,1200;
	setarray .valkyrie_lv4, 24004, 7090,20,7838,20,7835,20,7837,20,7836,20,7511,650,7563,1300;
	setarray .valkyrie_lv5, 24005, 7090,25,7838,25,7835,25,7837,25,7836,25,7511,700,7563,1400;
	setarray .valkyrie_lv6, 24006, 7090,30,7838,30,7835,30,7837,30,7836,30,7511,750,7563,1500;
	setarray .valkyrie_lv7, 24007, 7090,35,7838,35,7835,35,7837,35,7836,35,7511,800,7563,1600;
	setarray .valkyrie_lv8, 24008, 7090,40,7838,40,7835,40,7837,40,7836,40,7511,850,7563,1700;
	setarray .valkyrie_lv9, 24009, 7090,45,7838,45,7835,45,7837,45,7836,45,7511,900,7563,1800;
	setarray .valkyrie_lv10, 24010, 7090,50,7838,50,7835,50,7837,50,7836,50,7511,950,7563,1900;
	setarray .valkyrie_lv11, 24011, 7090,60,7838,60,7835,60,7837,60,7836,60,7511,1000,7563,2000;
	setarray .valkyrie_lv12, 24012;
 
	.max_lv = 1;
	while ( getd( ".valkyrie_lv"+ .max_lv ) ) .max_lv++;
	.max_lv--;
	end;
}




//===== rAthena Script =======================================
//= tr0n's Questboard
//===== By: ==================================================
//= tr0n
//===== Current Version: =====================================
//= 1.4.4
//===== Compatible With: ===================================== 
//= rAthena Project
//===== Description: =========================================
//= Easily add collection and hunting quests.
//===== Additional Comments: =================================  
// 1.0.0 Release
// 1.1.0 Added zeny reward
// 1.2.0 Rewrote checkmob and killcounter
// 1.3.1 Added level restriction
// 1.3.4 Added Reward Item Amount
// 1.4.4 Added Quest delay
//============================================================

sky_quest,41,41,5	script	Bulletin Quest	837,{
		
	if(c_run==1){
		mes "[^FF7700Questboard^000000]";
		mes "^0000FF"+getd("." + currentquest$ + "_collectionname$")+"^000000";
		mes "--------------------------------";
		for( set .@j, 0; .@j < getarraysize(getd("."+ currentquest$ + "_collectionitem")); set .@j,.@j+2) {
			mes "^FF0000"+getitemname(getd("."+currentquest$+"_collectionitem["+.@j+"]"))+" - "+countitem(getd("."+currentquest$+"_collectionitem["+.@j+"]"))+"/"+getd("."+currentquest$+"_collectionitem["+(.@j+1)+"]")+" ea.^000000";
		}
		mes "--------------------------------";
		mes "[Reward]";
		mes "Item: ^0000FF"+((getd("." +currentquest$+"_collectionprize"))?getitemname(getd("." +currentquest$+"_collectionprize"))+" - "+getd("." +currentquest$+"_collectionamount")+" ea.^000000":"Nothing^000000");
		mes "Zeny: ^0000FF"+getd("." +currentquest$+"_collectionzeny")+"^000000";
		mes "Base EXP: ^0000FF"+getd("." +currentquest$+"_collectionexp["+0+"]")+"^000000";
		mes "Job EXP: ^0000FF"+getd("." +currentquest$+"_collectionexp["+1+"]")+"^000000";
		next;
		if(select("Finish:Abort") == 2){
			mes "[^FF7700Questboard^000000]";
			mes "Quest aborted.";
			set currentquest$, "";
			set c_run, 0;
			close;
		}
		goto L_checkitems;
	}
	
	if(h_run==1){
		mes "[^FF7700Questboard^000000]";
		mes "^0000FF"+getd("." + currentquest$ + "_huntingname$")+"^000000";
		mes "--------------------------------";
		for( set .@j, 0; .@j < getarraysize(getd("."+ currentquest$ + "_huntingmob")); set .@j,.@j+2) {
			set .@currentmob, getd("."+currentquest$+"_huntingmob["+(.@j)+"]");
			mes "^FF0000"+strmobinfo(1,getd("."+currentquest$+"_huntingmob["+.@j+"]"))+" - "+getd(currentquest$+"_"+.@currentmob+"_"+(.@j+1)+"_killcount")+"/"+getd("."+currentquest$+"_huntingmob["+(.@j+1)+"]")+" ea.^000000";
		}
		mes "--------------------------------";
		mes "[Reward]";
		mes "Item: ^0000FF"+((getd("." +currentquest$+"_huntingprize"))?getitemname(getd("." +currentquest$+"_huntingprize"))+" - "+getd("." +currentquest$+"_huntingamount")+" ea.^000000":"Nothing^000000");
		mes "Zeny: ^0000FF"+getd("." +currentquest$+"_huntingzeny")+"^000000";
		mes "Base EXP: ^0000FF"+getd("." +currentquest$+"_huntingexp["+0+"]")+"^000000";
		mes "Job EXP: ^0000FF"+getd("." +currentquest$+"_huntingexp["+1+"]")+"^000000";
		next;
		if(select("Finish:Abort") == 2){
			mes "[^FF7700Questboard^000000]";
			mes "Quest aborted.";
			for(set .@x, 1; .@x < getarraysize(getd("."+currentquest$+"_huntingmob")); set .@x,.@x+2){
				set .@currentmob, getd("."+currentquest$+"_huntingmob["+(.@x-1)+"]");
				setd(currentquest$+"_"+.@currentmob+"_"+.@x+"_killcount", 0);
			}
			set currentquest$, "";
			set h_run, 0;
			close;
		}
		goto L_checkmobs;
	}
		
L_questmenu:
	mes "[^FF7700Questboard^000000]";
	mes "Select category:";
	next;
	
	switch(select((.collection)?"Collection Quests":"",
				  (.hunting)?"Hunting Quests":"",
				  "Exit")) {
	
case 1:
	set .@collectmenu$, "";
	for( set .@i,0; .@i < .collectionquestcount; set .@i,.@i+1) {
		if (.@i) set .@collectmenu$,.@collectmenu$+":";
		set .@collectmenu$, .@collectmenu$ + "[" + getd("." +(.@i+1)+"_collectionmin") + " - " + getd("." +(.@i+1)+"_collectionmax") + "] " + getd("." + (.@i+1) + "_collectionname$");
	}
	set .@selection,select(.@collectmenu$);
	if(gettimetick(2) < getd(.@selection + "_collection_delay")){
		set .@time_left, getd(.@selection + "_collection_delay")-gettimetick(2);
		mes "[^FF7700Questboard^000000]";
		if(.@time_left < 60) mes "You have to wait ^0000FF"+.@time_left+" seconds^000000 to do this quest again.";
		if(.@time_left < 3600) mes "You have to wait ^0000FF"+.@time_left/60+" minutes^000000 to do this quest again.";
		mes "You have to wait ^0000FF"+.@time_left/60/60+" hours^000000 to do this quest again.";
		close;
	}
	mes "[^FF7700Questboard^000000]";
	mes "^0000FF"+getd("." + .@selection + "_collectionname$")+"^000000";
	mes "--------------------------------";
	for( set .@j, 0; .@j < getarraysize(getd("."+ .@selection + "_collectionitem")); set .@j,.@j+2) {
		mes "^FF0000"+getitemname(getd("."+.@selection+"_collectionitem["+.@j+"]"))+" - "+getd("."+.@selection+"_collectionitem["+(.@j+1)+"]")+" ea.^000000";
	}
	mes "--------------------------------";
	mes "[Reward]";
	mes "Item: ^0000FF"+((getd("." +.@selection+"_collectionprize"))?getitemname(getd("." +.@selection+"_collectionprize"))+" - "+getd("." +.@selection+"_collectionamount")+" ea.^000000":"Nothing^000000");
	mes "Zeny: ^0000FF"+getd("." +.@selection+"_collectionzeny")+"^000000";
	mes "Base EXP: ^0000FF"+getd("." +.@selection+"_collectionexp["+0+"]")+"^000000";
	mes "Job EXP: ^0000FF"+getd("." +.@selection+"_collectionexp["+1+"]")+"^000000";
	next;
	if(select("Accept:Decline") == 2){
		close;
	}
	if(BaseLevel >= getd("." +.@selection+"_collectionmin") && BaseLevel <= getd("." +.@selection+"_collectionmax"))
	{
		mes "[^FF7700Questboard^000000]";
		mes "Quest accepted.";
		set c_run, 1;
		set currentquest$, .@selection;
		close;
	}
	else
	{
		mes "[^FF7700Questboard^000000]";
		mes "You don't have the required";
		mes "level to do this quest.";
		close;
	}
	
case 2:
	set .@huntmenu$, "";
	for( set .@i,0; .@i < .huntingquestcount; set .@i,.@i+1) {
		if (.@i) set .@huntmenu$,.@huntmenu$+":";
		set .@huntmenu$, .@huntmenu$ + "[" + getd("." +(.@i+1)+"_huntingmin") + " - " + getd("." +(.@i+1)+"_huntingmax") + "] " + getd("." + (.@i+1) + "_huntingname$");
	}
	set .@selection,select(.@huntmenu$);
	if(gettimetick(2) < getd(.@selection + "_hunting_delay")){
		set .@time_left, getd(.@selection + "_hunting_delay")-gettimetick(2);
		mes "[^FF7700Questboard^000000]";
		if(.@time_left < 60) mes "You have to wait ^0000FF"+.@time_left+" seconds^000000 to do this quest again.";
		if(.@time_left < 3600) mes "You have to wait ^0000FF"+.@time_left/60+" minutes^000000 to do this quest again.";
		mes "You have to wait ^0000FF"+.@time_left/60/60+" hours^000000 to do this quest again.";
		close;
	}
	mes "[^FF7700Questboard^000000]";
	mes "^0000FF"+getd("." + .@selection + "_huntingname$")+"^000000";
	mes "--------------------------------";
	for( set .@j, 0; .@j < getarraysize(getd("."+ .@selection + "_huntingmob")); set .@j,.@j+2) {
		mes "^FF0000"+strmobinfo(1,getd("."+.@selection+"_huntingmob["+.@j+"]"))+" - "+getd("."+.@selection+"_huntingmob["+(.@j+1)+"]")+" ea.^000000";
	}
	mes "--------------------------------";
	mes "[Reward]";
	mes "Item: ^0000FF"+((getd("." +.@selection+"_huntingprize"))?getitemname(getd("." +.@selection+"_huntingprize"))+" - "+getd("." +.@selection+"_huntingamount")+" ea.^000000":"Nothing^000000");
	mes "Zeny: ^0000FF"+getd("." +.@selection+"_huntingzeny")+"^000000";
	mes "Base EXP: ^0000FF"+getd("." +.@selection+"_huntingexp["+0+"]")+"^000000";
	mes "Job EXP: ^0000FF"+getd("." +.@selection+"_huntingexp["+1+"]")+"^000000";
	next;
	if(select("Accept:Decline") == 2){
		close;
	}
	if(BaseLevel >= getd("." +.@selection+"_huntingmin") && BaseLevel <= getd("." +.@selection+"_huntingmax"))
	{
		mes "[^FF7700Questboard^000000]";
		mes "Quest accepted.";
		set h_run, 1;
		set currentquest$, .@selection;
		close;
	}
	else
	{
		mes "[^FF7700Questboard^000000]";
		mes "You don't have the required";
		mes "level to do this quest.";
		close;
	}
	
case 3:
	close;
	}
	
L_checkitems:
	for( set .@k,0; .@k < getarraysize(getd("."+currentquest$+"_collectionitem")); set .@k,.@k+2) {
		if(countitem(getd("."+currentquest$+"_collectionitem["+.@k+"]"))>=getd("."+currentquest$+"_collectionitem["+(.@k+1)+"]")){
			set .@checkitem,.@checkitem+2;
		}
	}
	if(.@checkitem<getarraysize(getd("."+currentquest$+"_collectionitem"))){
		mes "[^FF7700Questboard^000000]";
		mes "You don't have everything.";
		close;
	}
	for( set .@delcount,0; .@delcount < getarraysize(getd("."+currentquest$+"_collectionitem")); set .@delcount,.@delcount+2) {
		delitem getd("."+currentquest$+"_collectionitem["+.@delcount+"]"),getd("."+currentquest$+"_collectionitem["+(.@delcount+1)+"]");
	}
	mes "[^FF7700Questboard^000000]";
	mes "Congratulation! Here is your Reward.";
	if(getd("." +currentquest$+"_collectionprize")!=0) getitem(getd("." +currentquest$+"_collectionprize"),getd("." +currentquest$+"_collectionamount"));
	set Zeny,Zeny+getd("." +currentquest$+"_collectionzeny");
	getexp getd("." +currentquest$+"_collectionexp["+0+"]"),getd("." +currentquest$+"_collectionexp["+1+"]");
	setd(currentquest$ + "_collection_delay"),gettimetick(2)+.quest_delay;
	set currentquest$, "";
	set c_run, 0;
	close;
	
L_checkmobs:
	set .@goal, (getarraysize(getd("."+currentquest$+"_huntingmob"))/2);
	for(set .@i, 1; .@i < getarraysize(getd("."+currentquest$+"_huntingmob")); set .@i,.@i+2){
		set .@currentmob, getd("."+currentquest$+"_huntingmob["+(.@i-1)+"]");
		if(getd(currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount")==getd("."+currentquest$+"_huntingmob["+.@i+"]")){
			set .@checkmonster, .@checkmonster+1;
			if(.@checkmonster==.@goal){
				goto L_checkmobs2;
			}
			continue;
		}
		goto L_checkmobs2;
	}
	
L_checkmobs2:
	if(.@checkmonster<.@goal){
		mes "[^FF7700Questboard^000000]";
		mes "You didn't kill everything.";
		close;
	}
	mes "[^FF7700Questboard^000000]";
	mes "Congratulation! Here is your Reward.";
	for(set .@x, 1; .@x < getarraysize(getd("."+currentquest$+"_huntingmob")); set .@x,.@x+2){
		set .@currentmob, getd("."+currentquest$+"_huntingmob["+(.@x-1)+"]");
		setd(currentquest$+"_"+.@currentmob+"_"+.@x+"_killcount", 0);
	}
	if(getd("." +currentquest$+"_huntingprize")!=0) getitem(getd("." +currentquest$+"_huntingprize"),getd("." +currentquest$+"_huntingamount"));
	set Zeny, Zeny+getd("." +currentquest$+"_huntingzeny");
	getexp getd("." +currentquest$+"_huntingexp["+0+"]"),getd("." +currentquest$+"_huntingexp["+1+"]");
	setd(currentquest$ + "_hunting_delay"),gettimetick(2)+.quest_delay;
	set currentquest$, "";
	set h_run, 0;
	close;

OnNPCKillEvent:
	if(h_run!=1) end;
	for(set .@i, 1; .@i < getarraysize(getd("."+currentquest$+"_huntingmob")); set .@i,.@i+2){
		if(killedrid==getd("."+currentquest$+"_huntingmob["+(.@i-1)+"]")){
			set .@currentmob, getd("."+currentquest$+"_huntingmob["+(.@i-1)+"]");
			if(getd(currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount")>=getd("."+currentquest$+"_huntingmob["+.@i+"]")) end;
			setd(currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount", getd(currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount")+1);
			dispbottom getd("."+currentquest$+"_huntingname$")+": ["+strmobinfo(1,.@currentmob)+"] ("+ getd(currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount")+"/"+getd("."+currentquest$+"_huntingmob["+.@i+"]")+")";
			end;
		}
		continue;
	}
	end;
	
OnInit:

	function AddCollection;
	function AddHunting;

	//Activate/Deactive quest categories here
	set .collection, 1;
	set .hunting, 1;
	
	//Quest Delay (seconds)
	//24 hours = 86400 seconds
	set .quest_delay, 0;
	
	//Checks if quests are loaded (prevents out of index)
	if(.questsloaded==1) end;
		set .questsloaded, 1;
		
		//Add Collection Quests here
		//AddCollection("<Quest Name>",<Min Lvl>,<Max Lvl>,<Reward|Item ID>,<Reward|Item Amount>,<Zeny Reward>,<Base EXP>,<Job EXP>,<Item ID>,<Item Amount>,...);
		AddCollection("Angelic Set",99,255,30101,1,1000000,10000,5000,949,2500,916,2500,7063,1000,7938,500,6394,500,7115,500,7440,500,6393,500,7079,5);
		AddCollection("Mystic Soul Set",99,255,30104,1,1000000,10000,5000,7255,2500,7849,2500,6087,500,6003,50,6001,50,6088,500,7307,500,7701,50,7089,5);
		AddCollection("Absolute Set",99,255,30102,1,1000000,10000,5000,6269,500,7960,2500,1053,500,7210,2500,6072,2500,7297,50,7430,50,7023,500,6024,10);
		AddCollection("The Scientist Set",99,255,30103,1,1000000,10000,5000,6278,2500,6274,2500,6541,500,6427,500,672,500,6386,500,7913,500,7871,500,7081,5);
		AddCollection("Dark Shadow Set",99,255,30105,1,1000000,10000,5000,7524,2500,7886,2500,7345,500,7315,500,7157,500,6089,500,6091,50,18002,50,7837,5);
		AddCollection("Mermaid Set",99,255,30106,1,1000000,10000,5000,1036,2500,7562,50,951,500,950,500,995,2500,954,500,926,50,722,50,7836,5);
		AddCollection("Pierrot Set",99,255,30107,1,1000000,10000,5000,6270,2500,6511,2500,7328,500,7803,500,982,500,30011,500,7537,50,7284,50,7833,5);
		AddCollection("Holy Guardian Set",99,255,30108,1,1000000,10000,5000,6187,2500,6274,2500,7914,500,6395,500,7796,50,7866,50,6152,500,7024,50,7074,5);
		AddCollection("White Vestment Set",99,255,30109,1,1000000,10000,5000,6418,2500,7960,2500,6173,500,676,500,11524,500,7230,50,30012,50,7092,5);
		AddCollection("Deadly Shadow Set",99,255,30110,1,1000000,10000,5000,6470,2500,7109,50,7449,500,7563,2500,631,500,678,500,7936,50,6306,50,7090,5);
		AddCollection("Shadow of Darkness Set",99,255,30111,1,1000000,10000,5000,6100,2500,7798,2500,6027,500,641,500,12020,500,7511,500,7566,50,7340,50,7080,5);
		AddCollection("Powerful Mantra Set",99,255,30112,1,1000000,10000,5000,7504,2500,1045,2500,7921,500,7057,500,7939,500,6219,500,30013,50,7305,50,7075,5);

		AddCollection("Goblin Master Coat",99,255,25027,1,1000000,10000,5000,996,200,693,100,7265,300,1820,10,992,100);
		AddCollection("Clear Cyclops",99,255,25028,1,1000000,10000,5000,7511,1000,7507,200,7111,100,7151,100,1048,200,7312,300);



		//Add Hunting Quests here
		//AddHunting("<Quest Name>",<Min Lvl>,<Max Lvl>,<Reward|Item ID>,<Reward|Item Amount>,<Zeny Reward>,<Base EXP>,<Job EXP>,<Monster ID>,<Monster Amount>,...);
		AddHunting("Valkyrie Quest",150,255,24001,1,1000000,100000,50000,1751,1,1765,10);
		AddHunting("Darker Than Black",150,255,25001,1,100000,10000,5000,1120,5,1179,50,1116,50,1869,50,1143,50);
		AddHunting("Thanatos Slaves",150,255,25002,1,100000,10000,5000,1704,10,1705,10,1706,10,1707,10,1708,1);
		AddHunting("Valkyrie Realm",150,255,25003,1,100000,10000,5000,1765,10,1751,1);
		AddHunting("Mask of Despair",150,255,25004,1,100000,10000,5000,1130,50,1831,30,1833,30,1837,50,1832,1);
		AddHunting("Glass of Despair",150,255,25005,1,100000,10000,5000,1130,50,1831,50,1833,50,1837,50,1832,1);
		AddHunting("Scarf Of Nightmare",150,255,25006,1,100000,10000,5000,1867,50,1268,10,1507,50,1109,50);
		AddHunting("Ring Of Night",150,255,25007,1,100000,10000,5000,1146,100,1203,10,1379,50);
		AddHunting("Ring Of Sound Wave",150,255,25008,1,100000,10000,5000,1408,50,1267,100,1513,30,1299,1);
		AddHunting("Sun Glass Of Hidden",150,255,25009,1,100000,10000,5000,1289,150);
		AddHunting("Beats By Dr. Dre",150,255,25010,1,100000,10000,5000,1114,500);
		AddHunting("Ring of Flower",150,255,25011,1,100000,10000,5000,1078,20,1079,20,1080,20,1082,20);
		AddHunting("Spirit of the Sun",150,255,25012,1,100000,10000,5000,1837,500);
		AddHunting("Winter Snow",150,255,25013,1,100000,10000,5000,1776,1000);
		AddHunting("Soul of 2 Headed Dragon",150,255,25014,1,100000,10000,5000,1720,50);
		AddHunting("Rune of Spells",150,255,25040,1,100000,10000,5000,1639,100,1059,5,1713,300);
		AddHunting("Shinobi of Konoha",150,255,25042,1,100000,10000,5000,1068,100,1034,100,1785,10);
		AddHunting("Hollowed Mask",150,255,25039,1,100000,10000,5000,1163,300,1159,5,1583,5);
		
		
		
		
		
		end;
		

function AddCollection {
	set .collectionquestcount,.collectionquestcount+1;
	setd ("." +.collectionquestcount+"_collectionname$", getarg(0));
	setd ("." +.collectionquestcount+"_collectionmin", getarg(1));
	setd ("." +.collectionquestcount+"_collectionmax", getarg(2));
	setd ("." +.collectionquestcount+"_collectionprize", getarg(3));
	setd ("." +.collectionquestcount+"_collectionamount", getarg(4));
	setd ("." +.collectionquestcount+"_collectionzeny", getarg(5));
	set .@argcount, 6;
	set .@size, getarraysize(getd("."+ .collectionquestcount + "_collectionexp"));
	setd ("." +.collectionquestcount+"_collectionexp["+.@size+"]",getarg(.@argcount)); 
	setd ("." +.collectionquestcount+"_collectionexp["+(.@size+1)+"]",getarg(.@argcount+1)); 
	set .@argcount, .@argcount+2;
	while(getarg(.@argcount,-1)!=-1 && getarg(.@argcount+1,-1)!=-1) {
		set .@size, getarraysize(getd("."+ .collectionquestcount + "_collectionitem"));
		setd ("."+.collectionquestcount+"_collectionitem["+.@size+"]",getarg(.@argcount)); 
		setd ("."+.collectionquestcount+"_collectionitem["+(.@size+1)+"]",getarg(.@argcount+1));
		set .@argcount,.@argcount+2;
	}
	return;
}

function AddHunting {
	set .huntingquestcount,.huntingquestcount+1;
	setd ("." +.huntingquestcount+"_huntingname$", getarg(0));
	setd ("." +.huntingquestcount+"_huntingmin", getarg(1));
	setd ("." +.huntingquestcount+"_huntingmax", getarg(2));
	setd ("." +.huntingquestcount+"_huntingprize", getarg(3));
	setd ("." +.huntingquestcount+"_huntingamount", getarg(4));
	setd ("." +.huntingquestcount+"_huntingzeny", getarg(5));
	set .@size, getarraysize(getd("."+ .huntingquestcount + "_huntingexp"));
	set .@argcount, 6;
	setd ("." +.huntingquestcount+"_huntingexp["+.@size+"]",getarg(.@argcount));
	setd ("." +.huntingquestcount+"_huntingexp["+(.@size+1)+"]",getarg(.@argcount+1)); 
	set .@argcount, .@argcount+2;
	while(getarg(.@argcount,-1)!=-1 && getarg(.@argcount+1,-1)!=-1) {
		set .@size, getarraysize(getd("."+ .huntingquestcount + "_huntingmob"));
		setd ("."+.huntingquestcount+"_huntingmob["+.@size+"]",getarg(.@argcount)); 
		setd ("."+.huntingquestcount+"_huntingmob["+(.@size+1)+"]",getarg(.@argcount+1));
		set .@argcount, .@argcount+2;
	}
	return;
}
}
 
Link to comment
Share on other sites

2 answers to this question

Recommended Posts


  • Group:  Forum Moderator
  • Topic Count:  33
  • Topics Per Day:  0.01
  • Content Count:  1282
  • Reputation:   393
  • Joined:  02/03/12
  • Last Seen:  


//===== rAthena Script =======================================

//= tr0n's Questboard

//===== By: ==================================================

//= tr0n

//===== Current Version: =====================================

//= 1.4.4

//===== Compatible With: =====================================

//= rAthena Project

//===== Description: =========================================

//= Easily add collection and hunting quests.

//===== Additional Comments: =================================

// 1.0.0 Release

// 1.1.0 Added zeny reward

// 1.2.0 Rewrote checkmob and killcounter

// 1.3.1 Added level restriction

// 1.3.4 Added Reward Item Amount

// 1.4.4 Added Quest delay

//============================================================

sky_quest,41,41,5 script Bulletin Quest 837,{

if(c_run==1){

mes "[^FF7700Questboard^000000]";

mes "^0000FF"+getd("." + currentquest$ + "_collectionname$")+"^000000";

mes "--------------------------------";

for( set .@j, 0; .@j < getarraysize(getd("."+ currentquest$ + "_collectionitem")); set .@j,.@j+2) {

mes "^FF0000"+getitemname(getd("."+currentquest$+"_collectionitem["+.@j+"]"))+" - "+countitem(getd("."+currentquest$+"_collectionitem["+.@j+"]"))+"/"+getd("."+currentquest$+"_collectionitem["+(.@j+1)+"]")+" ea.^000000";

}

mes "--------------------------------";

mes "[Reward]";

mes "Item: ^0000FF"+((getd("." +currentquest$+"_collectionprize"))?getitemname(getd("." +currentquest$+"_collectionprize"))+" - "+getd("." +currentquest$+"_collectionamount")+" ea.^000000":"Nothing^000000");

mes "Zeny: ^0000FF"+getd("." +currentquest$+"_collectionzeny")+"^000000";

mes "Base EXP: ^0000FF"+getd("." +currentquest$+"_collectionexp["+0+"]")+"^000000";

mes "Job EXP: ^0000FF"+getd("." +currentquest$+"_collectionexp["+1+"]")+"^000000";

next;

if(select("Finish:Abort") == 2){

mes "[^FF7700Questboard^000000]";

mes "Quest aborted.";

set currentquest$, "";

set c_run, 0;

close;

}

goto L_checkitems;

}

if(h_run==1){

mes "[^FF7700Questboard^000000]";

mes "^0000FF"+getd("." + currentquest$ + "_huntingname$")+"^000000";

mes "--------------------------------";

for( set .@j, 0; .@j < getarraysize(getd("."+ currentquest$ + "_huntingmob")); set .@j,.@j+2) {

set .@currentmob, getd("."+currentquest$+"_huntingmob["+(.@j)+"]");

mes "^FF0000"+strmobinfo(1,getd("."+currentquest$+"_huntingmob["+.@j+"]"))+" - "+getd(currentquest$+"_"+.@currentmob+"_"+(.@j+1)+"_killcount")+"/"+getd("."+currentquest$+"_huntingmob["+(.@j+1)+"]")+" ea.^000000";

}

mes "--------------------------------";

mes "[Reward]";

mes "Item: ^0000FF"+((getd("." +currentquest$+"_huntingprize"))?getitemname(getd("." +currentquest$+"_huntingprize"))+" - "+getd("." +currentquest$+"_huntingamount")+" ea.^000000":"Nothing^000000");

mes "Zeny: ^0000FF"+getd("." +currentquest$+"_huntingzeny")+"^000000";

mes "Base EXP: ^0000FF"+getd("." +currentquest$+"_huntingexp["+0+"]")+"^000000";

mes "Job EXP: ^0000FF"+getd("." +currentquest$+"_huntingexp["+1+"]")+"^000000";

next;

if(select("Finish:Abort") == 2){

mes "[^FF7700Questboard^000000]";

mes "Quest aborted.";

for(set .@x, 1; .@x < getarraysize(getd("."+currentquest$+"_huntingmob")); set .@x,.@x+2){

set .@currentmob, getd("."+currentquest$+"_huntingmob["+(.@x-1)+"]");

setd(currentquest$+"_"+.@currentmob+"_"+.@x+"_killcount", 0);

}

set currentquest$, "";

set h_run, 0;

close;

}

goto L_checkmobs;

}

L_questmenu:

mes "[^FF7700Questboard^000000]";

mes "Select category:";

next;

switch(select((.collection)?"Collection Quests":"",

(.hunting)?"Hunting Quests":"",

"Exit")) {

case 1:

set .@collectmenu$, "";

for( set .@i,0; .@i < .collectionquestcount; set .@i,.@i+1) {

if (.@i) set .@collectmenu$,.@collectmenu$+":";

set .@collectmenu$, .@collectmenu$ + "[" + getd("." +(.@i+1)+"_collectionmin") + " - " + getd("." +(.@i+1)+"_collectionmax") + "] " + getd("." + (.@i+1) + "_collectionname$");

}

set .@selection,select(.@collectmenu$);

if(gettimetick(2) < getd(.@selection + "_collection_delay")){

set .@time_left, getd(.@selection + "_collection_delay")-gettimetick(2);

mes "[^FF7700Questboard^000000]";

if(.@time_left < 60) mes "You have to wait ^0000FF"+.@time_left+" seconds^000000 to do this quest again.";

if(.@time_left < 3600) mes "You have to wait ^0000FF"+.@time_left/60+" minutes^000000 to do this quest again.";

mes "You have to wait ^0000FF"+.@time_left/60/60+" hours^000000 to do this quest again.";

close;

}

mes "[^FF7700Questboard^000000]";

mes "^0000FF"+getd("." + .@selection + "_collectionname$")+"^000000";

mes "--------------------------------";

for( set .@j, 0; .@j < getarraysize(getd("."+ .@selection + "_collectionitem")); set .@j,.@j+2) {

mes "^FF0000"+getitemname(getd("."+.@selection+"_collectionitem["+.@j+"]"))+" - "+getd("."+.@selection+"_collectionitem["+(.@j+1)+"]")+" ea.^000000";

}

mes "--------------------------------";

mes "[Reward]";

mes "Item: ^0000FF"+((getd("." +.@selection+"_collectionprize"))?getitemname(getd("." +.@selection+"_collectionprize"))+" - "+getd("." +.@selection+"_collectionamount")+" ea.^000000":"Nothing^000000");

mes "Zeny: ^0000FF"+getd("." +.@selection+"_collectionzeny")+"^000000";

mes "Base EXP: ^0000FF"+getd("." +.@selection+"_collectionexp["+0+"]")+"^000000";

mes "Job EXP: ^0000FF"+getd("." +.@selection+"_collectionexp["+1+"]")+"^000000";

next;

if(select("Accept:Decline") == 2){

close;

}

if(BaseLevel >= getd("." +.@selection+"_collectionmin") && BaseLevel <= getd("." +.@selection+"_collectionmax"))

{

mes "[^FF7700Questboard^000000]";

mes "Quest accepted.";

set c_run, 1;

set currentquest$, .@selection;

close;

}

else

{

mes "[^FF7700Questboard^000000]";

mes "You don't have the required";

mes "level to do this quest.";

close;

}

case 2:

set .@huntmenu$, "";

for( set .@i,0; .@i < .huntingquestcount; set .@i,.@i+1) {

if (.@i) set .@huntmenu$,.@huntmenu$+":";

set .@huntmenu$, .@huntmenu$ + "[" + getd("." +(.@i+1)+"_huntingmin") + " - " + getd("." +(.@i+1)+"_huntingmax") + "] " + getd("." + (.@i+1) + "_huntingname$");

}

set .@selection,select(.@huntmenu$);

if(gettimetick(2) < getd(.@selection + "_hunting_delay")){

set .@time_left, getd(.@selection + "_hunting_delay")-gettimetick(2);

mes "[^FF7700Questboard^000000]";

if(.@time_left < 60) mes "You have to wait ^0000FF"+.@time_left+" seconds^000000 to do this quest again.";

if(.@time_left < 3600) mes "You have to wait ^0000FF"+.@time_left/60+" minutes^000000 to do this quest again.";

mes "You have to wait ^0000FF"+.@time_left/60/60+" hours^000000 to do this quest again.";

close;

}

mes "[^FF7700Questboard^000000]";

mes "^0000FF"+getd("." + .@selection + "_huntingname$")+"^000000";

mes "--------------------------------";

for( set .@j, 0; .@j < getarraysize(getd("."+ .@selection + "_huntingmob")); set .@j,.@j+2) {

mes "^FF0000"+strmobinfo(1,getd("."+.@selection+"_huntingmob["+.@j+"]"))+" - "+getd("."+.@selection+"_huntingmob["+(.@j+1)+"]")+" ea.^000000";

}

mes "--------------------------------";

mes "[Reward]";

mes "Item: ^0000FF"+((getd("." +.@selection+"_huntingprize"))?getitemname(getd("." +.@selection+"_huntingprize"))+" - "+getd("." +.@selection+"_huntingamount")+" ea.^000000":"Nothing^000000");

mes "Zeny: ^0000FF"+getd("." +.@selection+"_huntingzeny")+"^000000";

mes "Base EXP: ^0000FF"+getd("." +.@selection+"_huntingexp["+0+"]")+"^000000";

mes "Job EXP: ^0000FF"+getd("." +.@selection+"_huntingexp["+1+"]")+"^000000";

next;

if(select("Accept:Decline") == 2){

close;

}

if(BaseLevel >= getd("." +.@selection+"_huntingmin") && BaseLevel <= getd("." +.@selection+"_huntingmax"))

{

mes "[^FF7700Questboard^000000]";

mes "Quest accepted.";

set h_run, 1;

set currentquest$, .@selection;

close;

}

else

{

mes "[^FF7700Questboard^000000]";

mes "You don't have the required";

mes "level to do this quest.";

close;

}

case 3:

close;

}

L_checkitems:

for( set .@k,0; .@k < getarraysize(getd("."+currentquest$+"_collectionitem")); set .@k,.@k+2) {

if(countitem(getd("."+currentquest$+"_collectionitem["+.@k+"]"))>=getd("."+currentquest$+"_collectionitem["+(.@k+1)+"]")){

set .@checkitem,.@checkitem+2;

}

}

if(.@checkitem<getarraysize(getd("."+currentquest$+"_collectionitem"))){

mes "[^FF7700Questboard^000000]";

mes "You don't have everything.";

close;

}

for( set .@delcount,0; .@delcount < getarraysize(getd("."+currentquest$+"_collectionitem")); set .@delcount,.@delcount+2) {

delitem getd("."+currentquest$+"_collectionitem["+.@delcount+"]"),getd("."+currentquest$+"_collectionitem["+(.@delcount+1)+"]");

}

mes "[^FF7700Questboard^000000]";

mes "Congratulation! Here is your Reward.";

announce strcharinfo(0)+" has completed the "+getd("."+currentquest$+"_collectionname$")+" quest!",bc_all;

if(getd("." +currentquest$+"_collectionprize")!=0) getitem(getd("." +currentquest$+"_collectionprize"),getd("." +currentquest$+"_collectionamount"));

set Zeny,Zeny+getd("." +currentquest$+"_collectionzeny");

getexp getd("." +currentquest$+"_collectionexp["+0+"]"),getd("." +currentquest$+"_collectionexp["+1+"]");

setd(currentquest$ + "_collection_delay"),gettimetick(2)+.quest_delay;

set currentquest$, "";

set c_run, 0;

close;

L_checkmobs:

set .@goal, (getarraysize(getd("."+currentquest$+"_huntingmob"))/2);

for(set .@i, 1; .@i < getarraysize(getd("."+currentquest$+"_huntingmob")); set .@i,.@i+2){

set .@currentmob, getd("."+currentquest$+"_huntingmob["+(.@i-1)+"]");

if(getd(currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount")==getd("."+currentquest$+"_huntingmob["+.@i+"]")){

set .@checkmonster, .@checkmonster+1;

if(.@checkmonster==.@goal){

goto L_checkmobs2;

}

continue;

}

goto L_checkmobs2;

}

L_checkmobs2:

if(.@checkmonster<.@goal){

mes "[^FF7700Questboard^000000]";

mes "You didn't kill everything.";

close;

}

mes "[^FF7700Questboard^000000]";

mes "Congratulation! Here is your Reward.";

announce strcharinfo(0)+" has completed the "+getd("."+currentquest$+"_huntingname$")+" quest!",bc_all;

for(set .@x, 1; .@x < getarraysize(getd("."+currentquest$+"_huntingmob")); set .@x,.@x+2){

set .@currentmob, getd("."+currentquest$+"_huntingmob["+(.@x-1)+"]");

setd(currentquest$+"_"+.@currentmob+"_"+.@x+"_killcount", 0);

}

if(getd("." +currentquest$+"_huntingprize")!=0) getitem(getd("." +currentquest$+"_huntingprize"),getd("." +currentquest$+"_huntingamount"));

set Zeny, Zeny+getd("." +currentquest$+"_huntingzeny");

getexp getd("." +currentquest$+"_huntingexp["+0+"]"),getd("." +currentquest$+"_huntingexp["+1+"]");

setd(currentquest$ + "_hunting_delay"),gettimetick(2)+.quest_delay;

set currentquest$, "";

set h_run, 0;

close;

OnNPCKillEvent:

if(h_run!=1) end;

for(set .@i, 1; .@i < getarraysize(getd("."+currentquest$+"_huntingmob")); set .@i,.@i+2){

if(killedrid==getd("."+currentquest$+"_huntingmob["+(.@i-1)+"]")){

set .@currentmob, getd("."+currentquest$+"_huntingmob["+(.@i-1)+"]");

if(getd(currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount")>=getd("."+currentquest$+"_huntingmob["+.@i+"]")) end;

setd(currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount", getd(currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount")+1);

dispbottom getd("."+currentquest$+"_huntingname$")+": ["+strmobinfo(1,.@currentmob)+"] ("+ getd(currentquest$+"_"+.@currentmob+"_"+.@i+"_killcount")+"/"+getd("."+currentquest$+"_huntingmob["+.@i+"]")+")";

end;

}

continue;

}

end;

OnInit:

function AddCollection;

function AddHunting;

//Activate/Deactive quest categories here

set .collection, 1;

set .hunting, 1;

//Quest Delay (seconds)

//24 hours = 86400 seconds

set .quest_delay, 0;

//Checks if quests are loaded (prevents out of index)

if(.questsloaded==1) end;

set .questsloaded, 1;

//Add Collection Quests here

//AddCollection("<Quest Name>",<Min Lvl>,<Max Lvl>,<Reward|Item ID>,<Reward|Item Amount>,<Zeny Reward>,<Base EXP>,<Job EXP>,<Item ID>,<Item Amount>,...);

AddCollection("Angelic Set",99,255,30101,1,1000000,10000,5000,949,2500,916,2500,7063,1000,7938,500,6394,500,7115,500,7440,500,6393,500,7079,5);

AddCollection("Mystic Soul Set",99,255,30104,1,1000000,10000,5000,7255,2500,7849,2500,6087,500,6003,50,6001,50,6088,500,7307,500,7701,50,7089,5);

AddCollection("Absolute Set",99,255,30102,1,1000000,10000,5000,6269,500,7960,2500,1053,500,7210,2500,6072,2500,7297,50,7430,50,7023,500,6024,10);

AddCollection("The Scientist Set",99,255,30103,1,1000000,10000,5000,6278,2500,6274,2500,6541,500,6427,500,672,500,6386,500,7913,500,7871,500,7081,5);

AddCollection("Dark Shadow Set",99,255,30105,1,1000000,10000,5000,7524,2500,7886,2500,7345,500,7315,500,7157,500,6089,500,6091,50,18002,50,7837,5);

AddCollection("Mermaid Set",99,255,30106,1,1000000,10000,5000,1036,2500,7562,50,951,500,950,500,995,2500,954,500,926,50,722,50,7836,5);

AddCollection("Pierrot Set",99,255,30107,1,1000000,10000,5000,6270,2500,6511,2500,7328,500,7803,500,982,500,30011,500,7537,50,7284,50,7833,5);

AddCollection("Holy Guardian Set",99,255,30108,1,1000000,10000,5000,6187,2500,6274,2500,7914,500,6395,500,7796,50,7866,50,6152,500,7024,50,7074,5);

AddCollection("White Vestment Set",99,255,30109,1,1000000,10000,5000,6418,2500,7960,2500,6173,500,676,500,11524,500,7230,50,30012,50,7092,5);

AddCollection("Deadly Shadow Set",99,255,30110,1,1000000,10000,5000,6470,2500,7109,50,7449,500,7563,2500,631,500,678,500,7936,50,6306,50,7090,5);

AddCollection("Shadow of Darkness Set",99,255,30111,1,1000000,10000,5000,6100,2500,7798,2500,6027,500,641,500,12020,500,7511,500,7566,50,7340,50,7080,5);

AddCollection("Powerful Mantra Set",99,255,30112,1,1000000,10000,5000,7504,2500,1045,2500,7921,500,7057,500,7939,500,6219,500,30013,50,7305,50,7075,5);

AddCollection("Goblin Master Coat",99,255,25027,1,1000000,10000,5000,996,200,693,100,7265,300,1820,10,992,100);

AddCollection("Clear Cyclops",99,255,25028,1,1000000,10000,5000,7511,1000,7507,200,7111,100,7151,100,1048,200,7312,300);

//Add Hunting Quests here

//AddHunting("<Quest Name>",<Min Lvl>,<Max Lvl>,<Reward|Item ID>,<Reward|Item Amount>,<Zeny Reward>,<Base EXP>,<Job EXP>,<Monster ID>,<Monster Amount>,...);

AddHunting("Valkyrie Quest",150,255,24001,1,1000000,100000,50000,1751,1,1765,10);

AddHunting("Darker Than Black",150,255,25001,1,100000,10000,5000,1120,5,1179,50,1116,50,1869,50,1143,50);

AddHunting("Thanatos Slaves",150,255,25002,1,100000,10000,5000,1704,10,1705,10,1706,10,1707,10,1708,1);

AddHunting("Valkyrie Realm",150,255,25003,1,100000,10000,5000,1765,10,1751,1);

AddHunting("Mask of Despair",150,255,25004,1,100000,10000,5000,1130,50,1831,30,1833,30,1837,50,1832,1);

AddHunting("Glass of Despair",150,255,25005,1,100000,10000,5000,1130,50,1831,50,1833,50,1837,50,1832,1);

AddHunting("Scarf Of Nightmare",150,255,25006,1,100000,10000,5000,1867,50,1268,10,1507,50,1109,50);

AddHunting("Ring Of Night",150,255,25007,1,100000,10000,5000,1146,100,1203,10,1379,50);

AddHunting("Ring Of Sound Wave",150,255,25008,1,100000,10000,5000,1408,50,1267,100,1513,30,1299,1);

AddHunting("Sun Glass Of Hidden",150,255,25009,1,100000,10000,5000,1289,150);

AddHunting("Beats By Dr. Dre",150,255,25010,1,100000,10000,5000,1114,500);

AddHunting("Ring of Flower",150,255,25011,1,100000,10000,5000,1078,20,1079,20,1080,20,1082,20);

AddHunting("Spirit of the Sun",150,255,25012,1,100000,10000,5000,1837,500);

AddHunting("Winter Snow",150,255,25013,1,100000,10000,5000,1776,1000);

AddHunting("Soul of 2 Headed Dragon",150,255,25014,1,100000,10000,5000,1720,50);

AddHunting("Rune of Spells",150,255,25040,1,100000,10000,5000,1639,100,1059,5,1713,300);

AddHunting("Shinobi of Konoha",150,255,25042,1,100000,10000,5000,1068,100,1034,100,1785,10);

AddHunting("Hollowed Mask",150,255,25039,1,100000,10000,5000,1163,300,1159,5,1583,5);

end;

function AddCollection {

set .collectionquestcount,.collectionquestcount+1;

setd ("." +.collectionquestcount+"_collectionname$", getarg(0));

setd ("." +.collectionquestcount+"_collectionmin", getarg(1));

setd ("." +.collectionquestcount+"_collectionmax", getarg(2));

setd ("." +.collectionquestcount+"_collectionprize", getarg(3));

setd ("." +.collectionquestcount+"_collectionamount", getarg(4));

setd ("." +.collectionquestcount+"_collectionzeny", getarg(5));

set .@argcount, 6;

set .@size, getarraysize(getd("."+ .collectionquestcount + "_collectionexp"));

setd ("." +.collectionquestcount+"_collectionexp["+.@size+"]",getarg(.@argcount));

setd ("." +.collectionquestcount+"_collectionexp["+(.@size+1)+"]",getarg(.@argcount+1));

set .@argcount, .@argcount+2;

while(getarg(.@argcount,-1)!=-1 && getarg(.@argcount+1,-1)!=-1) {

set .@size, getarraysize(getd("."+ .collectionquestcount + "_collectionitem"));

setd ("."+.collectionquestcount+"_collectionitem["+.@size+"]",getarg(.@argcount));

setd ("."+.collectionquestcount+"_collectionitem["+(.@size+1)+"]",getarg(.@argcount+1));

set .@argcount,.@argcount+2;

}

return;

}

function AddHunting {

set .huntingquestcount,.huntingquestcount+1;

setd ("." +.huntingquestcount+"_huntingname$", getarg(0));

setd ("." +.huntingquestcount+"_huntingmin", getarg(1));

setd ("." +.huntingquestcount+"_huntingmax", getarg(2));

setd ("." +.huntingquestcount+"_huntingprize", getarg(3));

setd ("." +.huntingquestcount+"_huntingamount", getarg(4));

setd ("." +.huntingquestcount+"_huntingzeny", getarg(5));

set .@size, getarraysize(getd("."+ .huntingquestcount + "_huntingexp"));

set .@argcount, 6;

setd ("." +.huntingquestcount+"_huntingexp["+.@size+"]",getarg(.@argcount));

setd ("." +.huntingquestcount+"_huntingexp["+(.@size+1)+"]",getarg(.@argcount+1));

set .@argcount, .@argcount+2;

while(getarg(.@argcount,-1)!=-1 && getarg(.@argcount+1,-1)!=-1) {

set .@size, getarraysize(getd("."+ .huntingquestcount + "_huntingmob"));

setd ("."+.huntingquestcount+"_huntingmob["+.@size+"]",getarg(.@argcount));

setd ("."+.huntingquestcount+"_huntingmob["+(.@size+1)+"]",getarg(.@argcount+1));

set .@argcount, .@argcount+2;

}

return;

}

}


sky_quest,54,40,3 script Valkyrie Randgris 403,{

for ( .@lv = 1; .@lv < .max_lv; .@lv++ ) {

if ( countitem( getd( ".valkyrie_lv"+ .@lv ) ) ) {

if ( .@found )

next;

.@found++;

mes "You have ^0000FF"+ getitemname( getd( ".valkyrie_lv"+ .@lv ) ) +"^000000";

mes "Requirement ->";

.@size = getarraysize( getd( ".valkyrie_lv"+ .@lv ) );

.@complete = 0;

for ( .@i = 1; .@i < .@size; .@i += 2 ) {

if ( countitem( getd( ".valkyrie_lv"+ .@lv +"["+ .@i +"]" ) ) < getd( ".valkyrie_lv"+ .@lv +"["+( .@i +1 )+"]" ) )

.@color$ = "^FF0000";

else {

.@color$ = "^009900";

.@complete++;

}

mes .@color$ + getd( ".valkyrie_lv"+ .@lv +"["+( .@i +1 )+"]" )+"x "+ getitemname( getd( ".valkyrie_lv"+ .@lv +"["+ .@i +"]" ) );

}

if ( .@complete == .@size /2 ) {

mes " ";

mes "^000000your "+ getitemname( getd( ".valkyrie_lv"+ .@lv ) ) +" has upgrade into "+ getitemname( getd( ".valkyrie_lv"+( .@lv +1 ) ) );

for ( .@i = 1; .@i < .@size; .@i += 2 )

delitem getd( ".valkyrie_lv"+ .@lv +"["+ .@i +"]" ), getd( ".valkyrie_lv"+ .@lv +"["+( .@i +1 )+"]" );

delitem getd( ".valkyrie_lv"+ .@lv ), 1;

getitem getd( ".valkyrie_lv"+( .@lv +1 ) ), 1;

announce strcharinfo(0)+" has upgrade "+ getitemname( getd( ".valkyrie_lv"+ .@lv ) ) +" into "+ getitemname( getd( ".valkyrie_lv"+( .@lv +1 ) ) ),bc_all|bc_blue;

}

}

}

if ( !.@found )

mes "Im Sorry, you need Pure Valkyrie Helm";

//mes "you don't have Pure Valkyrie Helm in your inventory";

close;

OnInit:

setarray .valkyrie_lv1, 24001, 7090,5,7838,5,7835,5,7837,5,7836,5,7511,500,7563,1000;

setarray .valkyrie_lv2, 24002, 7090,10,7838,10,7835,10,7837,10,7836,10,7511,550,7563,1100;

setarray .valkyrie_lv3, 24003, 7090,15,7838,15,7835,15,7837,15,7836,15,7511,600,7563,1200;

setarray .valkyrie_lv4, 24004, 7090,20,7838,20,7835,20,7837,20,7836,20,7511,650,7563,1300;

setarray .valkyrie_lv5, 24005, 7090,25,7838,25,7835,25,7837,25,7836,25,7511,700,7563,1400;

setarray .valkyrie_lv6, 24006, 7090,30,7838,30,7835,30,7837,30,7836,30,7511,750,7563,1500;

setarray .valkyrie_lv7, 24007, 7090,35,7838,35,7835,35,7837,35,7836,35,7511,800,7563,1600;

setarray .valkyrie_lv8, 24008, 7090,40,7838,40,7835,40,7837,40,7836,40,7511,850,7563,1700;

setarray .valkyrie_lv9, 24009, 7090,45,7838,45,7835,45,7837,45,7836,45,7511,900,7563,1800;

setarray .valkyrie_lv10, 24010, 7090,50,7838,50,7835,50,7837,50,7836,50,7511,950,7563,1900;

setarray .valkyrie_lv11, 24011, 7090,60,7838,60,7835,60,7837,60,7836,60,7511,1000,7563,2000;

setarray .valkyrie_lv12, 24012;

.max_lv = 1;

while ( getd( ".valkyrie_lv"+ .max_lv ) ) .max_lv++;

.max_lv--;

end;

}

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  28
  • Topics Per Day:  0.01
  • Content Count:  79
  • Reputation:   1
  • Joined:  02/24/14
  • Last Seen:  

@Skorm thanks for the fast reply. i will test it as soon as i get back to the house. thank you again.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...