Commit Graph

2721 Commits

Author SHA1 Message Date
lawnjelly 4ec07e8beb Optimize Editor `_init_grid()`
Use static `LocalVectors` instead of `PoolVectors` for temporaries.
2024-06-03 14:07:38 +01:00
Rémi Verschelde 49e533a765
Merge pull request #88871 from lawnjelly/fix_tilemap_undo2
[3.x] Tilemap editor - prevent changing tool when mouse buttons pressed
2024-04-25 13:28:27 +02:00
lawnjelly 6d036c5a3a Fix `spatial_editor_plugin` enum
* The `view_mesh_stats` feature introduced a new enum value `VIEW_SLECTED_INFO` within the unnamed `VIEW` enum.
* This turns out to be saved somehow, which means the view settings can get out of sync when reloading the project in an older version of the editor.
* The solution is simply to move the new value to the end of the enum so there are no conflicts.
2024-04-22 07:08:55 +01:00
lawnjelly bdf0f78e07 Editor 3D view mesh stats
Similar to information window, add a small optional window to display face count and other stats.
2024-04-21 08:20:18 +01:00
Haoyu Qiu 4551bd9386 Add option to toggle visibility of position gizmos in 2D editor
Co-authored-by: J. N. Witch <127793256+J-N-Witch@users.noreply.github.com>
2024-04-16 20:10:41 +08:00
Haoyu Qiu ed952f82bd Add is_zero_approx methods to Vector{2,3} 2024-04-10 19:02:42 +08:00
Rémi Verschelde 1ad9e856a0
Merge pull request #88198 from lawnjelly/fix_facecount_bug
[3.x] Fix `Mesh::get_face_count()`
2024-03-08 17:54:04 +01:00
Rémi Verschelde ae7dfd1f13
Merge pull request #85437 from lawnjelly/lod_scene_side
[3.x] Discrete Level of Detail
2024-03-08 17:53:58 +01:00
lawnjelly 50fa1896b8
Merge pull request #88828 from Mickeon/3.x-funny-regressions
[3.x] Fix TileSet editor selected regression
2024-02-27 13:34:04 +00:00
lawnjelly 6a31048dbc Tilemap editor - prevent changing tool when mouse buttons pressed
Changing tool when painting prevented the corresponding commit of undo action when the mouse button was released. This led to undo actions getting out of sync and the undo system breaking the editor.

This PR simply prevents changing tool while mouse buttons are pressed, and prevents the above scenario.
2024-02-26 15:27:31 +00:00
Micky 02a2968764 [3.x] Fix TileSet editor selected regression 2024-02-25 22:46:23 +01:00
Ansraer 1e7c60174e fix crash on mat creation after orm refactor 2024-02-16 20:51:27 +01:00
lawnjelly a32a2613e9 Fix `Mesh::get_face_count()`
This fixes a minor bug whereby facecount was actually returning the facecount * 3.
There were no major problems from this, but it did mean the optional threshold poly count used when merging was out by a factor of 3.
2024-02-11 12:19:52 +00:00
lawnjelly 1b5fa74e39 Discrete Level of Detail
Add scene side discrete level of detail.

New node `LOD` for UI, and `LODManager` within `World` for automatically updating child visibilities based on distance from cameras.
2024-02-10 18:54:25 +00:00
Ansraer b9cbffd957 add ORMSpatialMaterial 2024-02-08 20:34:11 +01:00
lawnjelly 8b79135538 Add MergeGroup node to simplify merging Meshes at runtime 2024-01-31 08:28:51 +00:00
Micky 211c707e67 [3.x] Add Selected Collision Group in TileSet Editor
Also moves the TileSet Script property down to its own category.
2024-01-26 16:26:55 +01:00
Rémi Verschelde 96bc1dc469
Merge pull request #79376 from kleonc/tiles-editor-tooltips
[3.x] Improve `TileMap` editor visible names and tooltips
2023-12-13 13:24:27 +01:00
kleonc 0cde6800e7 Make gizmo plugin handle SpriteBase3D instead of Sprite3D 2023-10-06 10:43:07 +02:00
Haz e3be3fbc59
Fix mesh library remove selected item menu option
Fixes #45969.

(cherry picked from commits 189acbee60
and aa9d2149e7)
2023-08-28 17:27:13 +02:00
Rémi Verschelde 55550da68b
SCons: Disable C++ exception handling
Upon investigating the extremely slow MSVC build times in #80513, I noticed
that while Godot policy is to never use exceptions, we weren't enforcing it
with compiler flags, and thus still included exception handling code and
stack unwinding.

This is wasteful on multiple aspects:

- Binary size: Around 20% binary size reduction with exceptions disabled
  for both MSVC and GCC binaries.
- Compile time:
  * More than 50% build time reduction with MSVC.
  * 10% to 25% build time reduction with GCC + LTO.
- Performance: Possibly, needs to be benchmarked.

Since users may want to re-enable exceptions in their own thirdparty code
or the libraries they compile with Godot, this behavior can be toggled with
the `disable_exceptions` SCons option, which defaults to true.
2023-08-16 10:34:10 +02:00
Haoyu Qiu 98803d4edd SpatialEditorPlugin should only handle Spatial 2023-08-03 09:41:48 +08:00
Haoyu Qiu dd3bda9156 Fix OccluderPolyShape handles disappear after release click 2023-07-27 16:56:00 +08:00
kleonc e1478ccac2 Improve TileMap editor visible names and tooltips 2023-07-12 14:32:25 +02:00
lawnjelly 43e181a00a Single Compilation Unit build.
Adds support for simple SCU build.
This speeds up compilation by compiling multiple cpp files within a single translation unit.
2023-07-02 20:13:16 +01:00
Rémi Verschelde 60a7b83fbf
Merge pull request #78047 from jeronimo-schreyer/expose_code_editor
[3.x] Expose the TextEdit control of the script editor
2023-06-13 14:37:15 +02:00
wareya 73ad6517e4 make autotiles fall back to the most similar bitmask using heuristics 2023-06-09 22:27:19 -04:00
Jeronimo Schreyer a248c318de Expose the TextEdit control of the script editor
Refactor ScriptEditor and ScriptTextEditor with added method to retrieve the script editor's TextEdit control.

Update
doc/classes/ScriptEditor.xml
script_editor_plugin.cpp
script_editor_plugin.h
script_text_editor.cpp
script_text_editor.h
2023-06-09 10:07:38 -03:00
Rémi Verschelde eeca70f843
Merge pull request #70502 from HolonProduction/svg_assets_3.x
[3.x] Add support for svg images in the asset lib.
2023-06-07 14:46:14 +02:00
Fredia Huya-Kouadio f9ae38d87c
Merge pull request #73692 from m4gr3d/update_touchscreen_editor_settings_3x
[3.x] Enable granular control of touchscreen related settings
2023-05-08 09:10:36 -07:00
Fredia Huya-Kouadio b78935ef51 Adds a `scale_gizmo_handles` entry to the `Touchscreen` editor settings
When enabled, this scales the editor icons to improve usability on touchscreen devices.
In addition this commit fixes touch detection for the collision_shape_2d_editor_plugin so it scales with the icons size.
2023-05-07 15:55:03 -07:00
Aaron Franke 141783d90f
[3.x] Expose `determinant` in Transform2D, rename internal method 2023-04-22 13:47:47 -05:00
DashCell 424bda217c
TileSet: Fix resizing collision shape when vertex is outside the tilesheet
Fixes #34970.
2023-02-13 13:20:48 +01:00
Rémi Verschelde 1426cd3b3a
One Copyright Update to rule them all
As many open source projects have started doing it, we're removing the
current year from the copyright notice, so that we don't need to bump
it every year.

It seems like only the first year of publication is technically
relevant for copyright notices, and even that seems to be something
that many companies stopped listing altogether (in a version controlled
codebase, the commits are a much better source of date of publication
than a hardcoded copyright statement).

We also now list Godot Engine contributors first as we're collectively
the current maintainers of the project, and we clarify that the
"exclusive" copyright of the co-founders covers the timespan before
opensourcing (their further contributions are included as part of Godot
Engine contributors).

Also fixed "cf." Frenchism - it's meant as "refer to / see".

Backported from #70885.
2023-01-10 15:26:54 +01:00
Haoyu Qiu bdcfb0877b Fix error when dropping script into script editor 2022-12-26 14:35:33 +08:00
HolonProduction 9c437631a4 Add support for svg images in the asset lib.
Backport of #70317
2022-12-23 23:24:18 +01:00
Rémi Verschelde ac589edb36
Merge pull request #69939 from timothyqiu/open-packed-scene-3.x
[3.x] Add open scene button in Inspector for PackedScene resource
2022-12-22 08:57:30 +01:00
Rémi Verschelde 76bcc90da8
Merge pull request #70228 from Calinou/add-transparent-viewport-project-setting-3.x
Add a project setting to make the root viewport transparent (3.x)
2022-12-22 08:55:21 +01:00
Anilforextra daa4be06b0 Enable material editor preview to be rotated.
(cherry picked from commit d4ee903004)
2022-12-18 10:32:04 +08:00
Hugo Locurcio 65465f309c
Add a project setting to make the root viewport transparent
This allows creating a project with a transparent window without having
to write any script.
2022-12-18 00:38:05 +01:00
Alfred Reinold Baudisch 7779164096 Add math operators to Visual Shader node names
This change makes it easy, in the "Create Shader Node" dialog, to search for VS nodes by just typing the operator. For example, instead of typing "multiply", you can just type "*" and multiply nodes will be listed.

This feature is inspired by Unreal Engine node graph editor's UX.

Backported from https://github.com/godotengine/godot/pull/67905
2022-12-15 17:21:37 +01:00
Rémi Verschelde 6963ba631e
Fix typos with codespell 2022-12-15 12:26:59 +01:00
Fredia Huya-Kouadio 0825859a94 Update the visibility logic for the spatial editor navigation controls 2022-12-13 16:17:22 -08:00
Haoyu Qiu 433be4aa3e Add open scene button in Inspector for PackedScene resource 2022-12-12 16:10:00 +08:00
Rémi Verschelde 9983df9210
Merge pull request #69526 from m4gr3d/polish_navigation_controls_opacity_3x
[3.x] Minor tweaks/polish to the navigation controls to prevent interference
2022-12-05 11:33:43 +01:00
Rémi Verschelde bf7f93d236
Merge pull request #69384 from asalazar516/3.x_delete_nodes_request_param
[3.x] Add missing argument to `AnimationNodeBlendTreeEditor::_delete_nodes_request`
2022-12-05 00:13:31 +01:00
Fredia Huya-Kouadio f1e6ecd3b5 Minor tweaks/polish to the navigation controls to prevent interference:
- Reduce controls size
- Enable opacity on hover to increase visibility
2022-12-02 23:33:14 -08:00
asalazar516 fd101d9def [3.x] Add missing argument to AnimationNodeBlendTreeEditor::_delete_nodes_request 2022-12-02 11:12:38 -08:00
Alfred Reinold Baudisch d3735d8b21
Cast dragged file extension name to lowercase, closes #68104
(cherry picked from commit 07e367cb0b)
2022-11-30 15:34:27 +01:00
kleonc 7f2c318e6e
`SpriteFramesEditor` Fix calculating frame index from mouse position
(cherry picked from commit d135957987)
2022-11-30 15:34:27 +01:00