mirror of
https://github.com/edubart/otclient.git
synced 2025-12-22 16:27:10 +01:00
map draw improvements
This commit is contained in:
18
src/tile.cpp
18
src/tile.cpp
@@ -47,3 +47,21 @@ void Tile::draw(int x, int y, int z)
|
||||
(*it)->draw(x, y, z);
|
||||
|
||||
}
|
||||
|
||||
bool Tile::hasGround()
|
||||
{
|
||||
return m_ground != 0;
|
||||
}
|
||||
|
||||
int Tile::getStackSize()
|
||||
{
|
||||
int ret = 0;
|
||||
if(m_ground)
|
||||
ret++;
|
||||
|
||||
ret += m_itemsBot.size();
|
||||
ret += m_creatures.size();
|
||||
ret += m_itemsTop.size();
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user