C# Entity Scrips now working(OnInit, update, destroy) [ Broke reloading]

- added UI button to generate a .sln in the games folder
- added UI for adding new component and drag n drop .cs file
- added modular Core API module system
This commit is contained in:
Antoine Pilote
2023-10-16 00:21:28 -04:00
parent 9807f0fa8f
commit af2546fb21
21 changed files with 677 additions and 50 deletions

View File

@@ -0,0 +1,39 @@
#pragma once
#include "src/Core/Core.h"
#include "src/Core/FileSystem.h"
#include "src/Core/Logger.h"
#include "src/Resource/Serializable.h"
#include "src/Resource/File.h"
namespace Nuake {
class NetScriptComponent
{
public:
std::string ScriptPath;
std::string Class;
json Serialize()
{
BEGIN_SERIALIZE();
SERIALIZE_VAL(ScriptPath);
SERIALIZE_VAL(Class);
END_SERIALIZE();
}
bool Deserialize(const json& j)
{
if (j.contains("ScriptPath"))
{
ScriptPath = j["ScriptPath"];
}
if (j.contains("Class"))
{
Class = j["Class"];
}
return true;
}
};
}