Jump to content
  • 0

Instance make server crash when generated


mjonrest

Question


  • Group:  Members
  • Topic Count:  11
  • Topics Per Day:  0.00
  • Content Count:  20
  • Reputation:   0
  • Joined:  08/16/13
  • Last Seen:  

Hello. im new scripter from indonesia. im trying to create my own instance. with learning from some source from rathena wiki and some from previous instance that i have..
 
but i met this condition.. 

 

here is my script description:

 

1. this instance is allowed to all player but, if the player is member of  guild that conqueror "prtg_cas03" will have halfed instance timer ( normal 12 hours, guild 6 hours)

 

2. the error begin when i try to generate the instance. 

 

its causing error like this 

errorinstance.jpg



alberta,246,97,4	script	Old SailorMan	55,{	
set .@Castle$, "prtg_cas03";

	mes "[Custom Instance]";

	mes "Would you like to warp to the special guild Instance?";

	mes "The conquerors of "+getcastlename(.@Castle$)+" having a half instance time (6 hours), though.";

    next;
	mes "For This, your guild will have a benefit!";
	mes "your instance delay time will be cut half!!";
	next;
    if(select("Warp me!:Cancel")==2) close;

    mes "[Custom Instance]";

    set .@i, getcastledata(.@Castle$,1);

    if (getcharid(2) == .@i) {
	set .@party_idkraken,getcharid(1);
	set .@p_name$,getpartyname(.@party_idkraken);
	set .@md_name$,"Crazy Kraken";

	set .@kraken_timer,checkquest(50000,PLAYTIME); // 1 week
	
	dispbottom "50000 = " + .@kraken_timer;
	
	if (!instance_check_party(.@party_idkraken,1)) {
		mes "Make or join a party with more than 1 member and try again.";
		close;
	}
	if (.@kraken_timer == -1) {
		if (getcharid(0) == getpartyleader(.@party_idkraken,2)) {
			mes "Confirmed the party has been made. Would you like to reserve entrance to the Crazy Kraken?";
			next;
			switch(select("Generate dungeon "+.@md_name$+":Enter the dungeon:Cancel")) {
			case 1:
				if (instance_create(.@md_name$) < 0) {
					mes "Party Name: "+.@p_name$;
					mes "Party Leader: "+strcharinfo(0);
					mes "^0000ff"+.@md_name$+" ^000000- Reservation Failed!";
					close;
				}
				mes "^0000ff"+.@md_name$+"^000000 - Try to reserve";
				mes "After making a reservation, you have to talk to NPC behind and select the menu 'Enter the Dungeon' to enter the dungeon.";
				close;
			case 2:
				callsub L_EnterkrakenG,0,1;
			case 3:
				close;
			}
		}
		switch(select("Enter the "+.@md_name$+":Cancel")) {
		case 1:
			callsub L_EnterkrakenG,1,1;
		case 2:
			end;
		}
	} else if ((.@kraken_timer == 0)) {

		set .@dun_lim_time,kraken_timer+21600; // 1 week
		//set .@dun_lim_time2,bios_timer+14400; // 4 hours
		set .@dun_cur_time,gettimetick(2);
		set .@dun_ent_t,(.@dun_lim_time - .@dun_cur_time);
		set .@dun_h,(.@dun_ent_t / 3600);
		set .@dun_m,(.@dun_ent_t - (.@dun_h * 3600)) / 60;
		set .@dun_s,.@dun_ent_t - ((.@dun_h * 3600) + (.@dun_m * 60));

		mes "Due to the tower's aftereffects, you cannot enter the dungeon right now, " + .@dun_h + "hours " + .@dun_m + "minutes " + .@dun_s + "seconds left to enter the next dungeon.";
		close;
		end;
	} else {
		set kraken_timer,0;
		erasequest 50000;
		//erasequest 3136;
		mes "^0000ffThe records and after effects related to the Crazy Kraken have been removed. You can generate and enter the Crazy Kraken again.^000000";
		close;
	}

L_EnterkrakenG:
	switch(instance_enter("Crazy Kraken")) {
	case 3:
		mes "An unknown error has occurred.";
		close;
	case 2:
		mes "The memorial dungeon Crazy Kraken does not exist.";
		mes "The party leader did not generate the dungeon yet.";
		close;
	case 1:
		mes "You can enter the dungeon after making the party.";
		close;
	case 0:
		mapannounce "e_tower", strcharinfo(0) +" of the party, "+ getpartyname( getcharid(1) ) +", is entering the dungeon, Crazy Kraken.",bc_map,"0x00ff99",FW_NORMAL,12;
		if (getarg(1)) {
			set kraken_timer,gettimetick(2);
			//setquest 15005;
			//setquest 3136;
		}
		//warp "1@tower",52,354;
		if (getarg(0) == 0) close;
		else end;
	}




}

	set .@party_idkraken,getcharid(1);
	set .@p_name$,getpartyname(.@party_idkraken);
	set .@md_name$,"Crazy Kraken";

	set .@kraken_timer,checkquest(50000,PLAYTIME); // 1 week
	
	dispbottom "50000 = " + .@kraken_timer;
	
	if (!instance_check_party(.@party_idkraken,1)) {
		mes "Make or join a party with more than 1 member and try again.";
		close;
	}
	if (.@kraken_timer == -1) {
		if (getcharid(0) == getpartyleader(.@party_idkraken,2)) {
			mes "Confirmed the party has been made. Would you like to reserve entrance to the Crazy Kraken?";
			next;
			switch(select("Generate dungeon "+.@md_name$+":Enter the dungeon:Cancel")) {
			case 1:
				if (instance_create(.@md_name$) < 0) {
					mes "Party Name: "+.@p_name$;
					mes "Party Leader: "+strcharinfo(0);
					mes "^0000ff"+.@md_name$+" ^000000- Reservation Failed!";
					close;
				}
				mes "^0000ff"+.@md_name$+"^000000 - Try to reserve";
				mes "After making a reservation, you have to talk to NPC behind and select the menu 'Enter the Dungeon' to enter the dungeon.";
				close;
			case 2:
				callsub L_Enterkraken,0,1;
			case 3:
				close;
			}
		}
		switch(select("Enter the "+.@md_name$+":Cancel")) {
		case 1:
			callsub L_Enterkraken,1,1;
		case 2:
			end;
		}
	} else if ((.@kraken_timer == 0)) {

		set .@dun_lim_time,kraken_timer+43200; // 1 week
		//set .@dun_lim_time2,bios_timer+14400; // 4 hours
		set .@dun_cur_time,gettimetick(2);
		set .@dun_ent_t,(.@dun_lim_time - .@dun_cur_time);
		set .@dun_h,(.@dun_ent_t / 3600);
		set .@dun_m,(.@dun_ent_t - (.@dun_h * 3600)) / 60;
		set .@dun_s,.@dun_ent_t - ((.@dun_h * 3600) + (.@dun_m * 60));

		mes "Due to the tower's aftereffects, you cannot enter the dungeon right now, " + .@dun_h + "hours " + .@dun_m + "minutes " + .@dun_s + "seconds left to enter the next dungeon.";
		close;
		end;
	} else {
		set kraken_timer,0;
		erasequest 50000;
		//erasequest 3136;
		mes "^0000ffThe records and after effects related to the Crazy Kraken have been removed. You can generate and enter the Crazy Kraken again.^000000";
		close;
	}

L_Enterkraken:
	switch(instance_enter("Crazy Kraken")) {
	case 3:
		mes "An unknown error has occurred.";
		close;
	case 2:
		mes "The memorial dungeon Crazy Kraken does not exist.";
		mes "The party leader did not generate the dungeon yet.";
		close;
	case 1:
		mes "You can enter the dungeon after making the party.";
		close;
	case 0:
		mapannounce "e_tower", strcharinfo(0) +" of the party, "+ getpartyname( getcharid(1) ) +", is entering the dungeon, Crazy Kraken.",bc_map,"0x00ff99",FW_NORMAL,12;
		if (getarg(1)) {
			set kraken_timer,gettimetick(2);
			//setquest 15005;
			//setquest 3136;
		}
		//warp "1@tower",52,354;
		if (getarg(0) == 0) close;
		else end;
	}
}



int_land,56,69,4	script	Anes	581,{
	if (getcharid(0) == getpartyleader(getcharid(1),2)) {
		mes "why are you here kid?";
		mes "dont you know that monster around here";
		close;
	npctalk "Anes: I dont really care if you get killed here";
	sleep 1000;
	npctalk "Anes: but you have to get out of here";
	sleep 2000;
	enablenpc "Droid#1";
	sleep 3000;
	npctalk "Anes: I dont care!!!";
	disablenpc strnpcinfo(0);
	end;
}
	mes "...........";
	close;
}

int_land,57,71,4	script	Droid#1	571,{
	npctalk "Droid : Dont blame new player here";
	sleep 1000;
	npctalk	"Droid : you dont know their strength, dont you?";
	sleep 3000;
	disablenpc strnpcinfo(0);
	mapwarp "int_land","int_land",98,63;
	enablenpc "Droids#2";
	end;
}

int_land,100,67,4	script	Droids#2	571,{
	npctalk "Droid : if you really want to meet that crazy monster";
	sleep 1000;
	npctalk	"Droid : We will really appreciate that";
	sleep 1000;
	npctalk "Droid : But you have to really ready for this";
	sleep 1000;
	npctalk "Droid : He is really strong even 10 people cant kill him";
	sleep 1000;
	npctalk "Droid : Well, ready or not!!";
	sleep 1000;
	npctalk "Droid : good luck inside, i will keep look behind you";
	sleep 1000;	
	donpcevent "kraken1spawn::Onspawnkraken1";
	mapwarp "int_land","int_land01",56,63;
	enablenpc "Anes";
	enablenpc "Droid#1";
	end;
}

int_land01,0,0,0	script	kraken1spawn	-1,{		
Onspawnkraken1:
	monster "int_land01",0,0,"Racist Skeleton",3721,10,strnpcinfo(0)+"::Onkraken1dead";
	monster "int_land01",0,0,"Racist Skeleton",3721,10,strnpcinfo(0)+"::Onkraken1dead";
	monster "int_land01",0,0,"Racist Skeleton",3721,10,strnpcinfo(0)+"::Onkraken1dead";
	end;
Onkraken1dead:
if (mobcount("int_land01","kraken1spawn::Onspawnkraken1") == 0){
	enablenpc "Droid#3";
	mapwarp "int_land01","int_land01",100,67;
	end;}
else if (mobcount("int_land01","kraken1spawn::Onspawnkraken1") == 20){
	announce "[ Droid] : Kill every single monster you meet... YOU HAVE TO DEFEAT THEM ALL!!",bc_map;
	end;}
		
}
int_land01,100,67,4	script	Droid#3	571,{
	sleep 1000;
	npctalk "Droid : Great! you have defeat them all";
	sleep 1000;
	npctalk "Droid : from now, your enemy will be stronger than this";
	sleep 1000;
	npctalk "Droid : Keep your spirit and conquer this island";
	sleep 1000;
	donpcevent "kraken2spawn::Onspawnkraken2";
	mapwarp "int_land01","int_land02",56,63;
	end;
}

int_land02,0,0,0	script	kraken2spawn	-1,{		
Onspawnkraken2:
	monster "int_land02",0,0,"Racist Skeleton",3721,10,strnpcinfo(0)+"::Onkraken2dead";
	monster "int_land02",0,0,"Hollow Seiren",3723,10,strnpcinfo(0)+"::Onkraken2dead";
	monster "int_land02",0,0,"Racist Skeleton",3721,10,strnpcinfo(0)+"::Onkraken2dead";
	end;
Onkraken2dead:
if (mobcount("int_land02","kraken2spawn::Onspawnkraken2") == 0){
	donpcevent "kraken2spawn::Onkrakenboss1";
	end;}
else if (mobcount("int_land02","kraken2spawn::Onspawnkraken2") == 20){
	announce "[ Droid] : Kill every single monster you meet... YOU HAVE TO DEFEAT THEM ALL!!",bc_map;
	end;}

Onkrakenboss1:
	monster "int_land02",0,0,"Mutated Vadon",3724,1,strnpcinfo(0)+"::Onkrakenbossdead1";
	end;

Onkrakenbossdead1:
	mapwarp "int_land02","int_land02",100,67;
	enablenpc "Droid#4";
	end;
}
int_land02,100,67,4	script	Droid#4	571,{
	sleep 1000;
	npctalk "Droid : Awesome.. you just kill Kraken Little Son";
	sleep 1000;
	npctalk "Droid : Now im wont hesitated anymore";
	sleep 1000;
	npctalk "Droid : you are closer to Kraken Now";
	sleep 1000;
	donpcevent "kraken3spawn::Onspawnkraken3";
	mapwarp "int_land02","int_land03",56,63;
}

int_land03,0,0,0	script	kraken3spawn	-1,{		
Onspawnkraken3:
	monster "int_land02",0,0,"Racist Skeleton",3721,10,strnpcinfo(0)+"::Onkraken3dead";
	monster "int_land02",0,0,"Hollow Seiren",3723,20,strnpcinfo(0)+"::Onkraken3dead";
	monster "int_land02",0,0,"Racist Skeleton",3721,20,strnpcinfo(0)+"::Onkraken3dead";
	end;
Onkraken3dead:
if (mobcount("int_land03","kraken3spawn::Onspawnkraken3") == 0){
	donpcevent "kraken3spawn::Onkrakenboss2";
	end;}
else if (mobcount("int_land03","kraken3spawn::Onspawnkraken3") == 20){
	announce "[ Droid] : Kill every single monster you meet... YOU HAVE TO DEFEAT THEM ALL!!",bc_map;
	end;}

Onkrakenboss2:
	monster "int_land03",0,0,"Elder Octopus",3722,1,strnpcinfo(0)+"::Onkrakenbossdead2";
	end;

Onkrakenbossdead1:
	mapwarp "int_land03","int_land03",100,67;
	enablenpc "Droid#5";
	end;
}
int_land03,100,67,4	script	Droid#5	571,{
	sleep 1000;
	npctalk "Droid : Great Job Guys!";
	sleep 1000;
	npctalk "Droid : You will be warp closer to Kraken Temple now";
	sleep 1000;
	npctalk "Droid : fasten your seatbelts!!";
	sleep 1000;
	enablenpc "Droid#6";
	mapwarp "int_land03","int_land04",56,63;
	end;
}

int_land04,57,71,4	script	Droid#6	571,{
	sleep 1000;
	npctalk "Droid : take a breath";
	sleep 1000;
	npctalk "Droid : you will be warp to kraken temple in 1 minutes";
	sleep 50000;
	npctalk "Droid : are you ready?!";
	sleep 10000;
	npctalk "Droid : Here we go!!!!";
	sleep 1000;
	hideonnpc strnpcinfo(0);
	enablenpc "krakenspawnboss";
	mapwarp "int_land04","int_land04",56,63;
	end;
}


int_land04,0,0,0	script	krakenspawnboss	-1,{
	sleep 1000;
	announce "[ Crazy Kraken ] : Grrr!!!!~",bc_map;
	sleep 2000;
	announce "[ Crazy Kraken ] : Who dare hurt my soldier and MY KIDS?",bc_map;
	sleep 2000;
	announce "[ Crazy Kraken ] : I dont care who you are!!! come defeat Me!!!",bc_map;
	Sleep 2000;
	donpcevent strnpcinfo(0)+"::Onkrakenboss3";
	end;	

Onkrakenboss3:
	monster "int_land04",56,63,"Crazy Kraken",3725,1,strnpcinfo(0)+"::Onkrakenbossdead3";
	end;

Onkrakenbossdead3:
	mapwarp "int_land04","int_land04",100,67;
	enablenpc "Droid#7";
	end;
}

int_land04,100,67,4	script	Droid#7	571,{
	if (getcharid(0) == getpartyleader(getcharid(1),2)) {
		mes "Well done team. Great Job";
		mes "As you saving my home from this disaster";
		mes "I will reward you 1 Hero Prize and 1 Mystical Album";
	next;
		mes "Good luck for your journey";
		close;
	mapwarp "int_land04","SavePoint",0,0;
	disablenpc "Droid#1";
	disablenpc "Droids#2";
	disablenpc "Droid#3";
	disablenpc "Droid#4";
	disablenpc "Droid#5";
	disablenpc "Droid#6";
	disablenpc "Droid#7";
	disablenpc "krakenspawnboss";
	end;
	}
	mes "Let you party leader talk to me";
	close;
}

	

if someone can help me.. i will be so glad and thankful

 

 

Link to comment
Share on other sites

0 answers to this question

Recommended Posts

There have been no answers to this question yet

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...