summaryrefslogtreecommitdiff
path: root/scene/3d/physics_body_3d.cpp
AgeCommit message (Collapse)Author
2022-09-18Turn on recovery as collisions only for floor snapping as this leads to ↵fabriceci
unwanted behaviour for other surface than the floor.
2022-09-17Add recovery_as_collision in move_and_collide/test_movefabriceci
2022-09-02Rename `or_lesser` range property hint to `or_less`Hugo Locurcio
"less" should be used for quantity, rather than "lesser". Existing scripts that use `or_lesser` in `_get_property_list()` will need to be updated to account for this change.
2022-09-02Add `is_zero_approx` methods to `Vector2`, `3`, and `4`Jonathan Nicholl
2022-08-26Merge pull request #64367 from Mickeon/rename-var-to-strRémi Verschelde
Rename `str2var` to `str_to_var` and similar
2022-08-26Rename `str2var` to `str_to_var` and similarMicky
Affects the Math class, a good chunk of the audio code, and a lot of other miscellaneous classes, too. - `var2str` -> `var_to_str` - `str2var` -> `str_to_var` - `bytes2var` -> `bytes_to_var` - `bytes2var_with_objects` -> `bytes_to_var_with_objects` - `var2bytes` -> `var_to_bytes` - `var2bytes_with_objects` -> `var_to_bytes_with_objects` - `linear2db` -> `linear_to_db` - `db2linear` -> `db_to_linear` - `deg2rad` -> `deg_to_rad` - `rad2deg` -> `rad_to_deg` - `dict2inst` -> `dict_to_inst` - `inst2dict` -> `inst_to_dict`
2022-08-26Restore RigidBody2/3D, SoftBody names in physicsfabriceci
2022-08-25Merge pull request #64802 from benbot/masterRémi Verschelde
2022-08-25Shorten variable names for moving platforms in CharacterBodyfabriceci
2022-08-24removes unused skeleton functions and stray comments in RigidDynamicBody3Dbenbot
2022-08-24Improves the API for monitoring contacts in RigidDynamicBodyfabriceci
2022-08-24Merge pull request #64009 from KoBeWi/arrayy_lmaoRémi Verschelde
Replace Array return types with TypedArray (part 2)
2022-08-23Replace Array return types with TypedArray 2kobewi
2022-08-23Rename properties unnecessarily using slash (`/`) in their namesRémi Verschelde
This is a legacy of Godot 2 days before the inspector had support for groups. "Properties" with a slash in their name can't be accessed from script unless using `set()`/`get()` so they were not actual properties as far as script languages are concerned. Part of #17558.
2022-08-22Merge pull request #64339 from YuriSizov/core-multilevel-validate-propertyRémi Verschelde
2022-08-22Make `_validate_property` a multilevel methodYuri Sizov
2022-08-22Merge pull request #64343 from TokageItLab/priority-phRémi Verschelde
2022-08-18Remove unintentional PROPERTY_USAGE_INTERNALRedMser
The flag only matters for property definition, but was also used in _validate_property a lot.
2022-08-18Add collision weight to PhysicsBody for penetrations must be avoidedSilc Renew
Co-authored-by: Juan Linietsky <reduzio@gmail.com>
2022-08-10add get_depth() to KinematicCollision3D as same of 2DSilc Renew
2022-07-29Remove Signal connect bindsJuan Linietsky
Remove the optional argument p_binds from `Object::connect` since it was deprecated by Callable.bind(). Changed all uses of it to Callable.bind()
2022-06-11Add suffixes to all nodes and resourcesFireForge
2022-05-19Use suffixes for units in nodes and resourcesAaron Franke
2022-05-19Add dedicated macros for property name extractionHaoyu Qiu
* Replace case-by-case extraction with PNAME & GNAME * Fix group handling when group hint begins with property name * Exclude properties that are PROPERTY_USAGE_NO_EDITOR * Extract missing ADD_ARRAY*, ADD_SUBGROUP* macros
2022-05-18Add motion parameter to toggle whether recovery is reported as a collisionRicardo Buring
This makes the intent explicit in each use case.
2022-05-16Replace most uses of Map by HashMapreduz
* Map is unnecessary and inefficient in almost every case. * Replaced by the new HashMap. * Renamed Map to RBMap and Set to RBSet for cases that still make sense (order matters) but use is discouraged. There were very few cases where replacing by HashMap was undesired because keeping the key order was intended. I tried to keep those (as RBMap) as much as possible, but might have missed some. Review appreciated!
2022-05-03Rename Basis get_axis to get_column, remove redundant methodsAaron Franke
2022-04-29Merge pull request #59297 from fabriceci/fix-jitter-2D-slight-slopeRémi Verschelde
2022-04-28Merge pull request #59438 from ↵Rémi Verschelde
fabriceci/fix-move-and-collide-reported-collisions Fix wrong collision reported on move_and_collide
2022-03-28Merge pull request #59525 from fire-forge/fix-group-namesRémi Verschelde
2022-03-28Fix inspector group name capitalizationFireForge
2022-03-28String: Remove TTR and DTR defines in non-tools buildRémi Verschelde
This ensures we don't use TTR in runtime code, as it's specifically meant to source translations for the editor.
2022-03-23When only a recovery occurs, don't report a collision on move_and_collidefabriceci
2022-03-21Fix 2D jitter on slight slopefabriceci
2022-03-09Avoid directional correction when the motion is downwardfabriceci
2022-03-03Add linear_velocity and angular_velocity to PhysicalBone3DMrSwedish
2022-02-22Rename motion_velocity to velocityChris Bradfield
2022-02-15Use `switch` consistently in `_notification` (`scene` folder)Rémi Verschelde
2022-01-26Revert #53174 (applying the delta in move and collide), rename rec_vel to ↵fabriceci
distance and improve the doc description
2022-01-24rename free mode to floating modefabriceci
2022-01-03Update copyright statements to 2022Rémi Verschelde
Happy new year to the wonderful Godot community!
2021-12-10Improve RigidDynamicBody force and torque APIPouleyKetchoupp
Makes the API for forces and impulses more flexible, easier to understand and harmonized between 2D and 3D. Rigid bodies now have 3 sets of methods for forces and impulses: -apply_impulse() for impulses (one-shot and time independent) -apply_force() for forces (time dependent) applied for the current step -add_constant_force() for forces that keeps being applied each step Also updated the documentation to clarify the different methods and parameters in rigid body nodes, body direct state and physics servers.
2021-11-23Fix horizontal velocity being always reset when the body hit a wall in 3dfabriceci
2021-11-22Merge pull request #55202 from fabriceci/fix-wall-acceleration-in-3dCamille Mohr-Daurat
Fix wall acceleration in move and slide (3D)
2021-11-22Fix body stuck in some 3d advanced scenariofabriceci
2021-11-21Fix wall acceleration in move and slide (3D)fabriceci
2021-11-10Merge pull request #54847 from nekomatata/fix-test-move-regressionRémi Verschelde
2021-11-10Fix test_move reporting collision when touching another bodyPouleyKetchoupp
Reporting rest collision information is needed for move_and_collide and move_and_slide so floor detection can be done properly, but in the case of just testing the motion for collision, it makes sense to return false if the body is able to move all along the path without being stopped. Updated the logic in test_move and clarified the documentation for test_move and move_and_collide.
2021-11-10Fix errors in CharacterBody when floor is destroyed or removedPouleyKetchoupp
In all physics servers, body_get_direct_state() now silently returns nullptr when the body has been already freed or is removed from space, so the client code can detect this state and invalidate the body rid. In 2D, there is no change in behavior (just no more errors). In 3D, the Bullet server returned a valid direct body state when the body was removed from the physics space, but in this case it didn't make sense to use the information from the body state.
2021-11-03Rename `PROPERTY_USAGE_NOEDITOR` to `PROPERTY_USAGE_NO_EDITOR`Hugo Locurcio
This is consistent with other constants that include `NO`, such as `PROPERTY_HINT_COLOR_NO_ALPHA`.