Rémi Verschelde
7e731bbce2
Merge pull request #31878 from aole/Initialize-TileMap-Custom-Transform
...
Initialize TileMap Custom Transform
2019-09-02 10:35:56 +02:00
Bhupendra Aole
0b5a600564
Initialize TileMap Custom Transform
...
Initialize TileMap Custom Transform to same as Cell Size (64).
Fixes #30948 .
2019-09-01 19:33:45 -04:00
Hugo Locurcio
8c8dc6f026
Call some CanvasItem property setters only if needed
...
The CanvasItem property setters `set_modulate`, `set_self_modulate`
and `set_light_mask` have some side effects that don't need to be run
if the value hasn't changed.
This closes #31777 .
2019-08-31 21:53:02 +02:00
Michael Alexsander Silva Dias
c902066bb5
Remove some unneeded checks in CollisionObject(2D)
2019-08-30 14:22:46 -03:00
Milan Davidovic
c12ce2b4dd
Prevent move_and_slide() to generate an error.
...
When moving KinematicBody2D from one scene to another and not freeing
the old scene, the first call to move_and_slide() in the new scene will
generate an error because KinematicBody2D keeps internaly a
RID on_floor_body of a body resource in the old scene which no more has
a space assigned.
To fix this, on_floor_body is set to empty RID in response to
NOTIFICATION_ENTER_TREE notification of KinematicBody2D and
KinematicBody. Also all other data related to move_and_slide() is reset:
floor, ceiling, wall flags, colliders vector, floor_velocity.
This fixes #31416 .
2019-08-26 15:10:15 +02:00
Rémi Verschelde
bfed4b6a97
Merge pull request #31014 from DavidSichma/kinematic_angle
...
Fix floor_max_angle comparison for impossible angles
2019-08-23 09:10:38 +02:00
RaphaelHunter
74713fe970
Fix custom inertia in physics2d, closes#30838
2019-08-22 20:30:03 +08:00
Rémi Verschelde
a8db4c848d
Merge pull request #31395 from ptrojahn/floatsarenasty
...
Replace is_zero_approx(A.distance_to(B)) with A==B
2019-08-20 12:54:40 +02:00
Paul Trojahn
7c9c6df7e4
Replace is_zero_approx(A.distance_to(B)) with A==B
...
Related to #22988 (Fixes the holes in the shape of
the first comment)
2019-08-19 18:16:58 +02:00
Hugo Locurcio
558e93f069
Improve the appearance of 2D path editors
...
- Add new handle icons for path/polygon editors
- Add smooth path point icons and curve tangent icons
- Use a gray color for tangent lines in the Path2D and Path editors
- Use antialiasing for Path2D lines
2019-08-18 22:27:01 +02:00
Rémi Verschelde
5f44ee30ec
Merge pull request #31360 from nekomatata/fix-error-parallax-mirroring
...
Fixed error in ParallaxLayer when set_mirroring is called before entering the tree
2019-08-14 13:48:22 +02:00
PouleyKetchoupp
927a7916f6
Fixed error in ParallaxLayer when set_mirroring is called before entering the tree
...
Fixes #31300
2019-08-14 13:21:22 +02:00
IAmActuallyCthulhu
82b9557803
Remove redundant author doc comments
2019-08-12 04:26:38 -05:00
Tomasz Chabora
af5e0fff66
Remove ERR_EXPLAIN from scene/* code
2019-08-09 13:54:52 +02:00
Rémi Verschelde
5becb2e322
Merge pull request #31194 from bojidar-bg/29312-corrupt-initial-tilemap
...
Fix corrupted TileMap saves due to missing/wrong format
2019-08-08 11:20:06 +02:00
Bojidar Marinov
141ee27dad
Fix corrupted TileMap saves due to missing/wrong format
...
Fixes #29312
2019-08-08 09:30:55 +03:00
Rémi Verschelde
ba541bceca
Merge pull request #31077 from qarmin/coverity_bugs
...
Change some code proposed by Coverity and Cppcheck
2019-08-07 13:49:33 +02:00
qarmin
e0b5b21863
Add some code changes/fixes proposed by Coverity and Clang Tidy
2019-08-07 12:54:30 +02:00
Tomasz Chabora
459f5cb75e
Tweaks related to Camera2D drag margins
2019-08-06 16:19:02 +02:00
Rémi Verschelde
77e8947687
Merge pull request #30905 from clayjohn/set-cpuparticles2d-visible
...
Toggle CPUParticles2D visibility when redrawing
2019-08-01 18:13:28 +02:00
David Sichma
2fae8832c5
Fix floor_max_angle comparison for impossible angles
2019-08-01 12:54:19 +02:00
Hugo Locurcio
0243dc53b8
Tweak Area and PhysicsBody damping setting hints for consistency
...
This partially addresses #19182 .
2019-07-31 13:57:13 +02:00
clayjohn
cb4d145c22
toggle CPUParticles2D visibility when redrawing
2019-07-28 18:31:52 -07:00
groud
11cb4eb363
Add frame_cords accessors to Sprite and Sprite3D
2019-07-27 13:05:02 +02:00
Rémi Verschelde
336846e547
Inspector: Fix PROPERTY_HINT_SPRITE_FRAME not behaving as RANGE
...
This was a regression in 3.1 and later from the new inspector, where
PROPERTY_HINT_SPRITE_FRAME was not fully re-implemented. It's meant to
be a normal PROPERTY_HINT_RANGE which also automatically increments its
value when keyed in the animation player.
To avoid code duplication, I made the frames properties use the actual
PROPERTY_HINT_RANGE and introduced a PROPERTY_USAGE_KEYING_INCREMENTS
usage flag instead.
2019-07-25 09:29:51 +02:00
Rémi Verschelde
d15cf7b672
Merge pull request #30576 from qarmin/lgtm_coverage
...
Changed some code reported by LGTM and Coverity
2019-07-20 12:00:13 +02:00
qarmin
6cbaf7662f
Changed some code showed in LGTM and Coverage
2019-07-20 08:09:57 +02:00
Rémi Verschelde
7d413f075c
Merge pull request #30590 from clayjohn/particle_life
...
Added individual particle random lifetime
2019-07-15 20:40:57 +02:00
clayjohn
5ef3374258
added individual particle random lifetime
2019-07-14 23:22:40 -07:00
Hugo Locurcio
350227013d
Improve 2D RayCast and one-way collision drawing
...
- Make RayCast2D gray when it's disabled
- Make the one-way collision arrow use the inverted shape debugging
color (will result in an orange color by default)
- This makes it easier to distinguish it from RayCast2D arrows
- Make lines slightly thinner
- Make the RayCast2D arrow tip larger
- Use anti-aliasing for the RayCast2D and one-way collision lines
2019-07-12 23:50:38 +02:00
Rémi Verschelde
9496e29326
Merge pull request #30451 from raphael10241024/fix_outline
...
Fix DynamicFont outline does not draw using draw_char
2019-07-10 13:38:20 +02:00
Rémi Verschelde
b489e75716
Merge pull request #30304 from DavidSichma/remote_cache
...
Exposed update_cache() of RemoteTransform and RemoteTransform2D
2019-07-09 22:08:59 +02:00
Hugo Locurcio
2491c87f86
Add `width` and `antialiased` parameters to CanvasItem `draw_rect()`
...
This also removes some duplicated editor code which is now obsoleted
by the new parameters in `draw_rect()`.
2019-07-09 20:30:18 +02:00
David Sichma
5a631bf4f4
Added force_update_cache() to RemoteTransform and RemoteTransform2D
2019-07-09 14:50:03 +02:00
RaphaelHunter
e57d0c8e60
Fix DynamaicFont outline does not draw using draw_char
2019-07-09 12:42:59 +08:00
Hugo Locurcio
ff7184c5cb
Improve the node configuration warning display
...
- Refer to properties explicitly when possible
- When multiple warnings are returned, always separate them by one
blank line to make them easier to distinguish
- Improve grammar and formatting
2019-07-09 00:18:00 +02:00
Rémi Verschelde
410cb13abd
Merge pull request #30361 from LikeLakers2/camera2d-offset-ignores-limit
...
Camera2D's offset now ignores the limit property
2019-07-08 13:40:35 +02:00
Bojidar Marinov
ebf2a4d553
Fix some issue with TileMap's and other nodes' boundaries
...
Fixes #30348
Addresses a small part of #30012
2019-07-08 12:35:52 +03:00
Rémi Verschelde
1fa26b969c
Merge pull request #30357 from simonpuchert/spheres
...
Particles / CPUParticles: Return uniform density spheres.
2019-07-07 11:04:46 +02:00
Ibrahn Sahir
4e4697b1c4
Added release function to PoolVector::Access.
...
For clarity, assign-to-release idiom for PoolVector::Read/Write
replaced with a function call.
Existing uses replaced (or removed if already handled by scope)
2019-07-06 12:04:27 +01:00
LikeLakers2
3f5db82a89
Camera2D's offset now ignores the limit property
2019-07-05 21:22:09 -04:00
Simon Puchert
18ba1bc824
cpu_particles: Return uniform density spheres.
...
The current implementation normalizes points from a uniform distribution
on a cube. This creates a non-uniform distribution on the sphere.
2019-07-06 00:13:03 +02:00
Rémi Verschelde
4dec1bde77
Merge pull request #30231 from Ranoller/master
...
Tilemap fix displaced textures and shapes and added center texture and compatibility mode
2019-07-02 21:43:16 +02:00
Ranoller
14e2a99129
Tilemap fix displaced textures and shapes and added center texture and compatibility mode
...
This commit fix #22989 #15249 #28206 . Main problem is that tilemap displace textures in different tile origins in a strange way and doesn´t respect coincidence between texture and shapes in not uniform tiles. This issue is present in godot 3.0 and godot 3.1. To maintain compatibility are added a compatibility mode and a center texture option. Other related issues and pull request: #28896 #29487 #29519 #29961 . Idications of #30204 are added
2019-07-02 17:12:58 +02:00
Bojidar Marinov
f7dad789e9
Fix various memory leaks and errors
2019-07-02 17:23:54 +03:00
Rémi Verschelde
c08877777d
Merge pull request #26613 from KoBeWi/direction_of_particles
...
Add a Direction property to ParticlesMaterial
2019-07-02 11:33:34 +02:00
Rémi Verschelde
6b30f284a0
Merge pull request #29980 from Dentrax/directed-by-qarmin
...
Fix some editor crashes
2019-07-01 14:59:29 +02:00
Rémi Verschelde
b0ce9401ff
Merge pull request #30126 from qarmin/remove_unnecessary_code
...
Remove unnecessary code and add some error explanations
2019-07-01 14:32:04 +02:00
Furkan Türkal
7d8d337b2c
fix some crashes
2019-07-01 14:28:29 +03:00
qarmin
3c154eb93b
Remove unnecessary code and add some error explanations
2019-07-01 12:59:42 +02:00
Rémi Verschelde
e4a50999c0
Merge pull request #28565 from CedNaru/CurvedWidthLine2D
...
Added a Width Curve to Line2D + UVs fix
2019-07-01 09:38:54 +02:00
Rémi Verschelde
850a54a2a5
Fix uninitialized variables in Line2D, JSONParseResult and TileMap
2019-06-30 13:58:07 +02:00
Rémi Verschelde
26f99beac3
CPUParticles2D: Fix gravity to be the same as in Particles2D and Area2D
...
This was likely a typo, 10 times the standard gravity is 98.0665
(ca. 98), not 98.8.
2019-06-30 13:58:07 +02:00
Rémi Verschelde
cd423f4712
Merge pull request #25649 from bojidar-bg/4454-promote-tilemap-shapes
...
Allow CollisionObject2D to get shapes from tilemaps
2019-06-29 15:35:13 +02:00
Rémi Verschelde
52355c638b
Merge pull request #29380 from bojidar-bg/16086-docs-default-value
...
Add default values to the editor help, docs, and generated RST
2019-06-29 12:28:30 +02:00
Bojidar Marinov
583f7adb51
Allow ColisionObject2D to get shapes from tilemaps
...
Fixes #4454 and likely resolves #22285
2019-06-27 21:16:54 +03:00
Rémi Verschelde
0636f709af
Merge pull request #29937 from clayjohn/particles-one-shot-bug
...
Update emitting status on one-shot particles
2019-06-27 17:29:40 +02:00
Bojidar Marinov
0c4c36d823
Add default values to the editor help, docs, and generated RST
...
Also, make spacing of "=" in the editor help a bit more consistent.
Closes #16086
2019-06-27 18:29:35 +03:00
Rémi Verschelde
eaaff9da31
Merge pull request #29941 from qarmin/redundant_code_and_others
...
Remove redundant code, possible NULL pointers and others
2019-06-27 01:05:18 +02:00
Tomasz Chabora
00b15c19b7
Add a Direction property to ParticlesMaterial
2019-06-26 20:37:39 +02:00
qarmin
4e5310cc60
Some code changed with Clang-Tidy
2019-06-26 15:08:25 +02:00
clayjohn
d59dbda24f
update emitting status on one-shot particles
2019-06-25 22:07:29 -07:00
Rémi Verschelde
f34c8015cb
Area2D: Fix argument type of body_* signals
...
Those signals receive either a PhysicsBody2D or a TileMap object,
and what the emitting method checks internally is only that the
object is a Node. In theory any Node could go through these signals
if they talk directly to the PhysicsServer2D.
Also updated docs.
Fixes #27076 .
Might need further (compat breaking) improvement as this API is a
bit confusing, cf. #24739 .
2019-06-24 21:40:31 +02:00
Rémi Verschelde
25022a1d89
Merge pull request #29974 from clayjohn/particles_restart
...
Properly set emitting when particles restart
2019-06-24 13:48:56 +02:00
clayjohn
64ecc8a5a3
properly set emitting when particles restart
2019-06-21 22:33:11 -07:00
Rémi Verschelde
b3fe249e94
CPUParticles: Set linear velocity to 0, like GPU Particles
2019-06-21 15:23:48 +02:00
Rémi Verschelde
fae3df1204
Particles: Properly initialize angular velocity parameter
...
Right now it would take garbage values when loading scenes,
which could end up written to the scene file.
2019-06-21 15:23:10 +02:00
Rémi Verschelde
5c66771e3e
Merge pull request #29283 from qarmin/fix_some_always_same_values
...
Remove always true/false values
2019-06-20 21:10:10 +02:00
qarmin
072e40368e
Fix always true/false values
2019-06-20 16:59:48 +02:00
Tristan Grespinet
14f8ed3317
Added a Width Curve to Line2D + UVs fix
2019-06-19 15:44:07 +02:00
JohnJLight
38d3bfe971
Made use of semicolons more consitent, fixed formatting
2019-06-19 15:24:31 +02:00
clayjohn
7d1ee6d3c3
change emit shape circle to sphere in CPUParticles2D
2019-06-17 11:59:31 -07:00
Hugo Locurcio
c0b3e20ca7
Tweak some editor property hints to be more flexible and consistent
...
This partially addresses #19242 .
2019-06-16 23:52:16 +02:00
Rémi Verschelde
9d3342545d
Merge pull request #29700 from clayjohn/cpuparticles_transform_bug
...
Fix CPU particles bug with local_coords and transform
2019-06-16 10:49:30 +02:00
Rémi Verschelde
68735d2a88
Fix compilation warnings in JS and Windows builds
...
Warnings raised by Emscripten 1.38.0 and MinGW64 5.0.4 / GCC 8.3.0.
JS can now build with `werror=yes warnings=extra`.
MinGW64 still has a few warnings to resolve with `warnings=extra`,
and only one with `warnings=all`.
Part of #29033 and #29801 .
2019-06-15 14:40:45 +02:00
clayjohn
52696e98b4
fix CPU particles bug with local_coords and transform
2019-06-14 13:22:19 -07:00
Rémi Verschelde
52dd0f8751
Implement missing orbit velocity for CPUParticles and CPUParticles2D
...
The relevant code was copied from (GPU) ParticlesMaterial but commented
out initially, and never ported.
Closes #29580 .
2019-06-13 11:35:07 +02:00
Rémi Verschelde
84d969a42a
Cleanup some unecessary editor/ includes in scene/
...
Part of #29730 , handles false positives.
2019-06-12 22:48:43 +02:00
Rémi Verschelde
971b5160c6
Merge pull request #29306 from qarmin/small_code_fixes
...
Small fixes to unrechable code, possibly overflows, using NULL pointers
2019-06-12 12:49:21 +02:00
Rémi Verschelde
f160c81f68
Merge pull request #29696 from akien-mga/cpuparticles-randomness
...
CPUParticles: Do randomness ratio computations in phase instead of time
2019-06-12 10:54:02 +02:00
Rémi Verschelde
fd66a45f32
Merge pull request #29685 from akien-mga/cpuparticles-tangential-accel
...
CPUParticles: Fix inconsistent tangential acceleration
2019-06-12 10:53:31 +02:00
Rémi Verschelde
d0c2005da1
CPUParticles: Do randomness ratio computations in phase instead of time
...
The original shader code uses a phase (ratio from 0 to 1 for the particle
lifetime) for the randomness ratio computations, and this code was ported
over but converted to time computations.
The seeding/cycle logic was thus invalid, so we're going back to phase
for these computations, thus fixing the previous non-working time/emission
randomness property.
Part of #29692 . Follow-up to #26859 .
2019-06-11 23:40:56 +02:00
Rémi Verschelde
9206bcabaa
CPUParticles: Fix inconsistent tangential acceleration
...
The tangential acceleration for both CPUParticles2D and CPUParticles had been
badly converted from their GPU counterpart (ParticlesMaterial).
This fixes it and ensures that both GPU and CPU particles behave the same with
regard to tangential acceleration.
2019-06-11 18:56:07 +02:00
Rémi Verschelde
6d16f2f053
Fix error macro calls not ending with semicolon
...
It's not necessary, but the vast majority of calls of error macros
do have an ending semicolon, so it's best to be consistent.
Most WARN_DEPRECATED calls did *not* have a semicolon, but there's
no reason for them to be treated differently.
2019-06-11 14:49:34 +02:00
Rémi Verschelde
7b883d7d50
Merge pull request #29558 from SamSindt/fix-lifetime-reversed-CPUParticles2D
...
Reversed operator in SortLifetime fixing #29440
2019-06-11 12:14:26 +02:00
Rémi Verschelde
227b5d20ee
Merge pull request #29519 from Ranoller/master
...
Make tilemap texture origin point top-left.
2019-06-11 12:05:13 +02:00
qarmin
37c2595526
Fix crash when frames are empty
2019-06-10 08:36:28 +02:00
SamSindt
6a23eff748
Reversed operator in SortLifetime fixing #29440
2019-06-06 12:49:48 -07:00
qarmin
2621131549
Fix 2D Line crash
2019-06-06 21:09:37 +02:00
Ranoller
f26e9daab5
Make tilemap texture origin point top-left.
...
Fix https://github.com/godotengine/godot/issues/29487 . In this commit: https://github.com/godotengine/godot/pull/28896 bad offset of textures and shapes was fixed, but a center of texture was added too, and this seems not dessired by default because breaks too much compatibility with demos and user projects. A future Check box for center texture can be added
2019-06-05 23:23:36 +02:00
qarmin
8245db869f
Small fixes to unrechable code, possibly overflows, using NULL pointers
2019-06-03 21:52:50 +02:00
clayjohn
2b8b1d7c46
added MultiMeshInstance2D node for using MultiMesh in 2D
2019-06-03 12:11:54 -07:00
Michael Alexsander Silva Dias
962652f14b
Properly add "texture_changed" signal to MeshInstance2D
...
Fixes #29410 .
2019-06-02 23:51:44 -03:00
Rémi Verschelde
449395716f
Merge pull request #28390 from KoBeWi/smaller_bigger_gizmo
...
Allow to change Position2D gizmo size
2019-06-02 00:06:28 +02:00
Tomasz Chabora
662c8f95ec
Allow to change Position2D gizmo size
2019-06-01 12:33:24 +02:00
Rémi Verschelde
4b399034aa
Merge pull request #24560 from guilhermefelipecgs/fix_24549
...
Add EDITMODE_PRIORITY for ATLAS_TILE
2019-06-01 09:49:18 +02:00
Rémi Verschelde
586539d867
Fix wrong property binding for NavigationPolygon::vertices
2019-05-29 17:28:22 +02:00
Rémi Verschelde
84331549db
Merge pull request #28896 from Ranoller/master
...
Fix tilemap displaced textures and shapes
2019-05-28 22:25:18 +02:00
Tomasz Chabora
f3c5db662d
Don't allow PathFollow offset outside bounds
2019-05-25 18:27:22 +02:00
Tomasz Chabora
5e9400b2e3
Don't modulate canvas on invisible color change
2019-05-24 13:10:21 +02:00