@tool
extends EditorPlugin

const AUTOLOAD_NAME := "ReedVFX"
const AUTOLOAD_PATH := "res://addons/reedfx/vfx/ReedVFXSystem.tscn"

func _enter_tree() -> void:
	# 1) 自动加载单例
	if not ProjectSettings.has_setting("autoload/%s" % AUTOLOAD_NAME):
		add_autoload_singleton(AUTOLOAD_NAME, AUTOLOAD_PATH)

func _exit_tree() -> void:
	if ProjectSettings.has_setting("autoload/%s" % AUTOLOAD_NAME):
		remove_autoload_singleton(AUTOLOAD_NAME)
