Use cloud height rather than offset in options, allow placing liquid and sprite blocks even if entities are located there.

This commit is contained in:
UnknownShadow200 2015-10-12 06:55:14 +11:00
parent 59990d2899
commit dd23cc8a47
2 changed files with 4 additions and 3 deletions

View File

@ -32,9 +32,9 @@ namespace ClassicalSharp {
if( env != null )
env.CloudsSpeed = Single.Parse( v ); } ),
Make( -140, 50, "Clouds offset", Anchor.Centre, OnWidgetClick,
g => (g.Map.CloudHeight - g.Map.Height).ToString(),
(g, v) => g.Map.SetCloudsLevel( g.Map.Height + Int32.Parse( v ) ) ),
Make( -140, 50, "Clouds height", Anchor.Centre, OnWidgetClick,
g => g.Map.CloudHeight.ToString(),
(g, v) => g.Map.SetCloudsLevel( Int32.Parse( v ) ) ),
Make( 140, -150, "Sunlight colour", Anchor.Centre, OnWidgetClick,
g => g.Map.Sunlight.ToRGBHexString(),

View File

@ -72,6 +72,7 @@ namespace ClassicalSharp {
float height = game.BlockInfo.Height[newBlock];
BoundingBox blockBB = new BoundingBox( pos.X, pos.Y, pos.Z,
pos.X + 1, pos.Y + height, pos.Z + 1 );
if( game.BlockInfo.CollideType[newBlock] != BlockCollideType.Solid ) return true;
for( int id = 0; id < 255; id++ ) {
Player player = game.Players[id];