diff --git a/Server/TileMatrix.cs b/Server/TileMatrix.cs index 291182feb..0e81c17df 100644 --- a/Server/TileMatrix.cs +++ b/Server/TileMatrix.cs @@ -399,8 +399,11 @@ namespace Server fixed ( StaticTile *pTiles = staTiles ) { +#if !MONO NativeReader.Read( m_Statics.SafeFileHandle.DangerousGetHandle(), pTiles, length ); - +#else + NativeReader.Read( m_Statics.Handle, pTiles, length ); +#endif if ( m_Lists == null ) { m_Lists = new TileList[8][]; @@ -469,7 +472,11 @@ namespace Server fixed ( Tile *pTiles = tiles ) { +#if !MONO NativeReader.Read( m_Map.SafeFileHandle.DangerousGetHandle(), pTiles, 192 ); +#else + NativeReader.Read( m_Map.Handle, pTiles, 192 ); +#endif } return tiles; diff --git a/Server/TileMatrixPatch.cs b/Server/TileMatrixPatch.cs index e7dc58ff5..84e44e6b0 100644 --- a/Server/TileMatrixPatch.cs +++ b/Server/TileMatrixPatch.cs @@ -99,7 +99,11 @@ namespace Server fixed ( Tile *pTiles = tiles ) { +#if !MONO NativeReader.Read( fsData.SafeFileHandle.DangerousGetHandle(), pTiles, 192 ); +#else + NativeReader.Read( fsData.Handle, pTiles, 192 ); +#endif } matrix.SetLandBlock( x, y, tiles ); @@ -164,8 +168,11 @@ namespace Server fixed ( StaticTile *pTiles = staTiles ) { +#if !MONO NativeReader.Read( fsData.SafeFileHandle.DangerousGetHandle(), pTiles, length ); - +#else + NativeReader.Read( fsData.Handle, pTiles, length ); +#endif StaticTile *pCur = pTiles, pEnd = pTiles + tileCount; while ( pCur < pEnd )