change editor_mode to editor.active, minor refactor, and start work on multiselect

This commit is contained in:
binarycat
2022-03-12 11:46:45 -05:00
parent 27f1dc71c0
commit f091fba9f7
3 changed files with 19 additions and 16 deletions

View File

@@ -1,11 +1,15 @@
assert(editor == nil)
editor = {
active = false,
room_mode = false,
--palette_mode = false,
palette = {
active = false,
scroll = Point:new(0, 0),
},
multiselect = {
active = false,
box = nil,
},
pan = { fixed = false, speed = 3 },
}
@@ -89,13 +93,6 @@ function stepEditor()
end,
}):activate()
end
if Keybind:checkPressed(Keybind.debug.editor) then
editor_mode = not editor_mode
deselectSpawns()
createTileObjects()
restartGame()
end
end
function scrollEditor(y)

View File

@@ -53,10 +53,6 @@ function stepGame()
initMenu("dialog",dialog_sequence.example)
end
if Keybind:checkPressed(Keybind.debug.editor) then
editor_mode = true
end
if Keybind:checkPressed(Keybind.debug.recording) then
if DemoRecording then
Demo:endRecord()