1
0
mirror of https://github.com/VCMP-SqMod/SqMod.git synced 2025-11-02 15:27:19 +01:00

Replace GetObject with GetObj to avoid collisions on Windows.

ef you MS
This commit is contained in:
Sandu Liviu Catalin
2020-04-17 17:42:09 +03:00
parent 1242b8a2fc
commit e13d1a91e7
22 changed files with 94 additions and 95 deletions

View File

@@ -193,7 +193,7 @@ static LightObj & SqGetKeybind(Int32 id)
}
// ------------------------------------------------------------------------------------------------
static LightObj & SqGetObject(Int32 id)
static LightObj & SqGetObj(Int32 id)
{
// Validate the identifier first
if (INVALID_ENTITYEX(id, SQMOD_OBJECT_POOL))
@@ -201,7 +201,7 @@ static LightObj & SqGetObject(Int32 id)
STHROWF("Out of range object identifier: %d", id);
}
// Return the requested information
return Core::Get().GetObject(id).mObj;
return Core::Get().GetObj(id).mObj;
}
// ------------------------------------------------------------------------------------------------
@@ -345,7 +345,7 @@ void Register_Core(HSQUIRRELVM vm)
.Func(_SC("GetBlip"), &SqGetBlip)
.Func(_SC("GetCheckpoint"), &SqGetCheckpoint)
.Func(_SC("GetKeybind"), &SqGetKeybind)
.Func(_SC("GetObject"), &SqGetObject)
.Func(_SC("GetObj"), &SqGetObj)
.Func(_SC("GetPickup"), &SqGetPickup)
.Func(_SC("GetPlayer"), &SqGetPlayer)
.Func(_SC("GetVehicle"), &SqGetVehicle)