Skip to content

Commit 580a784

Browse files
committed
Add conversion suggestions from Mickeon
1 parent cb415a5 commit 580a784

File tree

1 file changed

+21
-1
lines changed

1 file changed

+21
-1
lines changed

tutorials/editor/upgrading_to_godot_4.rst

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -317,13 +317,17 @@ Due to how the project upgrade tool works, not all
317317
- Camera2D's ``get_v_offset()`` is now ``get_drag_vertical_offset()``.
318318
- Camera2D's ``set_v_offset()`` is now ``set_drag_vertical_offset()``.
319319
- Camera2D's ``make_current()`` is now ``set_current()``.
320+
- CanvasItem's ``update()`` is now ``queue_redraw()``.
320321
- Control's ``set_tooltip()`` is now ``set_tooltip_text()``.
321322
- EditorNode3DGizmoPlugin's ``create_gizmo()`` is now ``_create_gizmo()``
322323
(note the leading underscore, which denotes a virtual method).
323324
- ENetMultiplayerPeer's ``get_peer_port()`` is now ``get_peer()``.
324325
- FileDialog's ``get_mode()`` is now ``get_file_mode()``.
325326
- FileDialog's ``set_mode()`` is now ``set_file_mode()``.
326327
- GraphNode's ``get_offset()`` is now ``get_position_offset()``.
328+
- GridMap's ``world_to_map()`` is now ``local_to_map()``.
329+
- GridMap's ``map_to_world()`` is now ``map_to_local()``.
330+
- Image's ``get_rect()`` is now ``get_region()``.
327331
- ItemList's ``get_v_scroll()`` is now ``get_v_scroll_bar()``.
328332
- MultiPlayerAPI's ``get_network_connected_peers()`` is now ``get_peers()``.
329333
- MultiPlayerAPI's ``get_network_peer()`` is now ``get_peer()``.
@@ -335,6 +339,8 @@ Due to how the project upgrade tool works, not all
335339
- ResourceFormatLoader's ``get_dependencies()`` is now ``_get_dependencies()``
336340
(note the leading underscore, which denotes a virtual method).
337341
- Shortcut's ``is_valid()`` is now ``has_valid_event()``.
342+
- TileMap's ``world_to_map()`` is now ``local_to_map()``.
343+
- TileMap's ``map_to_world()`` is now ``map_to_local()``.
338344

339345
**Properties**
340346

@@ -346,8 +352,10 @@ Due to how the project upgrade tool works, not all
346352
``set_progress()`` and ``get_progress()`` respectively.
347353

348354
- Control's ``margin`` is now ``offset``.
355+
- Label's ``percent_visible`` is now ``visible_ratio``.
349356
- MultiPlayerAPI's ``refuse_new_network_connections`` is now ``refuse_new_connections``.
350357
- PathFollow2D and PathFollow3D's ``offset`` is now ``progress``.
358+
- TextureProgressBar's ``percent_visible`` is now ``show_percentage``.
351359
- The ``extents`` property on CSG nodes and VoxelGI will have to be replaced
352360
with ``size``, with the set value halved (as they're no longer half-extents).
353361
This also affects its setter/getter methods ``set_extents()`` and
@@ -414,7 +422,19 @@ The most notable examples of this are:
414422
- ``randomize()`` is now automatically called on project load, so deterministic
415423
randomness with the global RandomNumberGenerate instance requires manually
416424
setting a seed in a script's ``_ready()`` function.
417-
- ``OS.get_system_time_secs()`` should be converted to ``Time.get_time_dict_from_system()["second"]``.
425+
- AnimatedTexture's ``fps`` property was replaced by ``speed_scale``, which
426+
works the same as AnimationPlayer's ``playback_speed`` property.
427+
- AnimatedSprite2D and AnimatedSprite3D now allow negative ``speed_scale``
428+
values. This may break animations if you relied on ``speed_scale`` being
429+
internally clamped to ``0.0``.
430+
- BaseButton's signals are now ``button_up`` and ``button_down``. The
431+
``pressed`` property is now ``button_pressed``.
432+
- Camera2D's ``rotating`` property was replaced by ``ignore_rotation``, which
433+
has inverted behavior.
434+
- Camera2D's ``zoom`` property was inverted: higher values are now more zoomed
435+
in, instead of less.
436+
- ``OS.get_system_time_secs()`` should be converted to
437+
``Time.get_time_dict_from_system()["second"]``.
418438
- A :ref:`class_StreamPeerTCP` must have ``poll()`` called on it to update its
419439
state, instead of relying on ``get_status()`` automatically polling:
420440
`GH-59582 <https://github.com/godotengine/godot/pull/59582>`__

0 commit comments

Comments
 (0)