From 0c9160ec8b9e40196f1af634ce211f66393dfaaf Mon Sep 17 00:00:00 2001 From: Matt Woodrow Date: Fri, 24 Jul 2009 12:54:08 +1200 Subject: [PATCH] More build fix attempts --- core/HalfLife2.cpp | 8 ++++---- core/smn_entities.cpp | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/core/HalfLife2.cpp b/core/HalfLife2.cpp index 50203321..a4e327c6 100644 --- a/core/HalfLife2.cpp +++ b/core/HalfLife2.cpp @@ -747,7 +747,7 @@ CEntInfo *CHalfLife2::LookupEntity(int entIndex) tempInfo.m_pNext = NULL; tempInfo.m_pPrev = NULL; - edict_t *pEdict = engine->PEntityOfEntIndex(entIndex); + edict_t *pEdict = PEntityOfEntIndex(entIndex); if (!pEdict) { @@ -795,7 +795,7 @@ cell_t CHalfLife2::IndexToReference(int entIndex) int CHalfLife2::ReferenceToIndex(cell_t entRef) { - if (entRef == INVALID_EHANDLE_INDEX) + if ((unsigned)entRef == INVALID_EHANDLE_INDEX) { return INVALID_EHANDLE_INDEX; } @@ -841,7 +841,7 @@ cell_t CHalfLife2::EntityToBCompatRef(CBaseEntity *pEntity) cell_t CHalfLife2::ReferenceToBCompatRef(cell_t entRef) { - if (entRef == INVALID_EHANDLE_INDEX) + if ((unsigned)entRef == INVALID_EHANDLE_INDEX) { return INVALID_EHANDLE_INDEX; } @@ -860,4 +860,4 @@ cell_t CHalfLife2::ReferenceToBCompatRef(cell_t entRef) void *CHalfLife2::GetGlobalEntityList() { return g_EntList; -} \ No newline at end of file +} diff --git a/core/smn_entities.cpp b/core/smn_entities.cpp index 0a2d90de..0d6ad0ee 100644 --- a/core/smn_entities.cpp +++ b/core/smn_entities.cpp @@ -595,7 +595,7 @@ static cell_t SetEntDataEnt(IPluginContext *pContext, const cell_t *params) CBaseHandle &hndl = *(CBaseHandle *)((uint8_t *)pEntity + offset); - if (params[3] == 0 || params[3] == INVALID_EHANDLE_INDEX) + if (params[3] == 0 || (unsigned)params[3] == INVALID_EHANDLE_INDEX) { hndl.Set(NULL); } else { @@ -637,7 +637,7 @@ static cell_t SetEntDataEnt2(IPluginContext *pContext, const cell_t *params) CBaseHandle &hndl = *(CBaseHandle *)((uint8_t *)pEntity + offset); - if (params[3] == INVALID_EHANDLE_INDEX) + if ((unsigned)params[3] == INVALID_EHANDLE_INDEX) { hndl.Set(NULL); }