From 53cc63e243b33b45779b6c891e0ea40430b187df Mon Sep 17 00:00:00 2001 From: Charles Krinke Date: Tue, 10 Jun 2008 16:02:18 +0000 Subject: Mantis#1501. Thank you kindly, Nebadon, for a patch that addresses the 'terrain fill 0' error. --- OpenSim/Data/MySQL/MySQLDataStore.cs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'OpenSim') diff --git a/OpenSim/Data/MySQL/MySQLDataStore.cs b/OpenSim/Data/MySQL/MySQLDataStore.cs index 9b7771c..a38a8b2 100644 --- a/OpenSim/Data/MySQL/MySQLDataStore.cs +++ b/OpenSim/Data/MySQL/MySQLDataStore.cs @@ -1046,7 +1046,13 @@ namespace OpenSim.Data.MySQL // TODO: COMPATIBILITY - Add byte-order conversions for (int x = 0; x < 256; x++) for (int y = 0; y < 256; y++) - bw.Write(val[x, y]); + { + double height = val[x, y]; + if (height == 0.0) + height = double.Epsilon; + + bw.Write(height); + } return str.ToArray(); } -- cgit v1.1