Aura.Channel.Network.Sending.Send.EnterDynamicRegion C# (CSharp) Method

EnterDynamicRegion() public static method

Sends EnterDynamicRegion to creature's client.
public static EnterDynamicRegion ( Creature creature, int warpFromRegionId, Region warpToRegion, int x, int y ) : void
creature Creature
warpFromRegionId int
warpToRegion Region
x int
y int
return void
		public static void EnterDynamicRegion(Creature creature, int warpFromRegionId, Region warpToRegion, int x, int y)
		{
			var warpTo = warpToRegion as DynamicRegion;
			if (warpTo == null)
				throw new ArgumentException("EnterDynamicRegion requires a dynamic region.");

			var pos = creature.GetPosition();

			var packet = new Packet(Op.EnterDynamicRegion, MabiId.Broadcast);
			packet.PutLong(creature.EntityId);
			packet.PutInt(warpFromRegionId); // creature's current region or 0?

			packet.PutInt(warpToRegion.Id);
			packet.PutString(warpToRegion.Name); // dynamic region name
			packet.PutUInt(0x80000000); // bitmask? (|1 = time difference?)
			packet.PutInt(warpTo.BaseId);
			packet.PutString(warpTo.BaseName);
			packet.PutInt(200); // 100|200 (100 changes the lighting?)
			packet.PutByte(0); // 1 = next is empty?
			packet.PutString("data/world/{0}/{1}", warpTo.BaseName, warpTo.Variation);

			packet.PutByte(0);
			//if (^ true)
			//{
			//	pp.PutByte(1);
			//	pp.PutInt(3100); // some region id?
			//}
			packet.PutInt(x); // target x pos
			packet.PutInt(y); // target y pos

			creature.Client.Send(packet);
		}
Send