summaryrefslogtreecommitdiff
path: root/src/init.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/init.cpp')
-rw-r--r--src/init.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/init.cpp b/src/init.cpp
new file mode 100644
index 0000000..601ac2a
--- /dev/null
+++ b/src/init.cpp
@@ -0,0 +1,16 @@
+#include "WebRTCPeer.hpp"
+
+/* Godot export stuff */
+extern "C" void GDN_EXPORT godot_gdnative_init(godot_gdnative_init_options *o) {
+ godot::Godot::gdnative_init(o);
+}
+
+extern "C" void GDN_EXPORT godot_gdnative_terminate(godot_gdnative_terminate_options *o) {
+ godot::Godot::gdnative_terminate(o);
+}
+
+extern "C" void GDN_EXPORT godot_nativescript_init(void *handle) {
+ godot::Godot::nativescript_init(handle);
+
+ godot::register_class<WebRTCPeer>();
+}