Separated protected functions from public functions

This commit is contained in:
Robert Jelic
2025-02-24 23:13:28 +01:00
parent 13d3bbd461
commit e65e6510e0
4 changed files with 42 additions and 28 deletions

View File

@@ -1,23 +0,0 @@
-- Will temporary exist so that we don't lose track of how the plugin system works
local VisualElement = {hooks={init={}}}
-- Called on Class level to define properties and setup before instance is created
function VisualElement.setup(element)
element.defineProperty(element, "testProp", {default = 5, type = "number"})
end
-- Hooks into existing methods (you can also use init.pre or init.post)
function VisualElement.hooks.init(self)
--self.basalt.LOGGER.debug("VisualElement initialized")
end
-- Adds a new method to the class
function VisualElement:testFunc()
--self.basalt.LOGGER.debug("Hello World", self.get("testProp"))
end
return {
VisualElement = VisualElement
}

View File

@@ -1,6 +1,5 @@
local errorManager = require("errorManager")
local PropertySystem = require("propertySystem")
local log = require("log")
local protectedNames = {
colors = true,