mirror of
https://github.com/scp-fs2open/fs2open.github.com.git
synced 2026-11-12 19:06:09 -10:00
* chore: vendor ImPlot library
Adds ImPlot as a build dependency, to be used for the upcoming ImGui
frame profiler overlay's frametime graph and pie chart.
* feat: add ImGui frame profiler overlay
Replaces the old text-dump frame profile display (-profile_frame_time)
with a runtime-toggleable ImGui/ImPlot overlay showing average/median
frametime, a scrolling frametime graph, and a pie chart of the top
contributors to frame time. Toggled via a new "Frame Profiler Overlay"
option, which also seeds from -profile_frame_time for backward
compatibility and now drives frame profiling collection at runtime
instead of only at startup.
* Add graphics and Vulkan debug stats to ImGui profiler overlay
- Integrated per-backend diagnostic counters into the ImGui frame profiler overlay, triggered by `-gr_debug`.
- Consolidated and cleaned up Vulkan rendering state and descriptor management for compatibility with ImGui's Vulkan pipeline.
- Enabled uniform buffer and draw statistics reporting for enhanced performance insights during debugging.
* Update ImPlot to v1.1 WIP and improve internal consistency
- Adjust copyright notices for extended license coverage (2025-2026).
- Modernize constants with `constexpr` replacements, improving type safety and clarity.
- Enforce `nullptr` usage over `NULL` throughout, aligning with modern C++ practices.
- Add various enhancements to ImPlot legends, markers, and axes behavior.
- Introduce additional helper methods for time handling and timestamp calculations.
- Address UI and typo improvements in comments and documentation, refining accuracy.
* Refactor frame profiler to use per-category self-time accumulation
- Introduced `accumulate_self_times` for single-pass exclusive time computation, improving performance and accuracy.
- Updated `FrameProfiler` and overlay snapshot logic to leverage `Category`'s stable `getId` and `getCount`.
- Replaced pie chart with a stacked bar for frame budget visualization, optimizing rendering cost.
- Cached `get_tid` and `get_pid` with thread-local storage to minimize syscall overhead.
- Added support for unit testing frame profiling functionality and included new test cases.
- Improved code comments and clarified documentation.
* Use dynamic uniform buffers to stop per-draw descriptor set churn in Vulkan
The Material and PerDraw descriptor sets were reallocated and fully rewritten on
essentially every draw call. model_draw_list::render_buffer rebinds ModelData with
a fresh uniform buffer offset for each queued draw, and that offset was part of the
Material set's memoization key, so the cache in VulkanDrawManager::applyMaterial
missed every time - taking a frame-pool allocation, a full template write, the
16-entry material texture resolution and a vkUpdateDescriptorSets with it.
GenericData/Matrices did the same to the PerDraw set. renderShadowDraw was worse
still: all three sets allocated and rewritten per shadow draw, with no memoization
at all.
A large asteroid field (Solaris m21) measured 2566 descriptor sets and 19107
descriptor writes per frame at 1606 model draws, and grew an extra descriptor pool
chunk every frame.
Declare the bindings whose offset moves per draw - MaterialBinding::ModelData,
MaterialBinding::ShadowMapData, PerDrawBinding::GenericData and
PerDrawBinding::Matrices - as eUniformBufferDynamic. DescriptorWriter::setBuffer
now splits a dynamic binding's offset out of the descriptor, writing
{buffer, 0, range} and stashing the offset for vkCmdBindDescriptorSets'
pDynamicOffsets, so an offset-only change leaves the set's contents identical and
the memoization caches start hitting. Shader sources are unchanged.
VulkanStateTracker::bindDescriptorSet now compares the dynamic offsets as well as
the set handle. This is required, not an optimization: the common case is now the
same set rebound with a new offset, and the old handle-only redundancy check would
have skipped that bind and fed every draw the previous draw's uniforms.
renderShadowDraw memoizes its three sets the way applyMaterial does. It does not
invalidate applyMaterial's caches - those record what a set contains, the shadow
pass allocates its own sets rather than overwriting theirs, and it binds through
the state tracker, so the next material cache hit still rebinds correctly.
Also switch allocateFrameSet to the non-allocating allocateDescriptorSets overload;
the vector-returning one heap-allocated once per set, thousands of times a frame.
MAX_SETS_PER_POOL stays at 1024 - the per-frame pool growth it used to log was a
symptom of the churn, and one chunk now covers the scene outright.
Measured on that mission in a Debug build, A/B on the same tree with and without
this change:
descriptor sets/frame @ ~1370 draws 2566 -> 250-345
descriptor writes/frame 19107 -> ~1700-2300
median frametime 92.9/83.6 ms -> 72.0/66.5 ms
Render Buffer (profiler overlay) 24.68 ms (30.8%) -> 12.73 ms (18.4%)
Build Shadow Map 5.44 ms -> off the top-5 entirely
Release builds already inlined most of this away and are unchanged, as expected.
Verified with the validation layers (sync validation enabled): no new VUIDs versus
the same build without the change.
Co-Authored-By: Claude Opus 5 <[email protected]>
* Refactor Vulkan descriptor set binding to reduce dynamic offset churn
- Consolidated dynamic descriptor offset logic into `DescriptorWriter::bindSets`, replacing repetitive `vkCmdBindDescriptorSets` patterns across Vulkan modules.
- Eliminated redundant descriptor binding operations for Material and PerDraw sets by centralizing logic in `bindSets`.
- Simplified descriptors by directly splitting offset changes from descriptor contents, avoiding unnecessary updates.
- Updated comments and documentation to align with the new approach while maintaining reference consistency.
- Applied optimizations across Vulkan modules (`VulkanPostProcessing`, `VulkanDescriptorManager`, etc.) to reduce per-draw overhead and improve readability.
* Enable primitive restart for supported topologies in Vulkan pipeline
- Added `topologySupportsPrimitiveRestart` to determine restart eligibility for each topology.
- Updated `primitiveRestartEnable` to be conditionally set based on topology, addressing compatibility issues with Metal/MoltenVK.
- Prevented crash scenarios on macOS by ensuring pipelines are valid for strip/fan topologies requiring primitive restart.
* Enable VK_KHR_portability_subset for compatibility
* Replace exception with sentinel for non-dynamic Vulkan descriptor bindings
- Introduced `DYNAMIC_SLOT_INVALID` sentinel to replace the throw in `dynamic_offset_slot` for MSVC compatibility.
- Added `static_assert` checks to validate binding constants, ensuring compile-time validation for dynamic offsets.
- Updated comments to clarify design rationale and avoid potential misuse.
* Add memory statistics and tracking to profiler overlay
* fix ci issues
* Add OpenGL memory statistics to the profiler overlay
The memory panel showed no texture bytes and no geometry bytes under
OpenGL. Only the depth renderbuffers went into the render target group.
All three groups now give a value.
Textures: GL_texture_bytes_used holds the bytes of every live texture
cache slot. opengl_texture_release_bytes() removes the bytes of a slot at
each site that drops its texture data. The bitmap render targets record
the bytes of their color texture.
Geometry: the unused GL_vertex_data_in global becomes
GL_geometry_bytes_used, which counts only vertex and index buffers. This
matches the geometry group of the Vulkan backend.
gr_opengl_delete_buffer() sets the size of the buffer to 0, because
opengl_destroy_all_buffers() calls it a second time for a buffer that the
game already deleted.
Render targets: three new functions add the scene textures, the
post-processing textures, and the shadow map to the group. They sum the
bytes at the moment of the call from the textures that exist, thus they
need no bookkeeping at the create and delete sites.
Co-Authored-By: Claude Opus 5 <[email protected]>
* Fix profiler overlay crash on a category that is not a static
The category registry kept a Category pointer for each id. The comment said that all categories
are global statics, but that is not correct. The Lua API tracing_category constructs a Category
and copies it into a script-owned object. The registry then kept a pointer to the dead temporary.
build_overlay_snapshot called getName() on that pointer, made an SCP_string from the garbage
char*, and the process stopped with SIGABRT.
The registry now keeps the name by value and never keeps a Category pointer. getById() becomes
getNameById(), which is all that build_overlay_snapshot needs. A copy of a Category keeps the id
of the original, which stays correct because the id only selects a name.
Add two tests: one shows that the name stays available after the Category object is dead, and one
drives the full path that failed, from processEvent to the overlay snapshot.
Co-Authored-By: Claude Opus 5 <[email protected]>
* Replace category pointers with IDs to prevent use-after-free
- Updated `trace_event` to store `category_id` instead of a pointer to prevent dangling references to category objects that may already be destroyed.
- Modified all references to category names to use `Category::getNameById()` instead of dereferencing pointers.
- Expanded memory statistics in the profiler overlay with new sound, Lua, and OS-level memory usage tracking.
- Added new tests to verify proper use of category IDs in frame profiling and event tracing.
- Improved memory safety and stability across tracing, profiling, and overlay systems.
* Refactor profiler overlay to use snapshot-based frame timing
* Address review feedback on the profiler overlay
Skip complete::end for a scope that did not start. This fixes a crash
when Lua turns the overlay on while a scope is open. Track the GPU begin
event so that turning the overlay off mid-scope still closes it.
Use XSTR 1936 and 1937 for the overlay option. Master now uses 1932
and 1933.
Remove the default value of dynamicOffsets in bindDescriptorSet. Use the
PerDraw binding constants in the PerDraw key.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
* Use wall-clock frame time and read the history without a copy
The Avg and FPS line used traced self-time, which reads too high.
Measure the time between overlay frames instead. Draw the graph with
PlotLineG so the history deque needs no per-frame copy.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
* Address second round of review feedback on the profiler overlay
- Make the category registry thread-safe and give categories with the
same name one id, so the registry does not grow without limit.
- Add tests that toggle the profiler inside an open trace scope.
- Correct the next free XSTR id note to 1938.
- Use the existing Windows include block for psapi.h in osapi.cpp.
- Use list_range in ship_get_num_ships() and shorten some comments.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
* Return size_t from Category::getCount() and tidy the registry code
- Use structured bindings and std::scoped_lock in the category registry.
- Return size_t from getCount() and update its callers and tests.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
* Address third round of review feedback on the profiler overlay
- Move the overlay option strings to XSTR 1940 and 1941. The touch
overlay on master uses 1936 to 1939.
- Give FrameProfiler the main thread ID when it is made. Before, it
used the thread of the first event, which was a race.
- Let mouse motion go to the game while the pointer is over the
overlay, so that mouse flight does not stop there.
- Find the dynamic bindings of the PerDraw key with
dynamic_offset_slot(), as the other call sites do.
- Make disable_inside_open_scope count the GPU timestamp queries, so
that it fails if end() does not close the GPU event.
- Make the copy test copy the category, not bind a reference.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
* apply review suggestions
---------
Co-authored-by: Claude Opus 5 <[email protected]>
372 lines
11 KiB
C++
372 lines
11 KiB
C++
#ifndef _SCRIPTING_H
|
|
#define _SCRIPTING_H
|
|
|
|
#include "globalincs/globals.h"
|
|
#include "globalincs/pstypes.h"
|
|
|
|
#include "graphics/2d.h"
|
|
#include "scripting/ade.h"
|
|
#include "scripting/ade_args.h"
|
|
#include "scripting/hook_conditions.h"
|
|
#include "scripting/lua/LuaFunction.h"
|
|
#include "utils/event.h"
|
|
|
|
//**********Scripting languages that are possible
|
|
#define SC_LUA (1<<0)
|
|
|
|
//*************************Scripting structs*************************
|
|
#define SCRIPT_END_LIST NULL
|
|
|
|
namespace scripting {
|
|
struct ScriptingDocumentation;
|
|
class HookBase;
|
|
}
|
|
|
|
struct image_desc
|
|
{
|
|
char fname[MAX_FILENAME_LEN];
|
|
int handle;
|
|
};
|
|
|
|
struct script_function {
|
|
int language = 0;
|
|
luacpp::LuaFunction function;
|
|
};
|
|
|
|
//-WMC
|
|
struct script_hook
|
|
{
|
|
//Override
|
|
script_function override_function;
|
|
|
|
//Actual hook
|
|
script_function hook_function;
|
|
};
|
|
|
|
extern bool script_hook_valid(script_hook *hook);
|
|
|
|
//**********Main Conditional Hook stuff
|
|
|
|
#define MAX_HOOK_CONDITIONS 8
|
|
|
|
// Conditionals
|
|
enum ConditionalType {
|
|
//These conditionals must ONLY contain global conditions.
|
|
//That is, conditions that do not depend on anything specific per-hook (such as a ship firing a weapon),
|
|
//but only conditions that can evaluate exclusively on a global state, identically for all actions.
|
|
//Per-Hook specific conditionals are added through hook_conditions.h/.cpp and the respective template argument of the hook.
|
|
CHC_NONE = -1,
|
|
CHC_MISSION,
|
|
CHC_STATE,
|
|
CHC_CAMPAIGN,
|
|
CHC_KEYPRESS,
|
|
CHC_VERSION,
|
|
CHC_APPLICATION,
|
|
CHC_MULTI_SERVER,
|
|
CHC_VR_MODE
|
|
};
|
|
|
|
//Actions
|
|
enum ConditionalActions : int32_t {
|
|
CHA_NONE = -1,
|
|
CHA_ONFRAME,
|
|
CHA_SPLASHSCREEN,
|
|
CHA_HUDDRAW,
|
|
CHA_GAMEINIT,
|
|
CHA_SIMULATION,
|
|
|
|
// DO NOT ADD NEW HOOKS HERE. THESE HOOKS ARE EXCLUSIVELY FOR COMPATIBILITY WITH NON-CONDITIONAL GLOBAL HOOKS
|
|
// There is a new Lua Hook API, see hook_api.h
|
|
// There you use either scripting::Hook for non-overridable or scripting::OverridableHook for overridable hooks
|
|
// while also having the option to document when the hook is called and what hook variables are set for it.
|
|
|
|
CHA_LAST = CHA_SIMULATION
|
|
};
|
|
|
|
// management stuff
|
|
void scripting_state_init();
|
|
void scripting_state_close();
|
|
void scripting_state_do_frame(float frametime, bool doKeys);
|
|
|
|
/**
|
|
* @brief Lua heap usage snapshot, for the profiler overlay's memory panel
|
|
*
|
|
* @details Reports Lua's own GC byte count for the main script state (see lua_gc(),
|
|
* LUA_GCCOUNT/LUA_GCCOUNTB). Invalid before the Lua state is created or after it is torn down.
|
|
*/
|
|
struct scripting_memory_stats {
|
|
bool valid = false;
|
|
size_t lua_heap_bytes = 0;
|
|
};
|
|
scripting_memory_stats scripting_get_memory_stats();
|
|
|
|
const scripting::HookBase* scripting_string_to_action(const char* action);
|
|
ConditionalType scripting_string_to_condition(const char* condition);
|
|
|
|
struct script_condition
|
|
{
|
|
ConditionalType condition_type;
|
|
SCP_string condition_string;
|
|
// stores values evaluated at hook load to optimize later condition checking.
|
|
// currently mostly olg done for the highest impact condition types, according to performance profiling
|
|
// the exact type of information stored varries between hook types.
|
|
// CHC_STATE, CHC_OBJECTTYPE - stores the value of enum matching the name requested by the condition string.
|
|
// CHC_SHIPCLASS, CHC_WEAPONCLASS - stores the index of the info object requested by the condition
|
|
// CHC_VERSION, CHC_APPLICATION - stores validity of the check in 1 for true or 0 for false, as the condition will not change after load.
|
|
// CHC_KEYPRESS - stores the keycode
|
|
// see ConditionedHook::AddCondition for exact implimentation
|
|
int condition_cached_value;
|
|
};
|
|
|
|
class script_action {
|
|
public:
|
|
SCP_vector<script_condition> global_conditions;
|
|
SCP_vector<std::unique_ptr<scripting::EvaluatableCondition>> local_conditions;
|
|
|
|
script_hook hook;
|
|
|
|
bool ConditionsValid(const std::any& local_condition_data) const;
|
|
};
|
|
|
|
//**********Main script_state function
|
|
class script_state
|
|
{
|
|
private:
|
|
char StateName[32];
|
|
|
|
int Langs;
|
|
struct lua_State *LuaState;
|
|
const struct script_lua_lib_list *LuaLibs;
|
|
|
|
//Utility variables
|
|
SCP_vector<image_desc> ScriptImages;
|
|
SCP_unordered_map<int, SCP_vector<script_action>> ConditionalHooks;
|
|
// Scripts can add new hooks at runtime; we collect all hooks to be added here and add them at the end of the current
|
|
// frame to avoid corrupting any iterators that the script system may be using.
|
|
SCP_unordered_map<int, SCP_vector<script_action>> AddedHooks;
|
|
|
|
SCP_vector<script_function> GameInitFunctions;
|
|
|
|
// Stores references to the Lua values for the hook variables. Uses a raw reference since we do not need the more
|
|
// advanced features of LuaValue
|
|
// values are a vector to provide a stack of values. This is necessary to ensure consistent behavior if a scripting
|
|
// hook is called from within another script (e.g. calls to createShip)
|
|
SCP_unordered_map<SCP_string, SCP_vector<luacpp::LuaReference>> HookVariableValues;
|
|
|
|
// ActiveActions lets code that might run scripting hooks know whether any scripts are even registered for it.
|
|
// AssayActions is responsible for keeping it up to date.
|
|
SCP_unordered_map<int, bool> ActiveActions;
|
|
|
|
void ParseChunkSub(script_function& out_func, const char* debug_str=NULL);
|
|
|
|
void SetLuaSession(struct lua_State *L);
|
|
|
|
static void OutputLuaDocumentation(scripting::ScriptingDocumentation& doc,
|
|
const scripting::DocumentationErrorReporter& errorReporter);
|
|
|
|
public:
|
|
//***Init/Deinit
|
|
script_state(const char *name);
|
|
|
|
script_state(const script_state&) = delete;
|
|
script_state& operator=(script_state &i) = delete;
|
|
|
|
~script_state();
|
|
|
|
/**
|
|
* @brief Resets the lua state and frees all resources
|
|
*/
|
|
void Clear();
|
|
|
|
//***Internal scripting stuff
|
|
int LoadBm(const char* name);
|
|
void UnloadImages();
|
|
|
|
lua_State *GetLuaSession(){return LuaState;}
|
|
|
|
//***Init functions for langs
|
|
int CreateLuaState();
|
|
|
|
//***Get data
|
|
scripting::ScriptingDocumentation OutputDocumentation(const scripting::DocumentationErrorReporter& errorReporter);
|
|
|
|
//***Moves data
|
|
//void MoveData(script_state &in);
|
|
|
|
template<typename T>
|
|
void SetHookVar(const char *name, char format, T&& value);
|
|
void SetHookObject(const char *name, object *objp);
|
|
void SetHookObjects(int num, ...);
|
|
void RemHookVar(const char *name);
|
|
void RemHookVars(std::initializer_list<SCP_string> names);
|
|
|
|
const SCP_unordered_map<SCP_string, SCP_vector<luacpp::LuaReference>>& GetHookVariableReferences();
|
|
|
|
//***Hook creation functions
|
|
template <typename T>
|
|
bool EvalStringWithReturn(const char* string, const char* format = nullptr, T* rtn = NULL,
|
|
const char* debug_str = nullptr);
|
|
bool EvalString(const char* string, const char* debug_str = nullptr);
|
|
void ParseChunk(script_hook *dest, const char* debug_str=NULL);
|
|
void ParseGlobalChunk(ConditionalActions hookType, const char* debug_str=nullptr, const std::shared_ptr<scripting::HookBase> parentHook=nullptr);
|
|
bool ParseCondition(const char *filename="<Unknown>");
|
|
void AddConditionedHook(int action_id, script_action hook);
|
|
void AssayActions();
|
|
bool IsActiveAction(int hookId);
|
|
|
|
void AddGameInitFunction(script_function func);
|
|
|
|
//***Hook running functions
|
|
template <typename T>
|
|
int RunBytecode(const script_function& hd, char format = '\0', T* data = nullptr);
|
|
int RunBytecode(const script_function& hd);
|
|
bool IsOverride(const script_hook &hd);
|
|
int RunCondition(int action_type, const std::any& local_condition_data);
|
|
bool IsConditionOverride(int action_type, const std::any& local_condition_data);
|
|
|
|
void RunInitFunctions();
|
|
|
|
void ProcessAddedHooks();
|
|
|
|
//*****Other functions
|
|
static script_state* GetScriptState(lua_State* L);
|
|
util::event<void, lua_State*> OnStateDestroy;
|
|
};
|
|
|
|
template<typename T>
|
|
void script_state::SetHookVar(const char *name, char format, T&& value)
|
|
{
|
|
if(format == '\0')
|
|
return;
|
|
|
|
if(LuaState != nullptr)
|
|
{
|
|
char fmt[2] = {format, '\0'};
|
|
::scripting::ade_set_args(LuaState, fmt, std::forward<T>(value));
|
|
auto reference = luacpp::UniqueLuaReference::create(LuaState);
|
|
lua_pop(LuaState, 1); // Remove object value from the stack
|
|
|
|
HookVariableValues[name].push_back(std::move(reference));
|
|
}
|
|
}
|
|
|
|
template <typename T>
|
|
bool script_state::EvalStringWithReturn(const char* string, const char* format, T* rtn, const char* debug_str)
|
|
{
|
|
using namespace luacpp;
|
|
|
|
size_t string_size = strlen(string);
|
|
char lastchar = string[string_size - 1];
|
|
|
|
if (string[0] == '{') {
|
|
return false;
|
|
}
|
|
|
|
if (string[0] == '[' && lastchar != ']') {
|
|
return false;
|
|
}
|
|
|
|
size_t s_bufSize = string_size + 8;
|
|
std::string s;
|
|
s.reserve(s_bufSize);
|
|
if (string[0] != '[') {
|
|
if (rtn != nullptr) {
|
|
s = "return ";
|
|
}
|
|
s += string;
|
|
} else {
|
|
s.assign(string + 1, string + string_size);
|
|
}
|
|
|
|
SCP_string debug_name;
|
|
if (debug_str == nullptr) {
|
|
debug_name = "String: ";
|
|
debug_name += s;
|
|
} else {
|
|
debug_name = debug_str;
|
|
}
|
|
|
|
try {
|
|
auto function = LuaFunction::createFromCode(LuaState, s, debug_name);
|
|
function.setErrorFunction(LuaFunction::createFromCFunction(LuaState, scripting::ade_friendly_error));
|
|
|
|
try {
|
|
auto ret = function.call(LuaState);
|
|
|
|
if (rtn != nullptr && ret.size() >= 1) {
|
|
auto stack_start = lua_gettop(LuaState);
|
|
|
|
auto val = ret.front();
|
|
val.pushValue(LuaState);
|
|
|
|
scripting::internal::Ade_get_args_skip = stack_start;
|
|
scripting::internal::Ade_get_args_lfunction = true;
|
|
scripting::ade_get_args(LuaState, format, rtn);
|
|
}
|
|
} catch (const LuaException&) {
|
|
lua_pop(LuaState, 1);
|
|
|
|
return false;
|
|
}
|
|
} catch (const LuaException& e) {
|
|
LuaError(GetLuaSession(), "%s", e.what());
|
|
|
|
lua_pop(LuaState, 1);
|
|
|
|
return false;
|
|
}
|
|
|
|
lua_pop(LuaState, 1);
|
|
|
|
return true;
|
|
}
|
|
|
|
template <typename T>
|
|
int script_state::RunBytecode(const script_function& hd, char format, T* data)
|
|
{
|
|
using namespace luacpp;
|
|
|
|
if (!hd.function.isValid()) {
|
|
return 1;
|
|
}
|
|
|
|
GR_DEBUG_SCOPE("Lua code");
|
|
|
|
try {
|
|
auto ret = hd.function.call(LuaState);
|
|
|
|
if (data != nullptr && ret.size() >= 1) {
|
|
auto stack_start = lua_gettop(LuaState);
|
|
|
|
auto val = ret.front();
|
|
val.pushValue(LuaState);
|
|
|
|
char fmt[2] = {format, '\0'};
|
|
scripting::internal::Ade_get_args_skip = stack_start;
|
|
scripting::internal::Ade_get_args_lfunction = true;
|
|
scripting::ade_get_args(LuaState, fmt, data);
|
|
|
|
// Reset stack again
|
|
lua_settop(LuaState, stack_start);
|
|
}
|
|
} catch (const LuaException&) {
|
|
return 0;
|
|
}
|
|
|
|
return 1;
|
|
}
|
|
|
|
//**********Script registration functions
|
|
void script_init();
|
|
|
|
//**********Script globals
|
|
extern class script_state Script_system;
|
|
extern bool Output_scripting_meta;
|
|
extern bool Output_scripting_json;
|
|
extern bool Output_scripting_luastub;
|
|
extern bool Scripting_game_init_run;
|
|
|
|
//*************************Conditional scripting*************************
|
|
|
|
#endif //_SCRIPTING_H
|