浏览代码

Merge pull request #99872 from HolonProduction/plugin-template

Add `_enable`/`_disable_plugin` to plugin script template
Rémi Verschelde 5 月之前
父节点
当前提交
d3676e9352
共有 1 个文件被更改,包括 10 次插入0 次删除
  1. 10 0
      modules/gdscript/editor/script_templates/EditorPlugin/plugin.gd

+ 10 - 0
modules/gdscript/editor/script_templates/EditorPlugin/plugin.gd

@@ -4,6 +4,16 @@
 extends _BASE_
 
 
+func _enable_plugin() -> void:
+	# Add autoloads here.
+	pass
+
+
+func _disable_plugin() -> void:
+	# Remove autoloads here.
+	pass
+
+
 func _enter_tree() -> void:
 	# Initialization of the plugin goes here.
 	pass