mirror of
https://github.com/ClassiCube/ClassiCube.git
synced 2025-09-16 11:06:06 -04:00
Fix respawn on non-air blocks. (Thanks goodlyay)
This commit is contained in:
parent
e9abb3def5
commit
e66116bdf4
@ -14,7 +14,7 @@ namespace ClassicalSharp.Gui {
|
|||||||
|
|
||||||
Block[] blocksTable;
|
Block[] blocksTable;
|
||||||
Texture blockInfoTexture;
|
Texture blockInfoTexture;
|
||||||
const int blocksPerRow = 10, maxRows = 4;
|
const int blocksPerRow = 10, maxRows = 8;
|
||||||
int selIndex, rows;
|
int selIndex, rows;
|
||||||
int startX, startY, blockSize;
|
int startX, startY, blockSize;
|
||||||
float selBlockExpand;
|
float selBlockExpand;
|
||||||
|
@ -284,7 +284,8 @@ namespace ClassicalSharp.Entities {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if( !anyHit ) {
|
if( !anyHit ) {
|
||||||
spawn.Y = y + Entity.Adjustment;
|
byte block = collisions.GetPhysicsBlockId( P.X, y, P.Z );
|
||||||
|
spawn.Y = y + info.MaxBB[block].Y + Entity.Adjustment;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user