fixes, simple

This commit is contained in:
Paul Liverman III 2017-04-13 08:11:45 -07:00
parent 630cb51b59
commit adb74f476a
9 changed files with 38 additions and 31 deletions

View File

@ -426,7 +426,7 @@
</div> <!-- id="main" --> </div> <!-- id="main" -->
<div id="about"> <div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i> <i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i>
<i style="float:right;">Last updated 2017-04-12 03:37:15 </i> <i style="float:right;">Last updated 2017-04-13 08:11:30 </i>
</div> <!-- id="about" --> </div> <!-- id="about" -->
</div> <!-- id="container" --> </div> <!-- id="container" -->
</body> </body>

View File

@ -144,7 +144,7 @@
</div> <!-- id="main" --> </div> <!-- id="main" -->
<div id="about"> <div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i> <i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i>
<i style="float:right;">Last updated 2017-04-12 03:37:15 </i> <i style="float:right;">Last updated 2017-04-13 08:11:30 </i>
</div> <!-- id="about" --> </div> <!-- id="about" -->
</div> <!-- id="container" --> </div> <!-- id="container" -->
</body> </body>

View File

@ -84,7 +84,7 @@
</div> <!-- id="main" --> </div> <!-- id="main" -->
<div id="about"> <div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i> <i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i>
<i style="float:right;">Last updated 2017-04-12 03:37:15 </i> <i style="float:right;">Last updated 2017-04-13 08:11:30 </i>
</div> <!-- id="about" --> </div> <!-- id="about" -->
</div> <!-- id="container" --> </div> <!-- id="container" -->
</body> </body>

View File

@ -491,7 +491,7 @@
</div> <!-- id="main" --> </div> <!-- id="main" -->
<div id="about"> <div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i> <i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i>
<i style="float:right;">Last updated 2017-04-12 03:37:15 </i> <i style="float:right;">Last updated 2017-04-13 08:11:30 </i>
</div> <!-- id="about" --> </div> <!-- id="about" -->
</div> <!-- id="container" --> </div> <!-- id="container" -->
</body> </body>

View File

@ -105,7 +105,7 @@
</div> <!-- id="main" --> </div> <!-- id="main" -->
<div id="about"> <div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i> <i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i>
<i style="float:right;">Last updated 2017-04-12 03:37:15 </i> <i style="float:right;">Last updated 2017-04-13 08:11:30 </i>
</div> <!-- id="about" --> </div> <!-- id="about" -->
</div> <!-- id="container" --> </div> <!-- id="container" -->
</body> </body>

View File

@ -758,7 +758,7 @@ table.insert element.parent, element.parent\removeChild(element),
</div> <!-- id="main" --> </div> <!-- id="main" -->
<div id="about"> <div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i> <i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i>
<i style="float:right;">Last updated 2017-04-12 03:37:15 </i> <i style="float:right;">Last updated 2017-04-13 08:11:30 </i>
</div> <!-- id="about" --> </div> <!-- id="about" -->
</div> <!-- id="container" --> </div> <!-- id="container" -->
</body> </body>

View File

@ -126,7 +126,7 @@
</div> <!-- id="main" --> </div> <!-- id="main" -->
<div id="about"> <div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i> <i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i>
<i style="float:right;">Last updated 2017-04-12 03:37:15 </i> <i style="float:right;">Last updated 2017-04-13 08:11:30 </i>
</div> <!-- id="about" --> </div> <!-- id="about" -->
</div> <!-- id="container" --> </div> <!-- id="container" -->
</body> </body>

View File

@ -122,20 +122,25 @@ do
for i = #self.child, 1, -1 do for i = #self.child, 1, -1 do
self.child[i]:delete() self.child[i]:delete()
end end
for i = 1, #self.parent.child do if self.parent then
if self.parent.child[i] == self then for i = 1, #self.parent.child do
table.remove(self.parent.child, i) if self.parent.child[i] == self then
break table.remove(self.parent.child, i)
break
end
end end
end end
for i = 1, #self.parent.data.child do if self.parent then
if self.parent.data.child[i] == self.data then for i = 1, #self.parent.data.child do
table.remove(self.parent.data.child, i) if self.parent.data.child[i] == self.data then
break table.remove(self.parent.data.child, i)
break
end
end end
end end
self.parent = nil self.parent = nil
self.data.parent = nil self.data.parent = nil
self = nil
end end
} }
_base_0.__index = _base_0 _base_0.__index = _base_0

View File

@ -92,7 +92,7 @@ class element
dx = @data.x - dx dx = @data.x - dx
dy = @data.y - dy dy = @data.y - dy
for child in *@child for child in *@child
child\move dx, dy child\move dx, dy
return @ return @
@ -144,7 +144,7 @@ class element
--- @treturn element self --- @treturn element self
move: (x=0, y=0) => move: (x=0, y=0) =>
for child in *@child for child in *@child
child\move x, y child\move x, y
@data.x += x @data.x += x
@data.y += y @data.y += y
@ -152,20 +152,22 @@ class element
--- Deletes references to this element and then deletes it. --- Deletes references to this element and then deletes it.
delete: => delete: =>
for i=#@child, 1, -1 for i=#@child, 1, -1
@child[i]\delete! @child[i]\delete!
for i=1, #@parent.child if @parent
if @parent.child[i] == @ for i=1, #@parent.child
table.remove @parent.child, i if @parent.child[i] == @
break table.remove @parent.child, i
break
for i=1, #@parent.data.child if @parent
if @parent.data.child[i] == @data for i=1, #@parent.data.child
table.remove @parent.data.child, i if @parent.data.child[i] == @data
break table.remove @parent.data.child, i
break
@parent = nil @parent = nil
@data.parent = nil -- should be for all @ -> nil @data.parent = nil -- should be for all @ -> nil MAYBE
--@ = nil <- or that, does that work? Idk @ = nil
-- DO NOT DELETE @data though, it could still be in use -- DO NOT DELETE @data though, it could still be in use