Commit Graph

35 Commits (d0a4ddfd9fcae91b75f456e57a229e9f0bc372fc)

Author SHA1 Message Date
Bastiaan Olij 7defa6f77e
Merge pull request #271 from Windfisch/fix-register-property
Fix registering properties of reference-types by applying bruvzg's patch
2019-05-02 23:00:47 +10:00
RameshRavone 761d62c9c8
Fix #272 2019-04-21 06:55:49 +05:30
Florian Jung 0b4be7bbfa Fix registering properties of reference-types by applying bruvzg's patch
bruvzg's original comment with the patch is here:
https://github.com/GodotNativeTools/godot-cpp/issues/237#issuecomment-465170294

Fixes #237.
2019-04-12 13:56:22 +02:00
bruvzg 0af05a45ce
Fix tags/cast_to for custom subclasses. 2018-11-28 00:08:45 +02:00
bruvzg be5a012ff7
Fix NULL dereferencing in get_from_variant and cast_to 2018-11-26 08:11:31 +02:00
Bastiaan Olij fc20fa3fce Implementing clang-format and applying it to all classes 2018-11-24 09:09:41 +11:00
karroffel 200bf226bf Nativescript 1.1
implemented instance binding data usage

This commit changes the way C++ wrapper classes work.
Previously, wrapper classes were merely wrapper *interfaces*.
They used the `this` pointer to store the actual foreign Godot
Object.

With the NativeScript 1.1 extension it is now possible to have
low-overhead language binding data attached to Objects.

The C++ bindings use that feature to implement *proper* wrappers
and enable regular C++ inheritance usage that way.

Some things might still be buggy and untested, but the C++
SimpleDemo works with those changes.

new and free change, custom free will crash engine, be wary

fix exporting of non-object types

fix free() crash with custom resources

added type tags and safe object casting

fix global type registration order

fix cast_to

changed build system to be more self contained

updated .gitignore

use typeid() for type tags now

fix indentation in bindings generator

remove accidentally added files

fix gitignore

Fixed up registering tool and updated godot_headers

Fix crash when calling String::split/split_floats

Was casting to the wrong object type.
Also adds parse_ints function to String with the same logic

Better warning/error macros

Change gitignore so we get our gen folders

New documentation based on nativescript 1.1

Fixed GODOT_SUBCLASS macro

Preventing crash when function returned null ptr

Adds needed include <typeinfo>

 Solves this issue #168 due to not having the include of typeinfo

Fix compile error of 'WARN_PRINT' and 'ERR_PRINT'.

cannot pass non-trivial object of type 'godot::String' to variadic function; expected type from format string was 'char *' [-Wnon-pod-varargs]

update vector3::distance_to

Remove godot_api.json as its now in the godot_headers submodule (api.json)
2018-11-07 21:23:08 +11:00
Nickolai Korshunov ef37d8d76e Merge branch 'master' of https://github.com/GodotNativeTools/godot-cpp 2018-04-25 11:40:49 +03:00
danielytics 01db553c49 adds Array::make and Dictionary::make static methods and has variadic template functions use those 2018-03-07 10:27:34 +00:00
danielytics c7b03c4132 make register_signal and auto-generated variadic funcitons use variadic templates to streamline their use 2018-03-06 21:36:20 +00:00
Nickolai Korshunov f1c35f24f6 NULL -> nullptr 2018-02-23 16:08:36 +03:00
Nickolai Korshunov 73a67b16b1 fixed some includes. replace cycle include with forward declaration 2018-02-23 14:56:36 +03:00
karroffel 8c053fc35f allow const getter functions 2018-01-19 11:49:28 +01:00
Marc Gilleron e7202cef8b Fix potential malloc(0) 2018-01-17 02:00:55 +01:00
karroffel 7dde412e26 custom types can now be used as method parameters 2018-01-14 23:03:57 +01:00
karroffel 5dac1b5887 caller-defined entry methods and string API update 2018-01-11 17:58:06 +01:00
Grosskopf 575b2f4d14 Fixed building
without this, the clang command fails
2017-12-11 16:36:03 +01:00
BastiaanOlij 0f773c2d72 Update bindings to use new Api extensions and rename Rect3->AABB 2017-11-23 22:50:05 +11:00
Bastiaan Olij 6452ba6e88 Implemented using api struct 2017-10-23 21:20:14 +11:00
Ramesh Ravone 10bb24cfbc
updated bindings 2017-10-03 16:07:34 +05:30
Ramesh Ravone 286d2aff03 Fix `_arg_cast`
This has been an issue from the day one,

A lot of people mentioned this on discord too
2017-10-03 08:29:08 +00:00
Sergey Kurson 3acd3f8991 Replaced 'char *' with 'const char *' for consistency with C API
Also makes gcc and clang happy
2017-07-27 13:43:53 +03:00
Karroffel c27af379b8 updated to use the new NativeScript and GDNative interface 2017-07-24 17:08:52 +02:00
Karroffel ee4ac30b40 template magic 2017-07-23 16:28:37 +02:00
Ramesh Ravone 36561b5853
String operator_plus fix 2017-07-22 19:16:10 +05:30
Karroffel a3bcda958e implement registering const methods
fixes #6
2017-06-21 02:26:06 +02:00
Karroffel e1f3865467 Wohoo, Ref<>s are now working 2017-06-21 02:14:54 +02:00
Karroffel 38f1ee741d some Ref WIP, memory leaks and invalid returns 2017-06-21 00:42:29 +02:00
Karroffel b6ca6a2d8e fixed ArgCast again 2017-06-19 12:05:38 +02:00
Karroffel 1c5eeee512 better Variant casting 2017-06-19 02:26:54 +02:00
Karroffel 99fceb455a updated scripting interface 2017-06-18 14:01:11 +02:00
Karroffel 51d3cecb5e updated scripting interface 2017-06-18 13:35:30 +02:00
Karroffel ad3720440e removed InputEvent and Image 2017-05-23 23:03:57 +02:00
Karroffel fad8f7c9eb made script "inheritance" less OOP 2017-05-13 13:55:04 +02:00
Karroffel cf30b0f39d rewrote binding generator in python 2017-05-12 21:53:07 +02:00