SweatyReptile/loser — pull request #51 by mnopbop (2014-07-09 09:03:13+00:00)
Title: Level Editor

Level Editor
=========
Where do I start... this is way too big for a single Pull Request.

Levels are (automatically) loaded from the `data/levels/` dir as from json files, and can be edited using the in-game editor.

Loads of new commands for LevelManager:
```
- level ---(renamed)--> lvl
- instantiate ---(renamed)--> lvl_new
- lvl_new alias type name width height timelimit
- lvl_new alias type name
- lvl_new alias name
- lvl_save
- lvl_load alias
- lvl_load alias alternate_alias
- lvl_reload_all
- edit
- play
- saveplay
- restart
- entity name
- entity name bodytype
- entity_rm name
- bg bgname
```

Creating a new level
--------------------------
* Use any form `lvl_new` command to create a new level.
* This level will not be saved until `lvl_save` or `saveplay` are called.

Editing a level
------------------
* **In order to for you changes to be saved, you must call `lvl_save` or `saveplay` after editing!**
* Use the `edit` command to reopen the level in edit mode.
* Use the `entity` command to create entities
* Use the `entity_rm` command to delete entities
* An entity can be moved by dragging the box near its bottom left corner.
* Use the `bg` command to change the background
* Use the `play` command to play the level **without** saving your changes

If you accidentally saved a level over a previous version that you actually wanted to keep, you'd better hope it's available in a previous git revision :D