Jump to content
  • 0

Monster spawn in all maps


Question

Posted

Hello everyone! I need help with making a script of a monster that can spawn it in all maps (in the interval of 1 hour when is killed). Is that possible? Thanks!

6 answers to this question

Recommended Posts

Posted

Hello everyone! I need help with making a script of a monster that can spawn it in all maps (in the interval of 1 hour when is killed). Is that possible? Thanks!

 

You could start with the following :

-	script	ANY_MAP_SPAWNER	-1,{
OnInit:
	.mobId = 1002;
	setarray .maps$,"prontera","izlude";
	donpcevent "ANY_MAP_SPAWNER::OnAddMob";
	end;
OnAddMob:
	monster .maps$[rand(0,getarraysize(.maps$) - 1)],0,0,"--ja--",.mobId,1,"ANY_MAP_SPAWNER::OnMyMobDead";
	announce "A new mob has spawned!",0;
	end;
OnMyMobDead:
	initnpctimer;
	announce "The mob has been killed by "+strcharinfo(0)+", wait a hour for the respawn.",0;
	end;
OnTimer3600000:
	stopnpctimer;
	donpcevent "ANY_MAP_SPAWNER::OnAddMob";
	end;
}
  • Upvote 1
Posted

Hey guys, about this script, is there anyway I can make it spawn in all maps automatically? Instead of putting all maps manually in the array...

 

Thanks

Posted

Hey guys, about this script, is there anyway I can make it spawn in all maps automatically? Instead of putting all maps manually in the array...

 

Thanks

 

just add timer in script Onclock or Onminute

Posted

 

Hey guys, about this script, is there anyway I can make it spawn in all maps automatically? Instead of putting all maps manually in the array...

 

Thanks

 

just add timer in script Onclock or Onminute

 

 

Sorry, i'm not good with script... How's that supposed to make it spawn in all maps loaded in the server?

Posted

 

 

Hey guys, about this script, is there anyway I can make it spawn in all maps automatically? Instead of putting all maps manually in the array...

 

Thanks

 

just add timer in script Onclock or Onminute

 

 

Sorry, i'm not good with script... How's that supposed to make it spawn in all maps loaded in the server?

 

 

to do this i believe your going to have to add in every map in multiple arrays each array can support up to 128 vars and there are about 750 maps by default,

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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...