Jump to content
  • 0

Warp Rotation


Vyserion

Question


  • Group:  Members
  • Topic Count:  15
  • Topics Per Day:  0.01
  • Content Count:  21
  • Reputation:   0
  • Joined:  06/25/20
  • Last Seen:  

Hello, there!

  I have an idea of a town/dungeon warps rotation on a Warper NPC that chooses a few destinations from a random list that change everyday. I've been trying to do this will simple script but I'm not able to.

Does anyone has the desire and time to do it for me? I appreciate it.

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

  • 0

  • Group:  Forum Moderator
  • Topic Count:  93
  • Topics Per Day:  0.02
  • Content Count:  10013
  • Reputation:   2346
  • Joined:  10/28/11
  • Last Seen:  

prontera,155,181,5	script	Sample	45,2,2,{
	end;
	
	function	func_AddWarp	{
		.@map$ = getarg(0, "");
		.@x = getarg(1, 0);
		.@y = getarg(2, 0);
		
		if (getmapusers(.@map$) >= 0) {
			.map$[.map_size] = .@map$;
			.x[.map_size] = .@x;
			.y[.map_size] = .@y;
			.map_size++;
		}
		return;
	}
	
	OnTouch:
		warp .map$[.index], .x[.index], .y[.index];
		end;
		
	OnInit:
		// func_AddWarp("map", x, y);
		func_AddWarp("prontera", 155, 181);
		func_AddWarp("payon", 0, 0);
		func_AddWarp("izlude", 100, 100);
		func_AddWarp("prt_fild01", 120, 60);
	OnHour00:
		.index = rand(.map_size);
		end;
}

 

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