update to plugin 7

This commit is contained in:
Green Sky 2024-01-07 17:04:49 +01:00
parent c3082e0140
commit 5802e7ddab
No known key found for this signature in database
3 changed files with 11 additions and 12 deletions

View File

@ -67,10 +67,8 @@ SOLANA_PLUGIN_EXPORT void solana_plugin_stop(void) {
g_crdtns.reset(); g_crdtns.reset();
} }
SOLANA_PLUGIN_EXPORT void solana_plugin_tick(float delta) { SOLANA_PLUGIN_EXPORT float solana_plugin_tick(float delta) {
(void)delta; return g_crdtns->iterate(delta);
//std::cout << "PLUGIN CRDTN TICK()\n";
g_crdtns->iterate(delta);
} }
} // extern C } // extern C

View File

@ -5,6 +5,7 @@
#include <imgui.h> #include <imgui.h>
#include <memory> #include <memory>
#include <limits>
#include <iostream> #include <iostream>
#define RESOLVE_INSTANCE(x) static_cast<x*>(solana_api->resolveInstance(#x)) #define RESOLVE_INSTANCE(x) static_cast<x*>(solana_api->resolveInstance(#x))
@ -79,10 +80,12 @@ SOLANA_PLUGIN_EXPORT void solana_plugin_stop(void) {
g_crdtn_imgui.reset(); g_crdtn_imgui.reset();
} }
SOLANA_PLUGIN_EXPORT void solana_plugin_tick(float delta) { SOLANA_PLUGIN_EXPORT float solana_plugin_tick(float delta) {
(void)delta; return std::numeric_limits<float>::max();
//std::cout << "PLUGIN CRDTNIMGUI TICK()\n"; }
g_crdtn_imgui->render();
SOLANA_PLUGIN_EXPORT float solana_plugin_render(float delta) {
return g_crdtn_imgui->render();
} }
} // extern C } // extern C

View File

@ -96,10 +96,8 @@ SOLANA_PLUGIN_EXPORT void solana_plugin_stop(void) {
g_crdtn_ts.reset(); g_crdtn_ts.reset();
} }
SOLANA_PLUGIN_EXPORT void solana_plugin_tick(float delta) { SOLANA_PLUGIN_EXPORT float solana_plugin_tick(float delta) {
(void)delta; return g_crdtn_ts->iterate(delta);
//std::cout << "PLUGIN CRDTN TICK()\n";
g_crdtn_ts->iterate(delta);
} }
} // extern C } // extern C