diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/Environment/Modules/World/Land/LandObject.cs | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/OpenSim/Region/Environment/Modules/World/Land/LandObject.cs b/OpenSim/Region/Environment/Modules/World/Land/LandObject.cs index e297b10..54fe9ae 100644 --- a/OpenSim/Region/Environment/Modules/World/Land/LandObject.cs +++ b/OpenSim/Region/Environment/Modules/World/Land/LandObject.cs | |||
@@ -73,6 +73,8 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
73 | get { return m_scene.RegionInfo.RegionID; } | 73 | get { return m_scene.RegionInfo.RegionID; } |
74 | } | 74 | } |
75 | 75 | ||
76 | #endregion | ||
77 | |||
76 | #region Constructors | 78 | #region Constructors |
77 | 79 | ||
78 | public LandObject(LLUUID owner_id, bool is_group_owned, Scene scene) | 80 | public LandObject(LLUUID owner_id, bool is_group_owned, Scene scene) |
@@ -98,7 +100,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
98 | { | 100 | { |
99 | if (x >= 0 && y >= 0 && x <= Constants.RegionSize && x <= Constants.RegionSize) | 101 | if (x >= 0 && y >= 0 && x <= Constants.RegionSize && x <= Constants.RegionSize) |
100 | { | 102 | { |
101 | return (landBitmap[x / 4, y / 4] == true); | 103 | return landBitmap[x / 4, y / 4]; |
102 | } | 104 | } |
103 | else | 105 | else |
104 | { | 106 | { |
@@ -148,7 +150,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
148 | updatePacket.ParcelData.GroupID = landData.groupID; | 150 | updatePacket.ParcelData.GroupID = landData.groupID; |
149 | updatePacket.ParcelData.GroupPrims = landData.groupPrims; | 151 | updatePacket.ParcelData.GroupPrims = landData.groupPrims; |
150 | updatePacket.ParcelData.IsGroupOwned = landData.isGroupOwned; | 152 | updatePacket.ParcelData.IsGroupOwned = landData.isGroupOwned; |
151 | updatePacket.ParcelData.LandingType = (byte) landData.landingType; | 153 | updatePacket.ParcelData.LandingType = landData.landingType; |
152 | updatePacket.ParcelData.LocalID = landData.localID; | 154 | updatePacket.ParcelData.LocalID = landData.localID; |
153 | if (landData.area > 0) | 155 | if (landData.area > 0) |
154 | { | 156 | { |
@@ -212,7 +214,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
212 | landData.selectedPrims; | 214 | landData.selectedPrims; |
213 | updatePacket.ParcelData.UserLocation = landData.userLocation; | 215 | updatePacket.ParcelData.UserLocation = landData.userLocation; |
214 | updatePacket.ParcelData.UserLookAt = landData.userLookAt; | 216 | updatePacket.ParcelData.UserLookAt = landData.userLookAt; |
215 | remote_client.OutPacket((Packet) updatePacket, ThrottleOutPacketType.Task); | 217 | remote_client.OutPacket(updatePacket, ThrottleOutPacketType.Task); |
216 | } | 218 | } |
217 | 219 | ||
218 | public void updateLandProperties(ParcelPropertiesUpdatePacket packet, IClientAPI remote_client) | 220 | public void updateLandProperties(ParcelPropertiesUpdatePacket packet, IClientAPI remote_client) |
@@ -355,7 +357,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
355 | { | 357 | { |
356 | ParcelAccessListReplyPacket.ListBlock listBlock = new ParcelAccessListReplyPacket.ListBlock(); | 358 | ParcelAccessListReplyPacket.ListBlock listBlock = new ParcelAccessListReplyPacket.ListBlock(); |
357 | 359 | ||
358 | listBlock.Flags = (uint) 0; | 360 | listBlock.Flags = 0; |
359 | listBlock.ID = entry.AgentID; | 361 | listBlock.ID = entry.AgentID; |
360 | listBlock.Time = 0; | 362 | listBlock.Time = 0; |
361 | 363 | ||
@@ -367,7 +369,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
367 | { | 369 | { |
368 | ParcelAccessListReplyPacket.ListBlock listBlock = new ParcelAccessListReplyPacket.ListBlock(); | 370 | ParcelAccessListReplyPacket.ListBlock listBlock = new ParcelAccessListReplyPacket.ListBlock(); |
369 | 371 | ||
370 | listBlock.Flags = (uint) 0; | 372 | listBlock.Flags = 0; |
371 | listBlock.ID = LLUUID.Zero; | 373 | listBlock.ID = LLUUID.Zero; |
372 | listBlock.Time = 0; | 374 | listBlock.Time = 0; |
373 | 375 | ||
@@ -390,7 +392,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
390 | replyPacket.Data.SequenceID = 0; | 392 | replyPacket.Data.SequenceID = 0; |
391 | 393 | ||
392 | replyPacket.List = createAccessListArrayByFlag(ParcelManager.AccessList.Access); | 394 | replyPacket.List = createAccessListArrayByFlag(ParcelManager.AccessList.Access); |
393 | remote_client.OutPacket((Packet) replyPacket, ThrottleOutPacketType.Task); | 395 | remote_client.OutPacket(replyPacket, ThrottleOutPacketType.Task); |
394 | } | 396 | } |
395 | 397 | ||
396 | if (flags == (uint) ParcelManager.AccessList.Ban || flags == (uint) ParcelManager.AccessList.Both) | 398 | if (flags == (uint) ParcelManager.AccessList.Ban || flags == (uint) ParcelManager.AccessList.Both) |
@@ -402,7 +404,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
402 | replyPacket.Data.SequenceID = 0; | 404 | replyPacket.Data.SequenceID = 0; |
403 | 405 | ||
404 | replyPacket.List = createAccessListArrayByFlag(ParcelManager.AccessList.Ban); | 406 | replyPacket.List = createAccessListArrayByFlag(ParcelManager.AccessList.Ban); |
405 | remote_client.OutPacket((Packet) replyPacket, ThrottleOutPacketType.Task); | 407 | remote_client.OutPacket(replyPacket, ThrottleOutPacketType.Task); |
406 | } | 408 | } |
407 | } | 409 | } |
408 | 410 | ||
@@ -482,7 +484,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
482 | { | 484 | { |
483 | for (y = 0; y < 64; y++) | 485 | for (y = 0; y < 64; y++) |
484 | { | 486 | { |
485 | if (landBitmap[x, y] == true) | 487 | if (landBitmap[x, y]) |
486 | { | 488 | { |
487 | if (min_x > x) min_x = x; | 489 | if (min_x > x) min_x = x; |
488 | if (min_y > y) min_y = y; | 490 | if (min_y > y) min_y = y; |
@@ -499,7 +501,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
499 | if (ty > 255) | 501 | if (ty > 255) |
500 | ty = 255; | 502 | ty = 255; |
501 | landData.AABBMin = | 503 | landData.AABBMin = |
502 | new LLVector3((float) (min_x * 4), (float) (min_y * 4), | 504 | new LLVector3((min_x * 4), (min_y * 4), |
503 | (float) m_scene.Heightmap[tx, ty]); | 505 | (float) m_scene.Heightmap[tx, ty]); |
504 | 506 | ||
505 | tx = max_x * 4; | 507 | tx = max_x * 4; |
@@ -509,7 +511,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
509 | if (ty > 255) | 511 | if (ty > 255) |
510 | ty = 255; | 512 | ty = 255; |
511 | landData.AABBMax = | 513 | landData.AABBMax = |
512 | new LLVector3((float) (max_x * 4), (float) (max_y * 4), | 514 | new LLVector3((max_x * 4), (max_y * 4), |
513 | (float) m_scene.Heightmap[tx, ty]); | 515 | (float) m_scene.Heightmap[tx, ty]); |
514 | landData.area = tempArea; | 516 | landData.area = tempArea; |
515 | } | 517 | } |
@@ -657,7 +659,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
657 | if (i % 8 == 0) | 659 | if (i % 8 == 0) |
658 | { | 660 | { |
659 | tempConvertArr[byteNum] = tempByte; | 661 | tempConvertArr[byteNum] = tempByte; |
660 | tempByte = (byte) 0; | 662 | tempByte = 0; |
661 | i = 0; | 663 | i = 0; |
662 | byteNum++; | 664 | byteNum++; |
663 | } | 665 | } |
@@ -677,7 +679,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
677 | tempByte = landData.landBitmapByteArray[i]; | 679 | tempByte = landData.landBitmapByteArray[i]; |
678 | for (bitNum = 0; bitNum < 8; bitNum++) | 680 | for (bitNum = 0; bitNum < 8; bitNum++) |
679 | { | 681 | { |
680 | bool bit = Convert.ToBoolean(Convert.ToByte(tempByte >> bitNum) & (byte) 1); | 682 | bool bit = Convert.ToBoolean(Convert.ToByte(tempByte >> bitNum) & 1); |
681 | tempConvertMap[x, y] = bit; | 683 | tempConvertMap[x, y] = bit; |
682 | x++; | 684 | x++; |
683 | if (x > 63) | 685 | if (x > 63) |
@@ -751,7 +753,7 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
751 | resultLocalIDs.RemoveAt(0); | 753 | resultLocalIDs.RemoveAt(0); |
752 | } | 754 | } |
753 | pack.Data = data; | 755 | pack.Data = data; |
754 | remote_client.OutPacket((Packet) pack, ThrottleOutPacketType.Task); | 756 | remote_client.OutPacket(pack, ThrottleOutPacketType.Task); |
755 | } | 757 | } |
756 | } | 758 | } |
757 | 759 | ||
@@ -922,7 +924,5 @@ namespace OpenSim.Region.Environment.Modules.World.Land | |||
922 | #endregion | 924 | #endregion |
923 | 925 | ||
924 | #endregion | 926 | #endregion |
925 | |||
926 | #endregion | ||
927 | } | 927 | } |
928 | } \ No newline at end of file | 928 | } \ No newline at end of file |