mirror of
https://github.com/VCMP-SqMod/SqMod.git
synced 2026-11-05 19:37:09 +01:00
Add the possibility to have null entity instances intentionally.
This commit is contained in:
1 parent
5c26ba62df
commit
29b0f8d4c9
16 files changed
+233
-1
No files matched your search
@@ -16,6 +16,19 @@ SQInteger CBlip::Typename(HSQUIRRELVM vm)
|
||||
return 1;
|
||||
}
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
SQInteger CBlip::SqGetNull(HSQUIRRELVM vm)
|
||||
{
|
||||
sq_pushobject(vm, Core::Get().GetNullBlip().GetObject());
|
||||
return 1;
|
||||
}
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
Object & CBlip::GetNull()
|
||||
{
|
||||
return Core::Get().GetNullBlip();
|
||||
}
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
CBlip::CBlip(Int32 id)
|
||||
: m_ID(VALID_ENTITYGETEX(id, SQMOD_BLIP_POOL))
|
||||
@@ -350,6 +363,8 @@ void Register_CBlip(HSQUIRRELVM vm)
|
||||
(_SC("Create"), &Blip_Create)
|
||||
.StaticOverload< Object & (*)(Int32, Int32, const Vector3 &, Int32, const Color4 &, Int32, Int32, Object &) >
|
||||
(_SC("Create"), &Blip_Create)
|
||||
// Raw Squirrel Methods
|
||||
.SquirrelFunc(_SC("NullInst"), &CBlip::SqGetNull)
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user