Postby Emral » Fri Dec 13, 2019 1:02 am
To make a block that only lacks collision if you're playing in the editor, you can do the following check in your luna.lua file:
if Misc.inEditor() then
Block.config[BLOCK_ID].passthrough = true
end
You have to replace BLOCK_ID with the numeric ID of the block which you want to be nonsolid.
Alternative interpretations:
"A block that doesn't collide with other objects in the editor" -> Just cut-pasting blocks around is honestly an easier solution.
"Editing a block's collision through the editor" -> Not possible. Set the passthrough flag like above in your level luna.lua file. If you want it to be nonsolid even when not playing in the editor, just omit the conditional. In the future, you will be able to use block-n.txt files to set the passthrough flag instead, but not yet.