You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-11 13:10:58 +00:00
Create GDExtension clases for PhysicsServer3D
* Allows creating a GDExtension based 3D Physics Server (for Bullet, PhysX, etc. support) * Some changes on native struct binding for PhysicsServer This allows a 3D Physics server created entirely from GDExtension. Once it works, the idea is to port the 2D one to it.
This commit is contained in:
@@ -33,6 +33,22 @@
|
||||
#include "core/config/project_settings.h"
|
||||
#include "core/string/print_string.h"
|
||||
|
||||
void PhysicsServer3DRenderingServerHandler::set_vertex(int p_vertex_id, const void *p_vector3) {
|
||||
GDVIRTUAL_REQUIRED_CALL(_set_vertex, p_vertex_id, p_vector3);
|
||||
}
|
||||
void PhysicsServer3DRenderingServerHandler::set_normal(int p_vertex_id, const void *p_vector3) {
|
||||
GDVIRTUAL_REQUIRED_CALL(_set_normal, p_vertex_id, p_vector3);
|
||||
}
|
||||
void PhysicsServer3DRenderingServerHandler::set_aabb(const AABB &p_aabb) {
|
||||
GDVIRTUAL_REQUIRED_CALL(_set_aabb, p_aabb);
|
||||
}
|
||||
|
||||
void PhysicsServer3DRenderingServerHandler::_bind_methods() {
|
||||
GDVIRTUAL_BIND(_set_vertex, "vertex_id", "vertices");
|
||||
GDVIRTUAL_BIND(_set_normal, "vertex_id", "normals");
|
||||
GDVIRTUAL_BIND(_set_aabb, "aabb");
|
||||
}
|
||||
|
||||
PhysicsServer3D *PhysicsServer3D::singleton = nullptr;
|
||||
|
||||
void PhysicsDirectBodyState3D::integrate_forces() {
|
||||
|
||||
Reference in New Issue
Block a user