Jump to content
  • 0

[Instance issue] Monster not respawn when killed


edwardluciano

Question


  • Group:  Members
  • Topic Count:  15
  • Topics Per Day:  0.01
  • Content Count:  29
  • Reputation:   2
  • Joined:  04/21/16
  • Last Seen:  

i tried to convert abyss dungeon to instance now i can spawn when instance create but when player kill monster monster note respawn

Lasted code  i tried to use OnNPCKillEvent 
Mapserver Msg when kill monster :
[Debug]: (map_mapname2mapid) mapindex_name2id: Map "" not found in index list!
[Debug]: (map_mapname2mapid) mapindex_name2id: Map "" not found in index list!
[Debug]: (map_mapname2mapid) mapindex_name2id: Map "" not found in index list!

1@abyss_03,0,0,0	script	AbyssLake	HIDDEN_WARP_NPC,{

OnInstanceInit:
	
	set .@map$, instance_mapname("1@abyss_03");
	//set .@label$, instance_npcname(strnpcinfo(0))+"::OnMobDead";
			
	monster .@map$,0,0,"Acidus",1713,60,strnpcinfo(0)+"::OnMobDead";
	monster .@map$,0,0,"Dragon Egg",1721,10,strnpcinfo(0)+"::OnMobDead";
	monster .@map$,0,0,"Mimic",1191,10,strnpcinfo(0)+"::OnMobDead";
	monster .@map$,0,0,"Acidus",1716,10,strnpcinfo(0)+"::OnMobDead";
	monster .@map$,0,0,"Ancient Mimic",1699,10,strnpcinfo(0)+"::OnMobDead";
	monster .@map$,0,0,"Ferus",1714,10,strnpcinfo(0)+"::OnMobDead";
	monster .@map$,0,0,"Ferus",1717,10,strnpcinfo(0)+"::OnMobDead";
	monster .@map$,0,0,"Hydrolancer",1720,3,strnpcinfo(0)+"::OnMobDead";
end;

OnMobDead:
	//set .@map$, instance_mapname("1@abyss_03");
	setarray .Mob_id[0]
	,1713
	,1721
	,1191
	,1716
	,1699
	,1714
	,1717
	,1720;
	
	for(.@i = 0; .@i < getarraysize(.Mob_id); .@i++)
	{
		if (killedrid == .Mob_id[.@i])
		{
			monster instance_mapname("1@abyss_03"),0,0,"--ja--",.Mob_id[.@i],1,strnpcinfo(0)+"::OnMobDead";
		}
	}
end;

}

 

Edited by edwardluciano
Link to comment
Share on other sites

4 answers to this question

Recommended Posts

  • 1

  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.01
  • Content Count:  241
  • Reputation:   18
  • Joined:  06/04/14
  • Last Seen:  

Link to comment
Share on other sites

  • 1

  • Group:  Members
  • Topic Count:  6
  • Topics Per Day:  0.00
  • Content Count:  91
  • Reputation:   22
  • Joined:  10/24/14
  • Last Seen:  

Hey,

Use instance commands when targeting instance NPC's, like the ones you commented out.

instance_npcname(strnpcinfo(0))+"::OnMobDead"

 

  • Upvote 1
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  15
  • Topics Per Day:  0.01
  • Content Count:  29
  • Reputation:   2
  • Joined:  04/21/16
  • Last Seen:  

Thankyou 

 

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  15
  • Topics Per Day:  0.01
  • Content Count:  29
  • Reputation:   2
  • Joined:  04/21/16
  • Last Seen:  

1@abyss_03,0,0,0	script	AbyssLake	HIDDEN_WARP_NPC,{

OnInstanceInit:
	set .map$, instance_mapname("1@abyss_03");
	//set .@label$, instance_npcname(strnpcinfo(0))+"::OnMobDead";
	setarray .Mob_id[0]
	,1713
	,1721
	,1191
	,1716
	,1699
	,1714
	,1717
	,1720;
	
	monster .map$,0,0,"Acidus",1713,70,instance_npcname(strnpcinfo(0))+"::OnMobDead";
	monster .map$,0,0,"Dragon Egg",1721,20,instance_npcname(strnpcinfo(0))+"::OnMobDead";
	monster .map$,0,0,"Mimic",1191,20,instance_npcname(strnpcinfo(0))+"::OnMobDead";
	monster .map$,0,0,"Acidus",1716,20,instance_npcname(strnpcinfo(0))+"::OnMobDead";
	monster .map$,0,0,"Ancient Mimic",1699,20,instance_npcname(strnpcinfo(0))+"::OnMobDead";
	monster .map$,0,0,"Ferus",1714,20,instance_npcname(strnpcinfo(0))+"::OnMobDead";
	monster .map$,0,0,"Ferus",1717,20,instance_npcname(strnpcinfo(0))+"::OnMobDead";
	monster .map$,0,0,"Hydrolancer",1720,13,instance_npcname(strnpcinfo(0))+"::OnMobDead";
end;

OnMobDead:
	for(.@i = 0; .@i < getarraysize(.Mob_id); .@i++)
	{
		if (killedrid == .Mob_id[.@i])
		{
			monster .map$,0,0,"--ja--",.Mob_id[.@i],1,instance_npcname(strnpcinfo(0))+"::OnMobDead";
		}
	}
end;

}

Now it ok but when reach 20 minute monster not spawn again


Msg:
[Error]: npc_event: event not found [dup_13_110044598::OnMobDead]

Edited by edwardluciano
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...