GDevelop-extensions
GDevelop-extensions copied to clipboard
New extension: <3D_Physics>
Description
An extension adding 3D physics for models
How to use the extension
The extension allows adding 3D physics to models. To use it, add the physics behavior to the desired object, configure its physical parameters such as mass, friction, restitution, etc., then add shapes for collision handling in the actions.
Types of shapes available:
- Box
- Sphere
- Cylinder
- Capsule
The extension also provides:
- Impulse and force for pushing objects
- Joins for connecting physical bodies
- Sleep mode for optimization and manual suspension of physics calculation for an object
- Collision checking between two objects
Controls: Add a separate behavior to the player, then in the actions, set the movement force and direction, and the jump force.
Checklist
- [X] I've followed all of the best practices.
- [X] I confirm that this extension can be integrated to this GitHub repository, distributed and MIT licensed.
- [X] I am aware that the extension may be updated by anyone, and do not need my explicit consent to do so.
What tier of review do you aim for your extension?
Community (Unreviewed)
Example file
Extension file
❗ An internal error has occurred. See logs at https://github.com/GDevelopApp/GDevelop-extensions/actions/runs/8392063336.
!update Physics3D.json
❗ An internal error has occurred. See logs at https://github.com/GDevelopApp/GDevelop-extensions/actions/runs/8392094637.
!update Physics3D.zip
Can't update the extension, as it doesn't pass automatic tests:
❌ 1 Error found in extension 'Physics3D':
⟶ ❌ [JavaScript disallowed properties]: Found disallowed properties in extension 'Physics3D':
{
allowedProperties: [
'getVariables',
'getLayer',
'getGame',
'getBackgroundColor',
'getName',
'createObject',
'createObjectsFrom',
'setBackgroundColor',
'sceneJustResumed',
'requestChange',
'hasLayer',
'enableDebugDraw'
],
disallowedProperty: '__physics3D',
objectName: 'runtimeScene'
}
{
allowedProperties: [
'getVariables',
'getLayer',
'getGame',
'getBackgroundColor',
'getName',
'createObject',
'createObjectsFrom',
'setBackgroundColor',
'sceneJustResumed',
'requestChange',
'hasLayer',
'enableDebugDraw'
],
disallowedProperty: '__CannonJS',
objectName: 'runtimeScene'
}
❌ 1 Error found in extensions - please fix it before generating the registry.
!update Physics3D.zip
Can't update the extension, as it doesn't pass automatic tests:
❌ 1 Error found in extension 'Physics3D':
⟶ ❌ [JavaScript disallowed properties]: Found disallowed properties in extension 'Physics3D':
{
allowedProperties: [
'getVariables',
'getLayer',
'getGame',
'getBackgroundColor',
'getName',
'createObject',
'createObjectsFrom',
'setBackgroundColor',
'sceneJustResumed',
'requestChange',
'hasLayer',
'enableDebugDraw'
],
disallowedProperty: '__physics3D',
objectName: 'runtimeScene'
}
{
allowedProperties: [
'getVariables',
'getLayer',
'getGame',
'getBackgroundColor',
'getName',
'createObject',
'createObjectsFrom',
'setBackgroundColor',
'sceneJustResumed',
'requestChange',
'hasLayer',
'enableDebugDraw'
],
disallowedProperty: '__CannonJS',
objectName: 'runtimeScene'
}
❌ 1 Error found in extensions - please fix it before generating the registry.
@TheAvIGOLD to get that test to pass, you need to add __physics3D
and __CannonJS
to allowedProperties
inside /scripts/lib/ExtensionsValidatorExceptions.js
.
https://github.com/GDevelopApp/GDevelop-extensions/blob/main/scripts/lib/ExtensionsValidatorExceptions.js
!update Physics3D.zip
Can't update the extension, as it doesn't pass automatic tests:
❌ 1 Error found in extension 'Physics3D':
⟶ ❌ [JavaScript disallowed properties]: Found disallowed properties in extension 'Physics3D':
{
allowedProperties: [
'getVariables',
'getLayer',
'getGame',
'getBackgroundColor',
'getName',
'createObject',
'createObjectsFrom',
'setBackgroundColor',
'sceneJustResumed',
'requestChange',
'hasLayer',
'enableDebugDraw'
],
disallowedProperty: '__physics3D',
objectName: 'runtimeScene'
}
{
allowedProperties: [
'getVariables',
'getLayer',
'getGame',
'getBackgroundColor',
'getName',
'createObject',
'createObjectsFrom',
'setBackgroundColor',
'sceneJustResumed',
'requestChange',
'hasLayer',
'enableDebugDraw'
],
disallowedProperty: '__CannonJS',
objectName: 'runtimeScene'
}
❌ 1 Error found in extensions - please fix it before generating the registry.
Thank you for submitting an extension.
We plan to create an extension directly in GDevelop using the Jolt physics engine in the near future. Do you still want a review of this extension?
Thank you for submitting an extension.
We plan to create an extension directly in GDevelop using the Jolt physics engine in the near future. Do you still want a review of this extension?
I think this extension can be an alternative to your extension. Just point out that this extension use Cannon JS engine.
Physics3D.zip When reviewing the extension, please use the latest version