diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/Scene.cs | 20 | ||||
-rw-r--r-- | OpenSim/Region/Environment/Scenes/SceneObject.cs | 11 |
2 files changed, 15 insertions, 16 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs index 417f817..c8714ae 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.cs | |||
@@ -355,7 +355,7 @@ namespace OpenSim.Region.Environment.Scenes | |||
355 | /// <summary> | 355 | /// <summary> |
356 | /// | 356 | /// |
357 | /// </summary> | 357 | /// </summary> |
358 | private void CreateTerrainTexture() | 358 | public void CreateTerrainTexture() |
359 | { | 359 | { |
360 | //create a texture asset of the terrain | 360 | //create a texture asset of the terrain |
361 | byte[] data = this.Terrain.exportJpegImage("defaultstripe.png"); | 361 | byte[] data = this.Terrain.exportJpegImage("defaultstripe.png"); |
@@ -446,6 +446,15 @@ namespace OpenSim.Region.Environment.Scenes | |||
446 | /// <param name="child"></param> | 446 | /// <param name="child"></param> |
447 | public override void AddNewClient(IClientAPI client, bool child) | 447 | public override void AddNewClient(IClientAPI client, bool child) |
448 | { | 448 | { |
449 | SubscribeToClientEvents(client); | ||
450 | this.estateManager.sendRegionHandshake(client); | ||
451 | CreateAndAddScenePresence(client); | ||
452 | this.parcelManager.sendParcelOverlay(client); | ||
453 | |||
454 | } | ||
455 | |||
456 | protected override void SubscribeToClientEvents(IClientAPI client) | ||
457 | { | ||
449 | client.OnRegionHandShakeReply += this.SendLayerData; | 458 | client.OnRegionHandShakeReply += this.SendLayerData; |
450 | //remoteClient.OnRequestWearables += new GenericCall(this.GetInitialPrims); | 459 | //remoteClient.OnRequestWearables += new GenericCall(this.GetInitialPrims); |
451 | client.OnChatFromViewer += this.SimChat; | 460 | client.OnChatFromViewer += this.SimChat; |
@@ -475,14 +484,6 @@ namespace OpenSim.Region.Environment.Scenes | |||
475 | client.OnParcelJoinRequest += new ParcelJoinRequest(parcelManager.handleParcelJoinRequest); | 484 | client.OnParcelJoinRequest += new ParcelJoinRequest(parcelManager.handleParcelJoinRequest); |
476 | client.OnParcelPropertiesUpdateRequest += new ParcelPropertiesUpdateRequest(parcelManager.handleParcelPropertiesUpdateRequest); | 485 | client.OnParcelPropertiesUpdateRequest += new ParcelPropertiesUpdateRequest(parcelManager.handleParcelPropertiesUpdateRequest); |
477 | client.OnEstateOwnerMessage += new EstateOwnerMessageRequest(estateManager.handleEstateOwnerMessage); | 486 | client.OnEstateOwnerMessage += new EstateOwnerMessageRequest(estateManager.handleEstateOwnerMessage); |
478 | |||
479 | |||
480 | this.estateManager.sendRegionHandshake(client); | ||
481 | CreateAndAddScenePresence(client); | ||
482 | |||
483 | this.parcelManager.sendParcelOverlay(client); | ||
484 | |||
485 | return; | ||
486 | } | 487 | } |
487 | 488 | ||
488 | protected void CreateAndAddScenePresence(IClientAPI client) | 489 | protected void CreateAndAddScenePresence(IClientAPI client) |
@@ -772,7 +773,6 @@ namespace OpenSim.Region.Environment.Scenes | |||
772 | remoteClient.SendRegionTeleport(regionHandle, 13, reg.ExternalEndPoint, 4, (1 << 4)); | 773 | remoteClient.SendRegionTeleport(regionHandle, 13, reg.ExternalEndPoint, 4, (1 << 4)); |
773 | 774 | ||
774 | } | 775 | } |
775 | //remoteClient.SendTeleportCancel(); | ||
776 | } | 776 | } |
777 | } | 777 | } |
778 | 778 | ||
diff --git a/OpenSim/Region/Environment/Scenes/SceneObject.cs b/OpenSim/Region/Environment/Scenes/SceneObject.cs index c586e9b..e979186 100644 --- a/OpenSim/Region/Environment/Scenes/SceneObject.cs +++ b/OpenSim/Region/Environment/Scenes/SceneObject.cs | |||
@@ -115,13 +115,12 @@ namespace OpenSim.Region.Environment.Scenes | |||
115 | { | 115 | { |
116 | SceneObject dupe = new SceneObject(); | 116 | SceneObject dupe = new SceneObject(); |
117 | 117 | ||
118 | dupe.m_world = this.m_world; | ||
119 | dupe.m_regionHandle = this.m_regionHandle; | ||
118 | Primitive newRoot = this.rootPrimitive.Copy((EntityBase)dupe, dupe); | 120 | Primitive newRoot = this.rootPrimitive.Copy((EntityBase)dupe, dupe); |
119 | 121 | dupe.rootPrimitive = newRoot; | |
120 | foreach (EntityBase child in this.children) | 122 | dupe.rootPrimitive.Pos =( this.Pos + new LLVector3(0,0,1)); |
121 | { | 123 | dupe.Rotation = this.Rotation; |
122 | EntityBase newChild = child.Copy(); | ||
123 | dupe.children.Add(newChild); | ||
124 | } | ||
125 | 124 | ||
126 | return dupe; | 125 | return dupe; |
127 | } | 126 | } |