Page 1 of 1

Level editor using SVG files

Posted: Fri Feb 08, 2013 11:13 pm
by FREEZX
So i had this idea about making a unified level editor that should more or less satisfy most level designers and programmers altogether.
I started the project which is currently in a very early phase of development.
I was thinking about how object scripting would work and settled with a model similar to the unity engine. Currently each object can have update, onload and onclick functions.
As for the objects themselves, currently only rectangles, images and groups are supported.
n8dZ01L.png
n8dZ01L.png (121.1 KiB) Viewed 375 times
You can check out the project on bitbucket:
https://bitbucket.org/FREEZX/l-ve2d-svg-level-editor

Tell me what you guys think.

Re: Level editor using SVG files

Posted: Wed Feb 13, 2013 10:35 am
by FREEZX
reserved

Re: Level editor using SVG files

Posted: Thu Feb 14, 2013 11:15 am
by monsieur_h
Didn't know that svg files were in xml. Your idea is really interesting, I recently tried to have a good idea for a level editor, but did not find any.
I'll follow your progress closely. Do you intend to share the code eventually?

Also, in my opinion, this thread belongs to Project and Demos.

Re: Level editor using SVG files

Posted: Thu Feb 14, 2013 6:00 pm
by Xgoff
interesting. how much of svg are you planning to implement? months ago i considered writing a lib that would "compile" an svg document into a sequence of love.graphics functions... i thought svg tiny would be a good starting point until i realized the spec was over 400 pages lol

Re: Level editor using SVG files

Posted: Sun Feb 17, 2013 11:33 am
by FREEZX
The code is already available on bitbucket:
https://bitbucket.org/FREEZX/l-ve2d-svg-level-editor

I was thinking about implementing circles, polygons, and maybe arcs since that would cover most of the needed shapes. I do realise that there is a lot to SVG, so i'm not going to implement the whole thing. I think the Corona SDK also uses SVG files for levels.

What i'm trying to do is keep it flexible enough so you can do most things with it. Right now you can write onupdate, onload and onclick Lua code within the objects in the SVG file. Please do check the code as well as the example levels (Not much to them, but it is a proof of concept). If you have ever used Unity3d, the scripting should have a similar concept.