Skip to content

Commit

Permalink
fix: plugin setting doesn't show
Browse files Browse the repository at this point in the history
refers to: #164
  • Loading branch information
Ark2000 committed Feb 23, 2024
1 parent 835a05c commit 58b3e4b
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions addons/panku_console/plugin.gd
Original file line number Diff line number Diff line change
Expand Up @@ -57,16 +57,18 @@ func safe_remove_singleton() -> void:
remove_autoload_singleton(SINGLETON_NAME)


func _enable_plugin() -> void:
ProjectSettings.set_setting(panku_option(OPTIONS.DISABLE_ON_RELEASE), false)
ProjectSettings.set_initial_value(panku_option(OPTIONS.DISABLE_ON_RELEASE), false)
ProjectSettings.save()
func create_setting() -> void:
if not ProjectSettings.has_setting(panku_option(OPTIONS.DISABLE_ON_RELEASE)):
ProjectSettings.set_setting(panku_option(OPTIONS.DISABLE_ON_RELEASE), false)
ProjectSettings.set_initial_value(panku_option(OPTIONS.DISABLE_ON_RELEASE), false)
ProjectSettings.save()


func _enter_tree() -> void:
exporter = PankuExporter.new()
exporter.owner = self
add_export_plugin(exporter)
create_setting()

safe_add_singleton()
print("Panku Console initialized! Project page: https://github.com/Ark2000/PankuConsole")
Expand Down

0 comments on commit 58b3e4b

Please sign in to comment.