 |
Blamite Game Engine - Guerilla (Library)
00449.01.12.26.0555.blamite
The tag editor for the Blamite Game Engine.
|
Go to the documentation of this file.
4 #include <blam/api/v1/types/project_info.h>
6 #ifdef GUERILLA_LIB_EXPORTS
7 #define GUERILLA_LIB_API __declspec(dllexport)
9 #define GUERILLA_LIB_API __declspec(dllimport)
15 #define PROJECT_FILE_EXTENSION ".blam"
18 #define PROJECT_FILE_USER_SUFFIX ".user"
21 #define BLAM_PROJECTS_DIR "Projects"
31 #define PROJECT_SECTION(name, fields) struct name##_data fields; name##_data name = name##_data();
41 #define PROJECT_FILE_FORMAT_VERSION 1
73 bool is_folder =
false;
74 bool path_exists =
false;
80 std::string hierarchy_path =
"";
81 std::string disk_path =
"";
82 std::string display_name =
"";
83 std::string class_name_short =
"";
113 std::vector<BlamTagTreeNode*> GetBulkNodeList();
127 std::string vcxproj_path =
"";
128 std::string engine_dependencies_path =
"";
129 std::string msbuild_path =
"msbuild.exe";
132 bool Load(std::string file_path);
148 bool load_result =
false;
150 void ValidateProjectFolders();
151 bool PopulateProjectInfo(rapidxml::xml_node<>* root_node);
154 std::string file_path =
"";
155 int format_version = 0;
156 std::string project_name =
"unnamed";
157 std::string project_root =
"";
161 std::string title =
"core";
162 std::string codename =
"core";
163 std::string publisher =
"Elaztek Studios";
164 std::string developer =
"Elaztek Studios";
165 std::string affiliates =
"";
166 std::string copyright =
"Copyright (c) Elaztek Studios 2013-2023";
167 std::string website =
"https://elaztek.com/";
168 std::string version =
"";
169 std::string icon =
"";
174 bool uses_cpp_script =
false;
175 std::string vcxproj_path =
"";
176 std::string engine_dependencies_path =
"";
177 std::string msbuild_path =
"msbuild.exe";
178 std::string msbuild_extra_args =
"";
179 std::string pre_build_commands =
"";
180 std::string post_build_commands =
"";
192 std::string user_data_folder =
"/";
194 std::string default_cache =
"mainmenu";
195 std::string campaign_info =
"";
196 std::string startup_movie =
"";
198 std::string content_root =
"";
199 std::string tags_dir =
"tags";
200 std::string movies_dir =
"bink";
201 std::string data_dir =
"data";
202 std::string cache_dir =
"maps";
203 std::string plugins_dir =
"plugins";
204 std::string fonts_dir =
"maps/fonts";
206 bool allow_user_tag_overrides =
false;
207 bool allow_release_debug_tools =
false;
208 bool allow_release_console =
false;
223 bool LoadFromDisk(std::string file_path);
230 bool BuildTagHierarchy();
232 std::string GetContentRoot();
233 std::string GetTagsRoot();
234 std::string GetMoviesRoot();
235 std::string GetDataRoot();
236 std::string GetCacheRoot();
237 std::string GetPluginsRoot();
238 std::string GetFontsRoot();
240 std::string GetVcxprojPath();
241 std::string GetMSBuildPath();
242 std::string GetEngineDependenciesPath();
244 BlamProjectInfo GetProjectInfoForEngine();
246 std::string GetTagFilePathFromTagPath(std::string tag_path);
std::string GetCacheRoot()
Definition: BlamProject.cpp:247
std::string GetContentRoot()
Definition: BlamProject.cpp:199
bool LoadFromDisk(std::string file_path)
Definition: BlamProject.cpp:27
std::string disk_path
The path of this node on disk, relative or absolute, ex: ./tags/levels/multi/forge_halo
Definition: projects.h:81
BlamProjectUserConfig * project_info_user
Definition: projects.h:211
std::vector< BlamTagTreeNode * > children
Any child nodes within this node, will only apply for Folder nodes.
Definition: projects.h:78
GUERILLA_LIB_API BlamProject * LoadProject(std::string file_path)
Loads a project file from disk and prepares it for use.
Definition: projects.cpp:23
std::string GetMSBuildPath()
Definition: BlamProject.cpp:293
std::string GetTagsRoot()
Definition: BlamProject.cpp:211
Class representing a Blamite Project.
Definition: projects.h:145
bool Save()
Definition: BlamProject.cpp:85
int format_version
Definition: projects.h:155
BlamTagTreeNode(BlamProject *_project, std::string file_path, bool ignore_folder_name_in_hierarchy, BlamTagTreeNode *parent=nullptr)
Constructs a new tag tree node.
Definition: BlamTagTreeNode.cpp:8
GUERILLA_LIB_API BlamProject * CreateProject(std::string name)
Definition: projects.cpp:98
GUERILLA_LIB_API std::vector< BlamProject * > GetLoadedProjects()
Retrieves the list of loaded projects.
Definition: projects.cpp:93
BlamProject * active_project
Definition: projects.cpp:11
std::string GetEngineDependenciesPath()
Definition: BlamProject.cpp:303
std::string GetDataRoot()
Definition: BlamProject.cpp:235
std::string class_name_short
The plugin/tag class this tag uses. Will be nullptr if the node is a directory or if the tag has no p...
Definition: projects.h:83
bool path_exists
Whether or not the path associated with this node exists.
Definition: projects.h:74
std::string GetPluginsRoot()
Definition: BlamProject.cpp:259
void Refresh()
Refreshes the node for any changes to its children on disk.
Definition: BlamTagTreeNode.cpp:84
#define GUERILLA_LIB_API
Definition: projects.h:9
Namespace containing functions for working with project files.
Definition: projects.h:263
GUERILLA_LIB_API void SetCurrentProject(BlamProject *project)
Definition: projects.cpp:18
std::string display_name
The display name of this node, ex: forge_halo
Definition: projects.h:82
bool Load(std::string file_path)
Definition: BlamProjectUserConfig.cpp:13
std::string GetTagFilePathFromTagPath(std::string tag_path)
Definition: BlamProject.cpp:471
PROJECT_SECTION(cpp_script_info, { std::string vcxproj_path="";std::string engine_dependencies_path="";std::string msbuild_path="msbuild.exe";})
BlamTagTreeNode * hierarchy_root
The root node for the project's tag hierarchy.
Definition: projects.h:212
std::vector< BlamPlugin * > plugins
The list of loaded plugins.
Definition: plugins.cpp:9
~BlamTagTreeNode()
Destroys a tag tree node.
Definition: BlamTagTreeNode.cpp:79
std::string GetFontsRoot()
Definition: BlamProject.cpp:271
BlamProject()
Definition: BlamProject.cpp:16
std::string GetMoviesRoot()
Definition: BlamProject.cpp:223
GUERILLA_LIB_API std::string GetProjectsRoot()
Definition: projects.cpp:118
#define PROJECT_FILE_FORMAT_VERSION
The current project file format version.
Definition: projects.h:41
bool is_folder
Indicates whether the node represents a file. If this is false, then the node represents a file.
Definition: projects.h:73
bool BuildTagHierarchy()
Builds the tag hierarchy for the project.
Definition: BlamProject.cpp:178
bool IsLoaded()
Definition: BlamProject.cpp:173
GUERILLA_LIB_API void UnloadProjects()
Releases all project data loaded into memory.
Definition: projects.cpp:83
bool IsLoaded()
Definition: BlamProjectUserConfig.cpp:57
BlamProject * project
The project this node belongs to.
Definition: projects.h:76
std::string project_root
The root folder for the project.
Definition: projects.h:157
BlamTagTreeNode * GetHierarchyNodeFromTagPath(std::string tag_path)
Definition: BlamProject.cpp:483
std::vector< BlamProject * > loaded_projects
Definition: projects.cpp:10
std::string project_name
The name of the project.
Definition: projects.h:156
BlamTagTreeNode * parent
The parent node of this node. If this item is the root node, then this will be nullptr.
Definition: projects.h:77
BlamProjectInfo GetProjectInfoForEngine()
Definition: BlamProject.cpp:439
std::string hierarchy_path
The path of this node within the hierarchy, ex: /levels/multi/forge_halo
Definition: projects.h:80
std::string file_path
Definition: projects.h:154
#define PROJECT_FILE_USER_SUFFIX
Definition: projects.h:18
#define PROJECT_FILE_EXTENSION
Definition: projects.h:15
bool Save()
Definition: BlamProjectUserConfig.cpp:62
#define PROJECT_SECTION(name, fields)
Macro used to aid in the creation of BlamProjectInfo sections.
Definition: projects.h:31
Class representing a tag tree node.
Definition: projects.h:52
std::string GetVcxprojPath()
Definition: BlamProject.cpp:283
#define BLAM_PROJECTS_DIR
Definition: projects.h:21
GUERILLA_LIB_API void LoadProjects()
Attempts to load all available project folders.
Definition: projects.cpp:40
~BlamProject()
Definition: BlamProject.cpp:21
BlamProjectUserConfig(BlamProject *_project)
Definition: BlamProjectUserConfig.cpp:8
Definition: projects.h:116
GUERILLA_LIB_API BlamProject * GetCurrentProject()
Definition: projects.cpp:13
std::vector< BlamTagTreeNode * > GetBulkNodeList()
Retrieves a bulk list of all tag nodes within this node.
Definition: BlamTagTreeNode.cpp:146