mirror of
https://github.com/Keyslam-Group/Concord.git
synced 2025-09-02 12:24:11 -04:00
Documented :destroy
This commit is contained in:
parent
4b8b6a6f88
commit
7053d91c80
1 changed files with 10 additions and 6 deletions
|
@ -36,12 +36,6 @@ function Entity:remove(component)
|
|||
return self
|
||||
end
|
||||
|
||||
function Entity:destroy()
|
||||
for i = 1, self.instances.size do
|
||||
self.instances:get(i):removeEntity(self)
|
||||
end
|
||||
end
|
||||
|
||||
--- Checks the Entity against the pools again.
|
||||
-- @return self
|
||||
function Entity:apply()
|
||||
|
@ -56,6 +50,16 @@ function Entity:apply()
|
|||
return self
|
||||
end
|
||||
|
||||
--- Destroys the Entity.
|
||||
-- @return self
|
||||
function Entity:destroy()
|
||||
for i = 1, self.instances.size do
|
||||
self.instances:get(i):removeEntity(self)
|
||||
end
|
||||
|
||||
return self
|
||||
end
|
||||
|
||||
--- Gets a Component from the Entity.
|
||||
-- @param component The Component to get
|
||||
-- @return The Bag from the Component
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue