From 417ea24b833f470042c8e767cea7ec028758ab3e Mon Sep 17 00:00:00 2001 From: gareth Date: Thu, 1 Mar 2007 15:15:45 +0000 Subject: [PATCH] Lovely lovely flat island :) --- src/world/Avatar.cs | 8 ++++---- src/world/World.cs | 14 +++++++------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/world/Avatar.cs b/src/world/Avatar.cs index b81fd0bcf3..bcf79a88ca 100644 --- a/src/world/Avatar.cs +++ b/src/world/Avatar.cs @@ -39,7 +39,7 @@ namespace OpenSim.world pos.X = 100f; objdata.ID = 8880000; objdata.NameValue = enc.GetBytes("FirstName STRING RW SV Test \nLastName STRING RW SV User \0"); - libsecondlife.LLVector3 pos2 = new LLVector3(13.981f,100.0f,20.0f); + libsecondlife.LLVector3 pos2 = new LLVector3(100f,100f,23f); //objdata.FullID=user.AgentID; byte[] pb = pos.GetBytes(); Array.Copy(pb, 0, objdata.ObjectData, 16, pb.Length); @@ -55,8 +55,8 @@ namespace OpenSim.world mov.AgentData.AgentID = this.ControllingClient.AgentID; mov.Data.RegionHandle = OpenSim_Main.cfg.RegionHandle; // TODO - dynamicalise this stuff - mov.Data.Timestamp = 1169838966; - mov.Data.Position = new LLVector3(100f, 100f, 35f); + mov.Data.Timestamp = 1172750370; + mov.Data.Position = new LLVector3(100f, 100f, 23f); mov.Data.LookAt = new LLVector3(0.99f, 0.042f, 0); Console.WriteLine("Sending AgentMovementComplete packet"); @@ -80,7 +80,7 @@ namespace OpenSim.world objupdate.ObjectData[0].FullID = ControllingClient.AgentID; objupdate.ObjectData[0].NameValue = _enc.GetBytes("FirstName STRING RW SV " + firstname + "\nLastName STRING RW SV " + lastname + " \0"); - libsecondlife.LLVector3 pos2 = new LLVector3(100f, 100.0f, 22.0f); + libsecondlife.LLVector3 pos2 = new LLVector3(100f, 100.0f, 23.0f); byte[] pb = pos2.GetBytes(); diff --git a/src/world/World.cs b/src/world/World.cs index 854e8fec14..ebbd61ee1d 100644 --- a/src/world/World.cs +++ b/src/world/World.cs @@ -14,19 +14,19 @@ namespace OpenSim.world public TerrainDecode terrainengine = new TerrainDecode(); public uint _localNumber=0; + private Random Rand = new Random(); + public World() { Console.WriteLine("World.cs - creating new entitities instance"); Entities = new Dictionary(); - // We need a 16x16 array of 16m2 surface patches for a 256m2 sim Console.WriteLine("World.cs - creating LandMap"); terrainengine = new TerrainDecode(); LandMap = new float[65536]; - for(int i =0; i < 65536; i++) { - LandMap[i] = 40f; - } - + for(int i =0; i < 65536; i++) { + LandMap[i] = 21.4989f; + } Console.WriteLine("World.cs - Creating script engine instance"); // Initialise this only after the world has loaded @@ -42,8 +42,8 @@ namespace OpenSim.world } public void SendLayerData(OpenSimClient RemoteClient) { - for(int i=1; i<16; i++) { - Packet layerpack=this.terrainengine.CreateLayerPacket(LandMap, i,1,1,16); + for(int x=0; x<16; x=x+4) for(int y=0; y<16; y++){ + Packet layerpack=this.terrainengine.CreateLayerPacket(LandMap, x,y,x+4,y+1); RemoteClient.OutPacket(layerpack); } }