mirror of
https://github.com/rm-code/Graphoon.git
synced 2024-11-16 18:24:22 +00:00
Add Edge and Node classes to init.lua
This way they can be required separately from the Graph class.
This commit is contained in:
parent
4e5e302d32
commit
73b74ca3fe
@ -1,3 +1,5 @@
|
|||||||
|
local current = (...):gsub('%.[^%.]+$', '');
|
||||||
|
|
||||||
local Edge = {};
|
local Edge = {};
|
||||||
|
|
||||||
function Edge.new( id, origin, target )
|
function Edge.new( id, origin, target )
|
||||||
|
@ -1,3 +1,5 @@
|
|||||||
|
local current = (...):gsub('%.[^%.]+$', '');
|
||||||
|
|
||||||
local Node = {};
|
local Node = {};
|
||||||
|
|
||||||
local FORCE_SPRING = -0.01;
|
local FORCE_SPRING = -0.01;
|
||||||
|
@ -1 +1,5 @@
|
|||||||
return { Graph = require( (...):gsub('%.init$', '') .. '.Graph' ) };
|
return {
|
||||||
|
Edge = require( (...):gsub('%.init$', '') .. '.Edge' ),
|
||||||
|
Graph = require( (...):gsub('%.init$', '') .. '.Graph' ),
|
||||||
|
Node = require( (...):gsub('%.init$', '') .. '.Node' )
|
||||||
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user