mirror of
https://github.com/tonytins/citylimits.git
synced 2025-03-22 07:22:20 +00:00
- Upgraded to Godot 4 - Just remembered the basic principles are based on a tile editor, and dramatically simplified from there. Derp. - New state machine and license display add-ons. - Re-licensed under the GPL because Micropolis' assets aren't under a separate one.
25 lines
922 B
GDScript
25 lines
922 B
GDScript
@tool
|
|
extends EditorPlugin
|
|
|
|
|
|
## It uses the icons provided by the scripts anyway, so
|
|
## we don't really need to specify the real ones here.
|
|
## Plus, it might help with enabling it before the project
|
|
## has been reloaded for the first time.
|
|
var placeholder_texture := PlaceholderTexture2D.new()
|
|
|
|
|
|
func _enter_tree() -> void:
|
|
add_custom_type("State", "Node", State, placeholder_texture)
|
|
add_custom_type("RandomState", "Node", RandomState, placeholder_texture)
|
|
add_custom_type("AnimationState", "Node", AnimationState, placeholder_texture)
|
|
add_custom_type("SequenceState", "Node", SequenceState, placeholder_texture)
|
|
add_custom_type("StateMachineDebugger", "Tree", StateMachineDebugger, placeholder_texture)
|
|
|
|
|
|
func _exit_tree() -> void:
|
|
remove_custom_type("State")
|
|
remove_custom_type("RandomState")
|
|
remove_custom_type("AnimationState")
|
|
remove_custom_type("SequenceState")
|
|
remove_custom_type("StateMachineDebugger")
|