mirror of
https://git.krews.org/morningstar/Arcturus-Community.git
synced 2025-01-18 15:36:27 +01:00
Merge branch 'improvement/fix-bot-placement-height' into 'dev'
Fix for bot not sitting at right height when placing on a chair #1999 See merge request morningstar/Arcturus-Community!97
This commit is contained in:
commit
5f82c98c4c
@ -127,7 +127,7 @@ public class BotManager {
|
||||
roomUnit.setRotation(RoomUserRotation.SOUTH);
|
||||
roomUnit.setLocation(location);
|
||||
|
||||
double stackHeight = location.getStackHeight();
|
||||
double stackHeight = room.getTopHeightAt(location.x, location.y);
|
||||
roomUnit.setPreviousLocationZ(stackHeight);
|
||||
roomUnit.setZ(stackHeight);
|
||||
|
||||
|
@ -3636,7 +3636,7 @@ public class Room implements Comparable<Room>, ISerialize, Runnable {
|
||||
HabboItem item = this.getTopItemAt(x, y);
|
||||
|
||||
if (item != null)
|
||||
return (item.getZ() + Item.getCurrentHeight(item));
|
||||
return (item.getZ() + Item.getCurrentHeight(item) - (item.getBaseItem().allowSit() ? 1 : 0));
|
||||
else
|
||||
return this.layout.getHeightAtSquare(x, y);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user