Serializable component

You can remove the component to tell Concord an Entity shouldn't be serialized.

It's given automatically on Entity creation, but this can be disabled by changing Entity.SERIALIZE_BY_DEFAULT to false.
This commit is contained in:
Pablo Ariel Mayobre 2023-02-14 18:14:24 -03:00 committed by Pablo Mayobre
parent c5c056f566
commit afc5643755
No known key found for this signature in database
GPG key ID: 13A2F589D013E0E7
4 changed files with 32 additions and 4 deletions

View file

@ -0,0 +1,12 @@
local PATH = (...):gsub('%.builtins%.[^%.]+$', '')
local Component = require(PATH..".component")
local Serializable = Component("serializable")
function Serializable:serialize ()
-- Don't serialize this Component
return nil
end
return Serializable