Use forward declares for vector math types

Adds operators to convert from int vector types to float vector types
as done in the upstream engine implementations.
This commit is contained in:
Rémi Verschelde
2022-02-20 11:47:57 +01:00
parent 917b0c2ca3
commit 7e3321d1b2
12 changed files with 75 additions and 38 deletions

View File

@@ -32,10 +32,12 @@
#define GODOT_VECTOR3I_HPP
#include <godot_cpp/core/math.hpp>
#include <godot_cpp/variant/string.hpp>
namespace godot {
class String;
class Vector3;
class Vector3i {
_FORCE_INLINE_ GDNativeTypePtr _native_ptr() const { return (void *)this; }
@@ -107,6 +109,7 @@ public:
inline bool operator>=(const Vector3i &p_v) const;
operator String() const;
operator Vector3() const;
inline Vector3i() {}
inline Vector3i(int32_t p_x, int32_t p_y, int32_t p_z) {