mirror of
https://github.com/VCMP-SqMod/SqMod.git
synced 2025-08-03 06:31:47 +02:00
Initial commit.
This commit is contained in:
28
source/Entity/Blip.cpp
Normal file
28
source/Entity/Blip.cpp
Normal file
@@ -0,0 +1,28 @@
|
||||
#include "Entity/Blip.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
bool Register_CBlip(HSQUIRRELVM vm)
|
||||
{
|
||||
if (!Register_Reference< CBlip >(vm, _SC("BaseBlip")))
|
||||
{
|
||||
LogDbg("Unable to register the base class <BaseBlip> for <CBlip> type");
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
LogDbg("Beginning registration of <CBlip> type");
|
||||
|
||||
Sqrat::RootTable(vm).Bind(_SC("CBlip"), Sqrat::DerivedClass< CBlip, Reference< CBlip > >(vm, _SC("CBlip"))
|
||||
.Ctor()
|
||||
.Ctor< SQInt32 >()
|
||||
);
|
||||
|
||||
LogDbg("Registration of <CBlip> type was successful");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // Namespace:: SqMod
|
22
source/Entity/Blip.hpp
Normal file
22
source/Entity/Blip.hpp
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef _ENTITY_BLIP_HPP_
|
||||
#define _ENTITY_BLIP_HPP_
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
#include "Entity.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
/* ------------------------------------------------------------------------------------------------
|
||||
* ...
|
||||
*/
|
||||
class CBlip : public Reference< CBlip >
|
||||
{
|
||||
public:
|
||||
// --------------------------------------------------------------------------------------------
|
||||
using RefType::Reference;
|
||||
};
|
||||
|
||||
} // Namespace:: SqMod
|
||||
|
||||
#endif // _ENTITY_BLIP_HPP_
|
29
source/Entity/Checkpoint.cpp
Normal file
29
source/Entity/Checkpoint.cpp
Normal file
@@ -0,0 +1,29 @@
|
||||
#include "Entity/Checkpoint.hpp"
|
||||
#include "Register.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
bool Register_CCheckpoint(HSQUIRRELVM vm)
|
||||
{
|
||||
if (!Register_Reference< CCheckpoint >(vm, _SC("BaseCheckpoint")))
|
||||
{
|
||||
LogDbg("Unable to register the base class <BaseCheckpoint> for <CCheckpoint> type");
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
LogDbg("Beginning registration of <CCheckpoint> type");
|
||||
|
||||
Sqrat::RootTable(vm).Bind(_SC("CCheckpoint"), Sqrat::DerivedClass< CCheckpoint, Reference< CCheckpoint > >(vm, _SC("CCheckpoint"))
|
||||
.Ctor()
|
||||
.Ctor< SQInt32 >()
|
||||
);
|
||||
|
||||
LogDbg("Registration of <CCheckpoint> type was successful");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // Namespace:: SqMod
|
22
source/Entity/Checkpoint.hpp
Normal file
22
source/Entity/Checkpoint.hpp
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef _ENTITY_CHECKPOINT_HPP_
|
||||
#define _ENTITY_CHECKPOINT_HPP_
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
#include "Entity.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
/* ------------------------------------------------------------------------------------------------
|
||||
* ...
|
||||
*/
|
||||
class CCheckpoint : public Reference< CCheckpoint >
|
||||
{
|
||||
public:
|
||||
// --------------------------------------------------------------------------------------------
|
||||
using RefType::Reference;
|
||||
};
|
||||
|
||||
} // Namespace:: SqMod
|
||||
|
||||
#endif // _ENTITY_CHECKPOINT_HPP_
|
29
source/Entity/Keybind.cpp
Normal file
29
source/Entity/Keybind.cpp
Normal file
@@ -0,0 +1,29 @@
|
||||
#include "Entity/Keybind.hpp"
|
||||
#include "Register.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
bool Register_CKeybind(HSQUIRRELVM vm)
|
||||
{
|
||||
if (!Register_Reference< CKeybind >(vm, _SC("BaseKeybind")))
|
||||
{
|
||||
LogDbg("Unable to register the base class <BaseKeybind> for <CKeybind> type");
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
LogDbg("Beginning registration of <CKeybind> type");
|
||||
|
||||
Sqrat::RootTable(vm).Bind(_SC("CKeybind"), Sqrat::DerivedClass< CKeybind, Reference< CKeybind > >(vm, _SC("CKeybind"))
|
||||
.Ctor()
|
||||
.Ctor< SQInt32 >()
|
||||
);
|
||||
|
||||
LogDbg("Registration of <CKeybind> type was successful");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // Namespace:: SqMod
|
22
source/Entity/Keybind.hpp
Normal file
22
source/Entity/Keybind.hpp
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef _ENTITY_KEYBIND_HPP_
|
||||
#define _ENTITY_KEYBIND_HPP_
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
#include "Entity.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
/* ------------------------------------------------------------------------------------------------
|
||||
* ...
|
||||
*/
|
||||
class CKeybind : public Reference< CKeybind >
|
||||
{
|
||||
public:
|
||||
// --------------------------------------------------------------------------------------------
|
||||
using RefType::Reference;
|
||||
};
|
||||
|
||||
} // Namespace:: SqMod
|
||||
|
||||
#endif // _ENTITY_KEYBIND_HPP_
|
29
source/Entity/Object.cpp
Normal file
29
source/Entity/Object.cpp
Normal file
@@ -0,0 +1,29 @@
|
||||
#include "Entity/Object.hpp"
|
||||
#include "Register.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
bool Register_CObject(HSQUIRRELVM vm)
|
||||
{
|
||||
if (!Register_Reference< CObject >(vm, _SC("BaseObject")))
|
||||
{
|
||||
LogDbg("Unable to register the base class <BaseObject> for <CObject> type");
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
LogDbg("Beginning registration of <CObject> type");
|
||||
|
||||
Sqrat::RootTable(vm).Bind(_SC("CObject"), Sqrat::DerivedClass< CObject, Reference< CObject > >(vm, _SC("CObject"))
|
||||
.Ctor()
|
||||
.Ctor< SQInt32 >()
|
||||
);
|
||||
|
||||
LogDbg("Registration of <CObject> type was successful");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // Namespace:: SqMod
|
22
source/Entity/Object.hpp
Normal file
22
source/Entity/Object.hpp
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef _ENTITY_OBJECT_HPP_
|
||||
#define _ENTITY_OBJECT_HPP_
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
#include "Entity.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
/* ------------------------------------------------------------------------------------------------
|
||||
* ...
|
||||
*/
|
||||
class CObject : public Reference< CObject >
|
||||
{
|
||||
public:
|
||||
// --------------------------------------------------------------------------------------------
|
||||
using RefType::Reference;
|
||||
};
|
||||
|
||||
} // Namespace:: SqMod
|
||||
|
||||
#endif // _ENTITY_OBJECT_HPP_
|
29
source/Entity/Pickup.cpp
Normal file
29
source/Entity/Pickup.cpp
Normal file
@@ -0,0 +1,29 @@
|
||||
#include "Entity/Pickup.hpp"
|
||||
#include "Register.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
bool Register_CPickup(HSQUIRRELVM vm)
|
||||
{
|
||||
if (!Register_Reference< CPickup >(vm, _SC("BasePickup")))
|
||||
{
|
||||
LogDbg("Unable to register the base class <BasePickup> for <CPickup> type");
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
LogDbg("Beginning registration of <CPickup> type");
|
||||
|
||||
Sqrat::RootTable(vm).Bind(_SC("CPickup"), Sqrat::DerivedClass< CPickup, Reference< CPickup > >(vm, _SC("CPickup"))
|
||||
.Ctor()
|
||||
.Ctor< SQInt32 >()
|
||||
);
|
||||
|
||||
LogDbg("Registration of <CPickup> type was successful");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // Namespace:: SqMod
|
22
source/Entity/Pickup.hpp
Normal file
22
source/Entity/Pickup.hpp
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef _ENTITY_PICKUP_HPP_
|
||||
#define _ENTITY_PICKUP_HPP_
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
#include "Entity.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
/* ------------------------------------------------------------------------------------------------
|
||||
* ...
|
||||
*/
|
||||
class CPickup : public Reference< CPickup >
|
||||
{
|
||||
public:
|
||||
// --------------------------------------------------------------------------------------------
|
||||
using RefType::Reference;
|
||||
};
|
||||
|
||||
} // Namespace:: SqMod
|
||||
|
||||
#endif // _ENTITY_PICKUP_HPP_
|
29
source/Entity/Player.cpp
Normal file
29
source/Entity/Player.cpp
Normal file
@@ -0,0 +1,29 @@
|
||||
#include "Entity/Player.hpp"
|
||||
#include "Register.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
bool Register_CPlayer(HSQUIRRELVM vm)
|
||||
{
|
||||
if (!Register_Reference< CPlayer >(vm, _SC("BasePlayer")))
|
||||
{
|
||||
LogDbg("Unable to register the base class <BasePlayer> for <CPlayer> type");
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
LogDbg("Beginning registration of <CPlayer> type");
|
||||
|
||||
Sqrat::RootTable(vm).Bind(_SC("CPlayer"), Sqrat::DerivedClass< CPlayer, Reference< CPlayer > >(vm, _SC("CPlayer"))
|
||||
.Ctor()
|
||||
.Ctor< SQInt32 >()
|
||||
);
|
||||
|
||||
LogDbg("Registration of <CPlayer> type was successful");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // Namespace:: SqMod
|
22
source/Entity/Player.hpp
Normal file
22
source/Entity/Player.hpp
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef _ENTITY_PLAYER_HPP_
|
||||
#define _ENTITY_PLAYER_HPP_
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
#include "Entity.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
/* ------------------------------------------------------------------------------------------------
|
||||
* ...
|
||||
*/
|
||||
class CPlayer : public Reference< CPlayer >
|
||||
{
|
||||
public:
|
||||
// --------------------------------------------------------------------------------------------
|
||||
using RefType::Reference;
|
||||
};
|
||||
|
||||
} // Namespace:: SqMod
|
||||
|
||||
#endif // _ENTITY_PLAYER_HPP_
|
29
source/Entity/Sphere.cpp
Normal file
29
source/Entity/Sphere.cpp
Normal file
@@ -0,0 +1,29 @@
|
||||
#include "Entity/Sphere.hpp"
|
||||
#include "Register.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
bool Register_CSphere(HSQUIRRELVM vm)
|
||||
{
|
||||
if (!Register_Reference< CSphere >(vm, _SC("BaseSphere")))
|
||||
{
|
||||
LogDbg("Unable to register the base class <BaseSphere> for <CSphere> type");
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
LogDbg("Beginning registration of <CSphere> type");
|
||||
|
||||
Sqrat::RootTable(vm).Bind(_SC("CSphere"), Sqrat::DerivedClass< CSphere, Reference< CSphere > >(vm, _SC("CSphere"))
|
||||
.Ctor()
|
||||
.Ctor< SQInt32 >()
|
||||
);
|
||||
|
||||
LogDbg("Registration of <CSphere> type was successful");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // Namespace:: SqMod
|
22
source/Entity/Sphere.hpp
Normal file
22
source/Entity/Sphere.hpp
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef _ENTITY_SPHERE_HPP_
|
||||
#define _ENTITY_SPHERE_HPP_
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
#include "Entity.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
/* ------------------------------------------------------------------------------------------------
|
||||
* ...
|
||||
*/
|
||||
class CSphere : public Reference< CSphere >
|
||||
{
|
||||
public:
|
||||
// --------------------------------------------------------------------------------------------
|
||||
using RefType::Reference;
|
||||
};
|
||||
|
||||
} // Namespace:: SqMod
|
||||
|
||||
#endif // _ENTITY_SPHERE_HPP_
|
29
source/Entity/Sprite.cpp
Normal file
29
source/Entity/Sprite.cpp
Normal file
@@ -0,0 +1,29 @@
|
||||
#include "Entity/Sprite.hpp"
|
||||
#include "Register.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
bool Register_CSprite(HSQUIRRELVM vm)
|
||||
{
|
||||
if (!Register_Reference< CSprite >(vm, _SC("BaseSprite")))
|
||||
{
|
||||
LogDbg("Unable to register the base class <BaseSprite> for <CSprite> type");
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
LogDbg("Beginning registration of <CSprite> type");
|
||||
|
||||
Sqrat::RootTable(vm).Bind(_SC("CSprite"), Sqrat::DerivedClass< CSprite, Reference< CSprite > >(vm, _SC("CSprite"))
|
||||
.Ctor()
|
||||
.Ctor< SQInt32 >()
|
||||
);
|
||||
|
||||
LogDbg("Registration of <CSprite> type was successful");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // Namespace:: SqMod
|
22
source/Entity/Sprite.hpp
Normal file
22
source/Entity/Sprite.hpp
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef _ENTITY_SPRITE_HPP_
|
||||
#define _ENTITY_SPRITE_HPP_
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
#include "Entity.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
/* ------------------------------------------------------------------------------------------------
|
||||
* ...
|
||||
*/
|
||||
class CSprite : public Reference< CSprite >
|
||||
{
|
||||
public:
|
||||
// --------------------------------------------------------------------------------------------
|
||||
using RefType::Reference;
|
||||
};
|
||||
|
||||
} // Namespace:: SqMod
|
||||
|
||||
#endif // _ENTITY_SPRITE_HPP_
|
29
source/Entity/Textdraw.cpp
Normal file
29
source/Entity/Textdraw.cpp
Normal file
@@ -0,0 +1,29 @@
|
||||
#include "Entity/Textdraw.hpp"
|
||||
#include "Register.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
bool Register_CTextdraw(HSQUIRRELVM vm)
|
||||
{
|
||||
if (!Register_Reference< CTextdraw >(vm, _SC("BaseTextdraw")))
|
||||
{
|
||||
LogDbg("Unable to register the base class <BaseTextdraw> for <CTextdraw> type");
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
LogDbg("Beginning registration of <CTextdraw> type");
|
||||
|
||||
Sqrat::RootTable(vm).Bind(_SC("CTextdraw"), Sqrat::DerivedClass< CTextdraw, Reference< CTextdraw > >(vm, _SC("CTextdraw"))
|
||||
.Ctor()
|
||||
.Ctor< SQInt32 >()
|
||||
);
|
||||
|
||||
LogDbg("Registration of <CTextdraw> type was successful");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // Namespace:: SqMod
|
22
source/Entity/Textdraw.hpp
Normal file
22
source/Entity/Textdraw.hpp
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef _ENTITY_TEXTDRAW_HPP_
|
||||
#define _ENTITY_TEXTDRAW_HPP_
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
#include "Entity.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
/* ------------------------------------------------------------------------------------------------
|
||||
* ...
|
||||
*/
|
||||
class CTextdraw : public Reference< CTextdraw >
|
||||
{
|
||||
public:
|
||||
// --------------------------------------------------------------------------------------------
|
||||
using RefType::Reference;
|
||||
};
|
||||
|
||||
} // Namespace:: SqMod
|
||||
|
||||
#endif // _ENTITY_TEXTDRAW_HPP_
|
29
source/Entity/Vehicle.cpp
Normal file
29
source/Entity/Vehicle.cpp
Normal file
@@ -0,0 +1,29 @@
|
||||
#include "Entity/Vehicle.hpp"
|
||||
#include "Register.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
bool Register_CVehicle(HSQUIRRELVM vm)
|
||||
{
|
||||
if (!Register_Reference< CVehicle >(vm, _SC("BaseVehicle")))
|
||||
{
|
||||
LogDbg("Unable to register the base class <BaseVehicle> for <CVehicle> type");
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
LogDbg("Beginning registration of <CVehicle> type");
|
||||
|
||||
Sqrat::RootTable(vm).Bind(_SC("CVehicle"), Sqrat::DerivedClass< CVehicle, Reference< CVehicle > >(vm, _SC("CVehicle"))
|
||||
.Ctor()
|
||||
.Ctor< SQInt32 >()
|
||||
);
|
||||
|
||||
LogDbg("Registration of <CVehicle> type was successful");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // Namespace:: SqMod
|
22
source/Entity/Vehicle.hpp
Normal file
22
source/Entity/Vehicle.hpp
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef _ENTITY_VEHICLE_HPP_
|
||||
#define _ENTITY_VEHICLE_HPP_
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
#include "Entity.hpp"
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
namespace SqMod {
|
||||
|
||||
/* ------------------------------------------------------------------------------------------------
|
||||
* ...
|
||||
*/
|
||||
class CVehicle : public Reference< CVehicle >
|
||||
{
|
||||
public:
|
||||
// --------------------------------------------------------------------------------------------
|
||||
using RefType::Reference;
|
||||
};
|
||||
|
||||
} // Namespace:: SqMod
|
||||
|
||||
#endif // _ENTITY_VEHICLE_HPP_
|
Reference in New Issue
Block a user