forked from 0ad/0ad
fixed a few warnings; updated vfs file enum code
This was SVN commit r375.
This commit is contained in:
parent
af05b758c6
commit
6782c17105
@ -27,7 +27,7 @@ CMiniPatch::~CMiniPatch()
|
||||
// on return, parameters x,y contain index in [0,MapSize)
|
||||
void CMiniPatch::GetTileIndex(u32& x,u32& z)
|
||||
{
|
||||
u32 tindex=this-&m_Parent->m_MiniPatches[0][0];
|
||||
const ptrdiff_t tindex = this - &m_Parent->m_MiniPatches[0][0];
|
||||
x=(m_Parent->m_X*16)+tindex%16;
|
||||
z=(m_Parent->m_Z*16)+tindex/16;
|
||||
}
|
||||
|
@ -36,7 +36,7 @@ void CObjectManager::AddObjectType(const char* name)
|
||||
m_ObjectTypes.resize(m_ObjectTypes.size()+1);
|
||||
SObjectType& type=m_ObjectTypes.back();
|
||||
type.m_Name=name;
|
||||
type.m_Index=m_ObjectTypes.size()-1;
|
||||
type.m_Index=(int)m_ObjectTypes.size()-1;
|
||||
}
|
||||
|
||||
void CObjectManager::AddObject(CObjectEntry* object,int type)
|
||||
|
@ -31,7 +31,7 @@ void CTextureManager::AddTextureType(const char* name)
|
||||
m_TerrainTextures.resize(m_TerrainTextures.size()+1);
|
||||
STextureType& ttype=m_TerrainTextures.back();
|
||||
ttype.m_Name=name;
|
||||
ttype.m_Index=m_TerrainTextures.size()-1;
|
||||
ttype.m_Index=(int)m_TerrainTextures.size()-1;
|
||||
}
|
||||
|
||||
CTextureEntry* CTextureManager::FindTexture(const char* filename)
|
||||
|
@ -754,8 +754,8 @@ void CGUI::DrawText(const SGUIText &Text, const CColor &DefaultColor,
|
||||
if (it->m_pSpriteCall)
|
||||
continue;
|
||||
|
||||
COverlayText txt(pos.x+it->m_Pos.x, pos.y+it->m_Pos.y,
|
||||
z, it->m_Font, it->m_String,
|
||||
COverlayText txt((float)pos.x+it->m_Pos.x, (float)pos.y+it->m_Pos.y,
|
||||
(int)z, it->m_Font, it->m_String,
|
||||
(it->m_UseCustomColor?it->m_Color:DefaultColor));
|
||||
render(&txt);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user