From 5225e40f9e2cfdbc5a14099f45e794ed208838f5 Mon Sep 17 00:00:00 2001 From: Adam Frisby Date: Wed, 1 Apr 2009 05:58:07 +0000 Subject: * Removes some hard-coded magic numbers relating to RegionSize. We now use Constants.RegionSize as expected. (Working towards enlarged or smaller regionsizes that arent multiples of 256m) * Adds minor functionality to MRM Scripting. --- OpenSim/Data/Tests/BasicRegionTest.cs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'OpenSim/Data/Tests') diff --git a/OpenSim/Data/Tests/BasicRegionTest.cs b/OpenSim/Data/Tests/BasicRegionTest.cs index 179692a..e7ce8af 100644 --- a/OpenSim/Data/Tests/BasicRegionTest.cs +++ b/OpenSim/Data/Tests/BasicRegionTest.cs @@ -882,10 +882,10 @@ namespace OpenSim.Data.Tests private double[,] GenTerrain(double value) { - double[,] terret = new double[256,256]; + double[,] terret = new double[Constants.RegionSize, Constants.RegionSize]; terret.Initialize(); - for (int x = 0; x < 256; x++) - for (int y = 0; y < 256; y++) + for (int x = 0; x < Constants.RegionSize; x++) + for (int y = 0; y < Constants.RegionSize; y++) terret[x,y] = value; return terret; @@ -893,8 +893,8 @@ namespace OpenSim.Data.Tests private bool CompareTerrain(double[,] one, double[,] two) { - for (int x = 0; x < 256; x++) - for (int y = 0; y < 256; y++) + for (int x = 0; x < Constants.RegionSize; x++) + for (int y = 0; y < Constants.RegionSize; y++) if (one[x,y] != two[x,y]) return false; -- cgit v1.1