Rémi Verschelde
1a16dabfb5
Merge pull request #21982 from luzpaz/misc-typos
...
Misc. typos
2018-09-13 10:59:00 +02:00
luz.paz
08bde5b2de
Misc. typos
...
Found via `codespell -q 3 -I ../godot-word-whitelist.txt --skip="./thirdparty,*.po"`
2018-09-12 21:39:17 -04:00
Rémi Verschelde
f6481d1694
Revert "Drop deprecated compatibility methods from AnimatedSprite"
2018-09-13 02:32:51 +02:00
Rémi Verschelde
158704fcaa
Merge pull request #21780 from akien-mga/animatedsprite-deprecated
...
Drop deprecated compatibility methods from AnimatedSprite
2018-09-12 10:38:37 +02:00
Rémi Verschelde
277b24dfb7
Make core/ includes absolute, remove subfolders from include path
...
This allows more consistency in the manner we include core headers,
where previously there would be a mix of absolute, relative and
include path-dependent includes.
2018-09-12 09:52:22 +02:00
Rémi Verschelde
2f6f920884
Drop deprecated compatibility methods from AnimatedSprite
...
They were deprecated in 2.1, but never properly identified as such
and thus never removed.
Fixes #21765 .
2018-09-09 15:25:49 +02:00
Juan Linietsky
74359a1d1e
Add a function to force transform update, fixes #17628
2018-09-06 20:38:16 -03:00
Juan Linietsky
47a4d78dbf
Only allow StreamTexture, ImageTexture in Light2D, closes #15194
2018-09-06 13:18:22 -03:00
Rémi Verschelde
5fe01d4cfc
Move ParticlesMaterial code to its own resource file
...
It's shared by both 2D and 3D particles (+ CPU ones), so it makes sense
to have as a common resource. It also allowed to disable compilation of
Particles (3D) when using 'disable_3d'.
Also cleaned up includes in SpatialEditorGizmos and some other places,
as well as dropped dead code in material_editor_plugin.cpp.
2018-09-04 11:32:56 +02:00
Rémi Verschelde
60570a5e60
PhysicsBody: Don't create PhysicsMaterial override for default friction/bounce
...
And don't save physics_material_override if null.
2018-09-02 15:08:43 +02:00
Kelly Thomas
1dc8e7c05f
Improve ClassDB information for some some signal parameters
2018-09-01 18:05:51 +08:00
Rémi Verschelde
449fcc5a72
RayCast2D: Fix reporting old collider after collision ended
...
It now behaves the same as RayCast (3D).
Fixed documentation accordingly and documented new configuration options.
Supersedes and closes #20567 .
2018-08-30 16:28:48 +02:00
Rémi Verschelde
9eb4d4ab2d
Add missing copyright headers
2018-08-29 22:41:17 +02:00
Juan Linietsky
cf834a22dc
Ported CPU particles to 2D
2018-08-29 16:48:55 -03:00
Rémi Verschelde
060988408b
Physics: Properly obsolete friction and bounce properties
...
Without this change any new PhysicsBody would show deprecation warnings
due to default values for friction and bounce being defined.
It also enforced a physics material override even when using default
values.
2018-08-29 18:44:42 +02:00
Marcelo Fernandez
20bea1e231
Unexpose TileMap set_celld
2018-08-29 09:00:00 -03:00
Rémi Verschelde
3b01bf94ad
Fix operator precedence in PhysicsBody2D::set_weight
...
Fixes #16038 .
2018-08-29 08:37:08 +02:00
Rémi Verschelde
67b0d3c2dc
Particles: Allow speed_scale at 0 in property hint, equivalent to pause
...
Supersedes and closes #21193 .
2018-08-24 18:11:35 +02:00
Rémi Verschelde
f733c6470d
Merge pull request #21110 from natrim/particles2d_editor
...
Particles2D: fix editing Visibility Rect from new inspector
2018-08-24 15:31:31 +02:00
Rémi Verschelde
52466d57e9
Make some debug prints verbose-only, remove others
2018-08-24 14:59:01 +02:00
Juan Linietsky
34e58fd831
Added a function to cache texture opacity at a pixel, and modified editor to use it.
...
Provides massive speedups to selecting objects, still awaiting for @MarianoGNU to do fixes to the region editor to improve performance.
2018-08-23 22:11:10 -03:00
Rémi Verschelde
ab3716bd46
Revert "Take CanvasLayer transform into account for 2D physics"
...
This reverts commit 4839e5f6d9
.
Fixes #21289 .
2018-08-23 21:49:24 +02:00
Juan Linietsky
398c1c1c0c
Fix transform not being applied properly after toggling remote node, fixes #17671
2018-08-23 12:29:33 -03:00
Juan Linietsky
634673cf5b
Fix properly keep scale in RemoteTransform2D, fixes #17692 , closes #17690
2018-08-23 12:14:04 -03:00
Chaosus
27731a86d2
Restrict set_pitch_scale to positive scales for AudioStreamPlayer*
...
Fixes #20459 .
Co-authored-by: Tiago José Sousa Magalhães <crakylps@gmail.com>
2018-08-22 00:11:53 +02:00
Rémi Verschelde
ed10ff65fd
Merge pull request #21245 from RandomShaper/fix-physics-canvas-xform
...
Take CanvasLayer transform into account for 2D physics
2018-08-21 21:46:04 +02:00
Juan Linietsky
ee07fb5ebe
Changes to ClippedCamera, RayCast,Raycast2D and 2D physics API to add ability to choose between bodies and areas when colliding.
2018-08-21 15:31:23 -03:00
Pedro J. Estébanez
20dc63054f
Optimize CanvasLayer::get_global_transform_with_canvas
...
So it takes advantage of the `get_global_transform` cached data.
2018-08-21 20:10:15 +02:00
Pedro J. Estébanez
4839e5f6d9
Take CanvasLayer transform into account for 2D physics
...
Fixes #18073 .
2018-08-21 20:10:15 +02:00
Rémi Verschelde
2969dffbe3
Deprecate incorrect Color::gray()
...
This average is not a proper approximation of a grayscale value,
get_v() is better suited for that.
If we want a real to_grayscale() conversion, it's somewhat more
involved: https://en.wikipedia.org/wiki/Grayscale
Remove the deprecated Gray() from C# bindings as it conflicts
with new named color constants.
2018-08-21 17:48:31 +02:00
Poommetee Ketson
76adef2704
Fix arg name in docs, some copy-paste errors
2018-08-21 01:51:19 +07:00
Andrea Catania
0010d9c82a
Added ray shape and move_and_slide with snapping on 3D.
...
Added stop_on_slope on 2d part
2018-08-19 13:45:23 +02:00
Natrim
6ad0f4ebe8
Particles2D: fix editing Visibility Rect from inspector
...
+ renamed generate_aabb to generate_visibility_rect to prevent future confusions
2018-08-17 12:25:48 +02:00
Rémi Verschelde
968886768b
Lift 1440 limit in rotation_degrees hint range
...
Fixes #15947 .
2018-08-16 14:36:38 +02:00
Juan Linietsky
4e55835e48
Merge pull request #18096 from aaronfranke/master
...
[Core] Split up math_2d.h
2018-08-14 18:58:32 -03:00
Rémi Verschelde
2062d6126d
Merge pull request #20587 from groud/fix_2deditor_scrollable_zone
...
Fixes bugs on the 2D editor scrollable area
2018-08-13 09:03:34 +02:00
Aaron Franke
28fc195339
[Core] Change math_2d includes to vector2 includes where relevant
2018-08-10 14:59:29 -05:00
Juan Linietsky
c02fb271fd
apply a threshold for floor angle, fixes #16037 , fixes #15632
2018-08-10 13:07:52 -03:00
MAriano Javier Suligoy
ce87a30e45
New TileSet Editor
2018-08-09 20:38:02 -03:00
Juan Linietsky
14fd797c53
Merge pull request #20381 from AndreaCatania/phymat_2
...
Improved Physics material
2018-08-07 15:31:26 -03:00
Andrea Catania
5e65e28eed
Removed physics material combination mode. Added rough and absorbent parameter to material. Fixed 'change' signal connection
2018-08-07 19:38:04 +02:00
groud
eb7f4ddcce
Fixes bugs on the 2D editor scrollable area
2018-07-30 01:05:13 +02:00
Rémi Verschelde
12254594ac
Fix PhysicsBody build with deprecated=no
...
Fixes #20483 .
2018-07-27 15:34:58 +02:00
Rémi Verschelde
391e46830f
doc: Sync classref with current source
...
Fix various missing arguments in bindings.
2018-07-26 11:56:21 +02:00
Hein-Pieter van Braam
0e29f7974b
Reduce unnecessary COW on Vector by make writing explicit
...
This commit makes operator[] on Vector const and adds a write proxy to it. From
now on writes to Vectors need to happen through the .write proxy. So for
instance:
Vector<int> vec;
vec.push_back(10);
std::cout << vec[0] << std::endl;
vec.write[0] = 20;
Failing to use the .write proxy will cause a compilation error.
In addition COWable datatypes can now embed a CowData pointer to their data.
This means that String, CharString, and VMap no longer use or derive from
Vector.
_ALWAYS_INLINE_ and _FORCE_INLINE_ are now equivalent for debug and non-debug
builds. This is a lot faster for Vector in the editor and while running tests.
The reason why this difference used to exist is because force-inlined methods
used to give a bad debugging experience. After extensive testing with modern
compilers this is no longer the case.
2018-07-26 00:54:16 +02:00
Rémi Verschelde
f778bd8e69
Merge pull request #20404 from TigerCaldwell/master
...
Ensured consistency between RigidBody, PhysicsDirectBodyState, PhysicsServers and their 2D counterparts
2018-07-25 08:25:34 +02:00
Rémi Verschelde
62f2a8aadb
Merge pull request #20252 from RandomShaper/fix-canvas-search
...
Fix CanvasItem's search for a CanvasLayer
2018-07-24 22:45:24 +02:00
Tiger Caldwell
40c7716586
Modified RigidBody, PhysicsDirectBodyState, PhysicsServer, and their respective 2D counterparts to be more consistent and to include more useful methods.
...
RigidBody:
- Added add_central_force
- Added add_force
- Added add_torque
- Added apply_central_impulse
RigidBody2D:
- Added add_central_force
- Added add_torque
- Added apply_central_impulse
- Added apply_torque_impulse
PhysicsDirectBodyState:
- Added apply_central_impulse
Physics2DDirectBodyState:
- Added add_central_force
- Added add_force
- Added add_torque
- Added apply_central_impulse
- Added apply_impulse
- Added apply_torque_impulse
PhysicsServer:
- Added body_add_force
- Added body_add_torque
- Added body_add_central_force
- Added body_apply_central_impulse
Physics2DServer:
- Added body_add_torque
- Added body_add_central_force
- Added body_apply_central_impulse
- Added body_apply_torque_impulse
Also fixed some small bugs along the way
2018-07-24 05:00:56 -04:00
Wilson E. Alvarez
a22e746bc3
Removed unnecessary assignments
2018-07-24 09:51:03 +02:00
Juan Linietsky
1ad20dc2f1
Merge pull request #12403 from AndreaCatania/phymat
...
Physics material
2018-07-23 07:37:03 -03:00