Commit Graph

53 Commits

Author SHA1 Message Date
e2d42db711 Also renamed the files. 2022-08-19 21:24:36 +02:00
6be9bf5dfe Cleaned up and added the skeleton modification stack implementations to the build. Also smaller fixes. 2022-08-18 15:41:28 +02:00
9757c39f05 Moved a few more core classes. 2022-08-17 17:43:49 +02:00
be16fe23ad Moved the error macros. 2022-08-17 15:14:19 +02:00
220b2db443 Moved String and related classes under a string folder in core. 2022-08-17 14:19:55 +02:00
dc9cc716c7 Moved Object related classes under core/object. 2022-08-17 13:45:14 +02:00
9555ee56b9 Moved Variant related classes under a variant folder in core. 2022-08-17 13:17:12 +02:00
388b88678e Moved container related classes in core under a new containers directory. 2022-08-17 12:53:49 +02:00
0d2fc2e9f2 Moved color to core/math. 2022-08-17 11:38:15 +02:00
d9669b0ed0 Ported form godot4: Reformat structure string operators
The order of numbers is not changed except for Transform2D. All logic is done inside of their structures (and not in Variant).
-aaronfranke
554c776e08
2022-08-16 22:46:24 +02:00
3b4b25b5f8 Add working bindings for Projection's get_projection_plane. 2022-08-16 22:33:56 +02:00
9e1588160f Now all Variant math types are structs. 2022-08-16 22:09:26 +02:00
e71e3ed897 Now Vector4, Vector4i, Projection, PoolVector4Array, PoolVector4iArray, are built in variant types. Also reordered the Variant's Type enum, renamed _RID in it to RID, fixed a few smaller issues and removed some very old compat code. 2022-08-16 21:55:56 +02:00
8c2e76840c Removed CameraMatrix, and switched to Projection. 2022-08-16 10:26:35 +02:00
608ba7826a Ported improvements to Vector2, Vector2i, Vector3, Vector3i, Vector4, and Vector4i from Godot4. 2022-08-15 16:13:21 +02:00
4cc1e75f69 Backported improvements to Quaternion from Godot4. Also bound all eligible methods. 2022-08-15 13:00:32 +02:00
007f728438 Bound all eligible transform methods. 2022-08-15 09:20:47 +02:00
5cd44e02d0 Backported the improvements to Transform from Godot4. 2022-08-14 20:35:11 +02:00
e9bb723975 Backported some improvements to Transform2D from Godot4. Also bound all eligible methods. 2022-08-14 19:19:51 +02:00
e4cad690a3 Renamed elements in Transform2D to columns. 2022-08-14 15:37:05 +02:00
d9a8497546 Renamed translate in Transform2D to translate_local. 2022-08-14 14:59:46 +02:00
662c3a7e88 Also did Rect2i. 2022-08-14 14:00:32 +02:00
899ac5cbd8 Backported some improvements to Rect2 from Godot4. Also bound all eligible methods. 2022-08-14 13:15:22 +02:00
7650103ce7 Backported some improvements to Plane from Godot4. Also bound all eligible methods. 2022-08-14 10:52:57 +02:00
170a41ca82 Backported improvements to Basis from Godot4. Also bound all eligible methods. 2022-08-14 00:18:21 +02:00
d9e094ab9a Renamed elements in Basis to rows. 2022-08-13 19:07:59 +02:00
c991043c95 Backported improvements to AABB from Godot 4. Also made sure all eligible methods are bound. 2022-08-13 18:21:54 +02:00
6523457c0f Backported the improvements to the Math class from Godot4. 2022-08-13 16:49:47 +02:00
730bce8587 Renamed Quat to Quaternion for consistency with the other engine math classes. 2022-08-13 15:22:33 +02:00
d1fe0ae433 Backported from Godot4: Fix blend animation to solve TRS track bug & blend order inconsistency - TokageItLab
b06d253920
2022-08-12 16:48:31 +02:00
22ce231a4e Backported from Godot 4: New and improved IK system for Skeleton3D
This PR and commit adds a new IK system for 3D with the Skeleton3D node
that adds several new IK solvers, as well as additional changes and functionality
for making bone manipulation in Godot easier.
This work was sponsored by GSoC 2020 and TwistedTwigleg
Full list of changes:
* Adds a SkeletonModification3D resource
  * This resource is the base where all IK code is written and executed
* Adds a SkeletonModificationStack3D resource
  * This node oversees the execution of the modifications and acts as a bridge of sorts for the modifications to the Skeleton3D node
* Adds SkeletonModification3D resources for LookAt, CCDIK, FABRIK, Jiggle, and TwoBoneIK
  * Each modification is in it's own file
* Several changes to Skeletons, listed below:
  * Added local_pose_override, which acts just like global_pose_override but keeps bone-child relationships intract
    * So if you move a bone using local_pose_override, all of the bones that are children will also be moved. This is different than global_pose_override, which only affects the individual bone
  * Internally bones keep track of their children. This removes the need of a processing list, makes it possible to update just a few select bones at a time, and makes it easier to traverse down the bone chain
  * Additional functions added for converting from world transform to global poses, global poses to local poses, and all the same changes but backwards (local to global, global to world). This makes it much easier to work with bone transforms without needing to think too much about how to convert them.
  * New signal added, bone_pose_changed, that can be used to tell if a specific bone changed its transform. Needed for BoneAttachment3D
  * Added functions for getting the forward position of a bone
* BoneAttachment3D node refactored heavily
  * BoneAttachment3D node is now completely standalone in its functionality.
    * This makes the code easier and less interconnected, as well as allowing them to function properly without being direct children of Skeleton3D nodes
  * BoneAttachment3D now can be set either using the index or the bone name.
  * BoneAttachment3D nodes can now set the bone transform instead of just following it. This is disabled by default for compatibility
  * BoneAttachment3D now shows a warning when not configured correctly
* Added rotate_to_align function in Basis
* Added class reference documentation for all changes
- TwistedTwigleg
5ffed49907
Note: It still needs some work.
2022-08-10 01:01:38 +02:00
a23d917937 use the proper _NO_DISCARD_ macro. 2022-08-08 17:36:15 +02:00
ae7d514cf3 Added set_column to Basis. 2022-08-08 01:18:58 +02:00
31603bec29 Added Vector4, Vector4i, and projection classes from Godot4. They are not yet handled via Variants. 2022-08-07 23:30:31 +02:00
0095078e25 Fixed an another warning on the pi. 2022-08-02 00:22:41 +02:00
Ricardo Buring
899a41e0d7 Fixup BVH debugging statements 2022-07-29 23:20:04 +02:00
fabriceci
dfd8e09953 Fix the calculation of the angular velocity when the rotation speed is not high.
(cherry picked from commit db7c91e0ada0c91ba48269cf3cc217631ca33bba)
2022-07-29 22:00:03 +02:00
Marcel Admiraal
24d15ae3f7 Ensure AudioFrame variables l and r are always initialised
(cherry picked from commit d3f099457226ab833127ca66f5876855a9f2da0f)
2022-07-29 11:02:34 +02:00
Theraot
375670222d Added missing p_bidirectional to AStar2D methods
The methods disconnect_points and are_points_connected  now have an optional p_bidirectional parameter matching AStar.

(cherry picked from commit 3590cdfd34eea8dda746d7db1c7e5a79af389026)
2022-07-29 09:13:46 +02:00
Yuri Rubinsky
1a68039fcf Fix wrapf to correct wrap values with 0.1 stepping
(cherry picked from commit 09418afbc0b5a5642448786751b590352ee6cf97)
2022-07-29 09:08:06 +02:00
lawnjelly
c0c72eed7b Force unsigned behaviour for bitfield enums
Some compilers (notably MSVC) were using signed values for bitfield enums. This was causing problems where 2 bits were used to store 4 or less enum values, where they were being treated as negative numbers.

This PR explicitly requests these enums to be treated as unsigned values.
2022-07-28 13:45:51 +02:00
e060783202 Fix mistake. 2022-07-27 19:35:50 +02:00
24eccc4281 Ported: Fix warnings found by Emscripten 3.1.10
Fix `-Wunused-but-set-variable`, `-Wunqualified-std-cast-call`, and
`-Wliteral-range` warnings.
- akien-mga
5e693b6d84
2022-07-27 18:39:35 +02:00
smix8
62518e9a95 Allow AStar/AStar2D zero point weight
Allow AStar/AStar2D zero point weight.

Limit was set to 1 which seemed like an arbitrary value as lower values down to zero can be useful for common gameplay navigation elements like teleports.
2022-07-27 15:01:51 +02:00
fa2ac74a7c Added 2 helper methods to Math. 2022-07-02 21:55:46 +02:00
32f148ac0c Mass replaced godot to pandemonium. 2022-03-23 20:46:05 +01:00
527cfb88aa Added Vector2i, Vector3i, Rect2i, PoolVector2i, PoolVector3i, Vector<Vector2i>, Vector<Vector3i> classes as core variant binds. GDScript still need to be updated to be able to use them. 2022-03-21 14:01:31 +01:00
34547120dd Added Vector3i from godot4. 2022-03-21 02:13:08 +01:00
05d5f1b181 Now Rect2i is in it's own header and cpp file. 2022-03-21 02:08:38 +01:00
987f77442a Now Vector2i is in it's own header and cpp file. 2022-03-21 01:50:02 +01:00