Commit graph

182 commits

Author SHA1 Message Date
Michael Alexsander Silva Dias 8aad7ef016 General fixes for the TileSet editor 2018-12-24 18:27:43 -02:00
Guilherme Felipe bacf5124cf Add EDITMODE_PRIORITY for ATLAS_TILE
When editing ATLAS_TILE, now it's possible to enable priority to
randomize subtiles.
2018-12-23 18:56:18 -02:00
Rémi Verschelde f09956c86c
Merge pull request #24513 from YeldhamDev/fix_tileset_editor_draw
Fix small drawing error in TileSet editor
2018-12-21 10:09:00 +01:00
Michael Alexsander Silva Dias daf54133c2 Fix small drawing error in TileSet editor 2018-12-20 19:52:56 -02:00
Guilherme Felipe 21bad78bd8 Fixes for TileSetEditor and TileMapEditor
[TileSetEditor] Hide Bitmask and Priority for ATLAS_TILE
[TileMapEditor] Hide "Disable autotile" if the selected tile isn't
autotile
Fix #22756, don't update bitmask when tilemode is ATLAS_TILE
2018-12-20 15:31:45 -02:00
Michael Alexsander Silva Dias e425f2d498 Expose "meta" to the Inspector 2018-12-08 02:27:20 -02:00
Guilherme Felipe 69f6f787c0 Add Z-Index for Autotile 2018-12-07 18:42:56 -02:00
Michael Alexsander Silva Dias d514ac405b Hide "Script" section in the "TilesetEditorContext" 2018-12-07 02:18:02 -02:00
Rémi Verschelde 3f1bec5887
Merge pull request #23977 from YeldhamDev/editor_plugins_improvements
General enhancements to the Polygon2D, TextureRegion, and TileSet editors
2018-12-06 16:26:16 +01:00
David Kennedy 29284f628c Fixes editor crashing when editing autotiles issue #24004 2018-12-06 07:15:48 -03:00
Michael Alexsander Silva Dias e4d0ecce7a General enhancements to the Polygon2D, TextureRegion, and TileSet editors 2018-12-06 03:29:27 -02:00
Liangdi 5116c009c9 fix tile set editor crash when drawing polygon shapes 2018-11-08 02:10:13 +08:00
Pedro J. Estébanez d856ec611a Let TileSet editor sanitize out tiles with wrong textures 2018-11-02 04:54:28 +01:00
Liangdi aaa7f625df support New TileSet Editor zooming use CTRL/CMD + MouseWheel
fixed code style for clang-format

apply clang-format
2018-10-26 23:58:58 +08:00
merumelu 27596f6031 TileSetEditor: Don't crash when adding invalid files 2018-10-11 17:15:01 +02:00
Rémi Verschelde 7b081a7fc8 Fix warnings about unhandled enum value in switch [-Wswitch]
Fixes GCC 5 warnings of the form:

core/io/http_client.cpp:288:9: warning: enumeration value 'STATUS_SSL_HANDSHAKE_ERROR' not handled in switch [-Wswitch]
core/io/marshalls.cpp:806:9: warning: enumeration value 'AABB' not handled in switch [-Wswitch]

Those can be trivial cases where adding a default fallback is the solution,
or more complex issues/hidden bugs where missed values are actually meant
to be handled.
2018-09-27 18:34:30 +02:00
Yuri Chornoivan 06e73522dc Fix vformat(), minor typos and word puzzles 2018-08-29 11:50:39 +03:00
Rémi Verschelde 9df5ddae29
Merge pull request #21456 from MarianoGnu/tileset_editor
TileSet editor Fixes
2018-08-27 17:49:02 +02:00
Omicron 71397e0e17
Typo in text string
reported by Yuri Chornoivan on weblate
2018-08-27 16:12:48 +02:00
Mariano Javier Suligoy c64ab97063 TileSet editor Fixes
Properly draw navigation and oclusion polygons for SINGLE type tiles. Fixes #21398
Add some checks for TileID validation before accessing to it's properties. Fixes #21397
Fix 'Keep inside region' snap option for tiles with SINGLE_TILE mode. Fixes #21402
Restore hability to asign/unasign an script to a tileset. Fixes #20886
2018-08-26 17:10:01 -03:00
Michael Alexsander Silva Dias 6fa1b5eca7 Add option to move Tile/GridMap editors to another side 2018-08-22 19:18:23 -03:00
Mariano Javier Suligoy 810b73c01e Display tile ID along with name
Fixes #20895.
2018-08-22 14:35:50 +02:00
Michael Alexsander Silva Dias 609d97b6d4 Changes to the TileSet and TextureRegion editors 2018-08-14 14:02:47 -03:00
MAriano Javier Suligoy ce87a30e45 New TileSet Editor 2018-08-09 20:38:02 -03:00
Bojidar Marinov d73cdeb248
Fix bugs related to bad handling of rotated/translated shapes in tilemap
Fixup #18529 and #12870
2018-06-03 16:32:23 +03:00
Mariano Javier Suligoy 7eddb80b27
Merge pull request #18960 from isaacremnant/autotile_3x3_minimal
Restore support for minimal 3x3 autotile sets
2018-05-17 19:57:55 -03:00
isaacremnant e4f0ac558d Restore support for minimal 3x3 autotile sets 2018-05-17 09:49:14 -04:00
Rémi Verschelde 5e20a229eb
Merge pull request #18529 from swarnimarun/master
Fix StaticBody2D ignore in tileset bug
2018-05-17 09:35:51 +02:00
Swarnim Arun 8529763a0f Fix tileset bug #18090 to use StaticBody2D position
Using staticbody2d position to affect the collision shape position whenever a tileset is created.

Formatting the code

Removed the most get/set from my old code.
2018-05-09 12:12:10 +05:30
Rémi Verschelde de97339a2d
Merge pull request #18291 from akien-mga/coverity-uninitialized-scalar-var
Fix Coverity reports of uninitialized scalar variable
2018-05-01 19:14:07 +02:00
Pieter-Jan Briers 20dd2204db Adds z-index properties to TileSets. 2018-05-01 17:24:57 +02:00
Rémi Verschelde bf7ca623a6 Fix Coverity reports of uninitialized scalar variable
Fixes most current reports on Coverity Scan of uninitialized scalar
variable (CWE-457): https://cwe.mitre.org/data/definitions/457.html

These happen most of the time (in our code) when instanciating structs
without a constructor (or with an incomplete one), and later returning
the instance. This is sometimes intended though, as some parameters are
only used in some situations and should not be double-initialized for
performance reasons (e.g. `constant` in ShaderLanguage::Token).
2018-04-19 15:20:45 +02:00
Poommetee Ketson ed3b080ca6 Fix converting to tileset crashes Godot if existing file is not tileset
also make TileSetEditorPlgn tile list updates the preview modulate
2018-03-23 21:27:30 +07:00
Rémi Verschelde 535205196f
Merge pull request #17013 from Noshyaar/theme
Update icons when theme changed
2018-03-13 13:48:37 +01:00
Rémi Verschelde 8b629bbcbe
Merge pull request #17166 from Noshyaar/tilemap2
TileSet&TextureRegion: fix error when getting nonexistent tile
2018-03-13 12:53:51 +01:00
Poommetee Ketson 54ecfc96ea TileSetEditorPlgn: use EditorHandle icon as handle 2018-03-02 23:15:32 +07:00
Poommetee Ketson 86938a06aa TileSet&TextureRegion: fix error when getting nonexistent tile 2018-03-02 17:14:55 +07:00
Poommetee Ketson 762f241e10 TileSetEditorPlgn: Fix a leak 2018-02-27 09:58:27 +07:00
Poommetee Ketson 2de1dfa42f Update icons when theme changed 2018-02-25 23:04:16 +07:00
Damar Indra e69dd47501 Tileset Editor Improvement 2018-02-20 22:33:59 +07:00
damarindra cceb176be3 fix crash autotile edit mode 2018-02-16 17:48:01 +07:00
Poommetee Ketson 70be6848c2 Fix ObjectDB Instances still exist
```
WARNING: cleanup: ObjectDB Instances still exist!
   At: core/object.cpp:1989.
Leaked Instance: VSeparator:13837 - Node Name:
Leaked Instance: AutotileEditorHelper:13814
Orphan StringName: VSeparator
Orphan StringName: AutotileEditorHelper
StringName: 2 unclaimed string names at exit.
```
2018-01-22 11:46:05 +07:00
Mariano Suligoy 489eac3f13 TileSetEditorPlugin: take scale in accout when highlighting current selected subtile. 2018-01-17 21:07:43 -03:00
Gilles Roudiere b06c6602c8 Changes the keep_margin parameter to true by default, so that people are not suprised that set_anchor changes the margins values 2018-01-15 10:37:13 +01:00
damarindra bea40343ab fix updating tileset list when assign texture and set autotile true 2018-01-11 05:50:36 +07:00
Rémi Verschelde abcb87bc43
Merge pull request #15357 from damarindra/autotile-behaviour
Fixing unconsistent behaviour on autotile editor
2018-01-07 16:00:00 +01:00
Poommetee Ketson 768fd83e61 Fix typo in new strings 2018-01-06 21:33:11 +07:00
damarindra 97b8be7261 Fixing weird behaviour on autotile editor 2018-01-05 17:53:30 +07:00
damarindra 0ae4ca7066 prevent autotile properties out of bounds 2018-01-05 15:28:36 +07:00
Rémi Verschelde e4213e66b2 Add missing copyright headers and fix formatting
Using `misc/scripts/fix_headers.py` on all Godot files.
Some missing header guards were added, and the header inclusion order
was fixed in the Bullet module.
2018-01-05 01:22:23 +01:00
volzhs 1876999b3a Fix get_edited_scene_root error at starting editor
Fix #15300
2018-01-05 03:55:43 +09:00
Michael Alexsander Silva Dias ca90c737b7 Fixed "Tile Set" button always showing bug introduced with #15309. 2018-01-04 09:26:24 -02:00
Michael Alexsander Silva Dias fb68ceebae Fixed the "Tile Set" button being able to go out of bounds. 2018-01-03 21:56:57 -02:00
Rémi Verschelde 361ade53aa
Merge pull request #15185 from damarindra/master
Improve : ease of use TileSet Editor
2018-01-03 12:06:21 +01:00
damarindra 9b04973568 Improve : ease of use TileSet Editor 2018-01-02 16:15:33 +07:00
Rémi Verschelde b50a9114b1 Update copyright statements to 2018
Happy new year to the wonderful Godot community!
2018-01-01 14:40:47 +01:00
damarindra e850360948 Autotile Enhancement 2017-12-28 23:57:23 +07:00
geequlim 52ad2e5418 Add more translatable text for editor plugins. 2017-12-23 22:40:15 +08:00
George Marques c8d416d152
Fix method not returning value in all paths (autotile editor) 2017-12-17 16:03:46 -02:00
Michael Alexsander Silva Dias a933b927ca Fixed Tileset editor button having the wrong text and not being translatable. 2017-12-12 17:06:44 -02:00
volzhs 81a79e0c0e Fix get_edited_scene_root error at starting editor 2017-12-10 08:01:00 +09:00
Mariano Suligoy af719a90a7 TileMap Fixes 2017-12-02 20:49:01 -03:00
Mariano Suligoy bcfb0a09f8 Implement auto-tiling 2017-11-20 06:27:47 -03:00
Gilles Roudiere 05bb8e0c10 Remove set_area_as_parent_rect and replace it by set_anchors_and_margins_preset(PRESET_WIDE) 2017-09-22 11:39:44 +02:00
Rémi Verschelde bd282ff43f Use HTTPS URL for Godot's website in the headers 2017-08-27 14:16:55 +02:00
Hein-Pieter van Braam cacced7e50 Convert Object::cast_to() to the static version
Currently we rely on some undefined behavior when Object->cast_to() gets
called with a Null pointer. This used to work fine with GCC < 6 but
newer versions of GCC remove all codepaths in which the this pointer is
Null. However, the non-static cast_to() was supposed to be null safe.

This patch makes cast_to() Null safe and removes the now redundant Null
checks where they existed.

It is explained in this article: https://www.viva64.com/en/b/0226/
2017-08-24 23:08:24 +02:00
Gilles Roudiere 06256cd778 Some control fixes and removed useless lines 2017-08-19 19:10:00 +02:00
Wilson E. Alvarez 428f03cf06 Updated function argument names 2017-08-12 15:12:49 -04:00
Bojidar Marinov 4d2642b666 Readd tilemap's shape_transform and bugfixes
This reverts commit a808f53020.
2017-07-01 20:56:51 +03:00
Juan Linietsky a808f53020 Revert "Fix Tileset/tilemap issues related to my adding of one-way collisions to them" 2017-07-01 13:02:04 -03:00
Bojidar Marinov 80356f925c
Fix #9409, fixup #9370; tileset now has shape transform instead of offset
Fix bad return type in CollisionObject2D, Shape -> Shape2D. Was causing unintended null when casting. (9409)
Fix a misplaced ++ operator. (9370)
Fix merging with exiting tileset duplicating shapes. (9370)
2017-06-30 19:01:20 +03:00
Rémi Verschelde f2bc0cc966 Merge pull request #9370 from bojidar-bg/c-9318-oneway-tilemaps
Add one-way collisions and individual shape offsets for tilesets
2017-06-26 22:47:26 +02:00
Rémi Verschelde f7b77e5b76 Merge pull request #9318 from bojidar-bg/readd-normal-tilemap
Add normal map to tilemaps and tilesets
2017-06-26 22:47:11 +02:00
Bojidar Marinov 207feb2f87
Add one-way collisions and individual shape offsets for tilesets
As requested in #9318
Accidentially fixes #2231 as well
2017-06-25 21:47:30 +03:00
Juan Linietsky 6ba1e4677b -Trigger shapes removed in 2D, they became obsolete long ago when areas could detect their own overlap
-Added ability to disable individual collisionshape/polygon
-Moved One Way Collision to shape, allowing more flexibility
-Changed internals of CollisionObject, shapes are generated from child nodes on the fly, not stored inside any longer.
-Modifying a CollisionPolygon2D on the fly now works, it can even be animated.

Will port this to 3D once well tested. Have fun!
2017-06-23 23:39:52 -03:00
Bojidar Marinov 2edb082c7e
Add normal map to tilemaps and tilesets
Fixes #9310
2017-06-22 18:15:50 +03:00
Jon Ross c97c733779 Fix #8819. Adds _import_node() that, when used in conjunction with _import_scene, recurses through the scene tree and exports all available nodes. 2017-05-19 14:49:37 -07:00
Sergey Pusnei 8589ca3903 Rename [gs]et_pos to [gs]et_position for Controls
Control set_pos -> set_position
Control set_global_pos -> set_global_position
[gs]et_mouse_pos -> [gs]et_mouse_position
[gs]et_global_mouse_pos -> [gs]et_global_mouse_position
fixes #8005
2017-04-10 08:27:34 +02:00
Rémi Verschelde df61dc4b2b Add "Godot Engine contributors" copyright line 2017-04-08 00:11:42 +02:00
Juan Linietsky 74808ac4d9 New particle system, mostly working, some small features missing. 2017-04-06 23:49:27 -03:00
Rémi Verschelde 5dbf1809c6 A Whole New World (clang-format edition)
I can show you the code
Pretty, with proper whitespace
Tell me, coder, now when did
You last write readable code?

I can open your eyes
Make you see your bad indent
Force you to respect the style
The core devs agreed upon

A whole new world
A new fantastic code format
A de facto standard
With some sugar
Enforced with clang-format

A whole new world
A dazzling style we all dreamed of
And when we read it through
It's crystal clear
That now we're in a whole new world of code
2017-03-05 16:44:50 +01:00
Rémi Verschelde 49c065d29c Refactoring: rename tools/editor/ to editor/
The other subfolders of tools/ had already been moved to either
editor/, misc/ or thirdparty/, so the hiding the editor code that
deep was no longer meaningful.
2017-03-05 14:21:25 +01:00
Renamed from tools/editor/plugins/tile_set_editor_plugin.cpp (Browse further)