diff --git a/fd/Graph.lua b/fd/Graph.lua index e7a872b..6b84cb2 100644 --- a/fd/Graph.lua +++ b/fd/Graph.lua @@ -64,9 +64,10 @@ function Graph.new() -- @param y - The y coordinate the Node should be spawned at (optional). -- @param anchor - Wether the node should be locked in place or not (optional). -- - function self:addNode( id, x, y, anchor ) + function self:addNode( id, x, y, anchor, ... ) + print( id, x, y, anchor, parent, path, spritebatch ) assert( not nodes[id], "Node IDs must be unique." ); - nodes[id] = Node.new( id, x, y, anchor ); + nodes[id] = Node.new( id, x, y, anchor, ... ); return nodes[id]; end diff --git a/fd/Node.lua b/fd/Node.lua index c01b685..bd66e20 100644 --- a/fd/Node.lua +++ b/fd/Node.lua @@ -17,7 +17,7 @@ local DEFAULT_MASS = 0.05; -- @param y - The y coordinate the Node should be spawned at (optional). -- @param anchor - Wether the node should be locked in place or not (optional). -- -function Node.new( id, x, y, anchor ) +function Node.new( id, x, y, anchor, ... ) local self = {}; local px, py = x or 0, y or 0;