diff options
Diffstat (limited to 'OpenSim/Framework/Util.cs')
-rw-r--r-- | OpenSim/Framework/Util.cs | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/OpenSim/Framework/Util.cs b/OpenSim/Framework/Util.cs index 1c8f273..3654a7d 100644 --- a/OpenSim/Framework/Util.cs +++ b/OpenSim/Framework/Util.cs | |||
@@ -46,12 +46,13 @@ namespace OpenSim.Framework | |||
46 | private static object XferLock = new object(); | 46 | private static object XferLock = new object(); |
47 | private static Dictionary<LLUUID, string> capsURLS = new Dictionary<LLUUID, string>(); | 47 | private static Dictionary<LLUUID, string> capsURLS = new Dictionary<LLUUID, string>(); |
48 | 48 | ||
49 | public static double GetDistanceTo(LLVector3 a, LLVector3 b) { | 49 | public static double GetDistanceTo(LLVector3 a, LLVector3 b) |
50 | float dx = a.X - b.X; | 50 | { |
51 | float dy = a.Y - b.Y; | 51 | float dx = a.X - b.X; |
52 | float dz = a.Z - b.Z; | 52 | float dy = a.Y - b.Y; |
53 | return Math.Sqrt(dx * dx + dy * dy + dz * dz); | 53 | float dz = a.Z - b.Z; |
54 | } | 54 | return Math.Sqrt(dx*dx + dy*dy + dz*dz); |
55 | } | ||
55 | 56 | ||
56 | public static ulong UIntsToLong(uint X, uint Y) | 57 | public static ulong UIntsToLong(uint X, uint Y) |
57 | { | 58 | { |
@@ -383,7 +384,7 @@ namespace OpenSim.Framework | |||
383 | { | 384 | { |
384 | return Math.Min(Math.Max(x, min), max); | 385 | return Math.Min(Math.Max(x, min), max); |
385 | } | 386 | } |
386 | 387 | ||
387 | /// <summary> | 388 | /// <summary> |
388 | /// Convert an LLUUID to a raw uuid string. Right now this is a string without hyphens. | 389 | /// Convert an LLUUID to a raw uuid string. Right now this is a string without hyphens. |
389 | /// </summary> | 390 | /// </summary> |
@@ -394,4 +395,4 @@ namespace OpenSim.Framework | |||
394 | return lluuid.UUID.ToString("n"); | 395 | return lluuid.UUID.ToString("n"); |
395 | } | 396 | } |
396 | } | 397 | } |
397 | } | 398 | } \ No newline at end of file |