1
0
mirror of https://github.com/VCMP-SqMod/SqMod.git synced 2024-11-08 00:37:15 +01:00

WIP inventory prototyping.

This commit is contained in:
Sandu Liviu Catalin 2021-04-01 22:00:04 +03:00
parent 8dfeba7719
commit 41f7c4f75f
4 changed files with 80 additions and 0 deletions

View File

@ -38,6 +38,7 @@ add_library(SqModule MODULE SqBase.hpp Main.cpp
Core/Command.cpp Core/Command.hpp
Core/Common.cpp Core/Common.hpp
Core/Entity.cpp Core/Entity.hpp
Core/Inventory.cpp Core/Inventory.hpp
Core/Loot.cpp Core/Loot.hpp
Core/Privilege.cpp Core/Privilege.hpp
Core/Privilege/Base.cpp Core/Privilege/Base.hpp

19
module/Core/Inventory.cpp Normal file
View File

@ -0,0 +1,19 @@
// ------------------------------------------------------------------------------------------------
#include "Core/Inventory.hpp"
// ------------------------------------------------------------------------------------------------
#include <cstring>
// ------------------------------------------------------------------------------------------------
namespace SqMod {
// ------------------------------------------------------------------------------------------------
// ================================================================================================
void Register_Inventory(HSQUIRRELVM vm)
{
}
} // Namespace:: SqMod

58
module/Core/Inventory.hpp Normal file
View File

@ -0,0 +1,58 @@
#pragma once
// ------------------------------------------------------------------------------------------------
#include "Core/Utility.hpp"
#include "Base/Vector3.hpp"
#include "Base/Quaternion.hpp"
// ------------------------------------------------------------------------------------------------
#include <array>
#include <vector>
#include <random>
#include <chrono>
// ------------------------------------------------------------------------------------------------
namespace SqMod {
/* ------------------------------------------------------------------------------------------------
* Built-in inventory.
*/
class InventoryManager
{
public:
/* --------------------------------------------------------------------------------------------
* Default constructor.
*/
InventoryManager() = default;
/* --------------------------------------------------------------------------------------------
* Copy constructor. (disabled)
*/
InventoryManager(const InventoryManager & o) = delete;
/* --------------------------------------------------------------------------------------------
* Move constructor. (disabled)
*/
InventoryManager(InventoryManager && o) = delete;
/* --------------------------------------------------------------------------------------------
* Destructor.
*/
~InventoryManager() = default;
/* --------------------------------------------------------------------------------------------
* Copy assignment operator. (disabled)
*/
InventoryManager & operator = (const InventoryManager & o) = delete;
/* --------------------------------------------------------------------------------------------
* Copy assignment operator. (disabled)
*/
InventoryManager & operator = (InventoryManager && o) = delete;
private:
};
} // Namespace:: SqMod

View File

@ -50,6 +50,7 @@ extern void Register_Constants(HSQUIRRELVM vm);
extern void Register_Log(HSQUIRRELVM vm);
extern void Register_Core(HSQUIRRELVM vm);
extern void Register_Command(HSQUIRRELVM vm);
extern void Register_Inventory(HSQUIRRELVM vm);
extern void Register_Loot(HSQUIRRELVM vm);
extern void Register_Privilege(HSQUIRRELVM vm);
extern void Register_Routine(HSQUIRRELVM vm);
@ -104,6 +105,7 @@ bool RegisterAPI(HSQUIRRELVM vm)
Register_Log(vm);
Register_Core(vm);
Register_Command(vm);
Register_Inventory(vm);
Register_Loot(vm);
Register_Privilege(vm);
Register_Routine(vm);