From fa3f598fc3b91d92665fda293460944f75c95b67 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Fri, 9 Nov 2018 17:02:39 -0800 Subject: Fixing the upgrade pipeline, plus some misc. fixes. --- nomsu_decompiler.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'nomsu_decompiler.lua') diff --git a/nomsu_decompiler.lua b/nomsu_decompiler.lua index a3d7f41..77905e5 100644 --- a/nomsu_decompiler.lua +++ b/nomsu_decompiler.lua @@ -179,7 +179,7 @@ tree_to_inline_nomsu = function(tree) elseif "FileChunks" == _exp_0 then return error("Can't inline a FileChunks") elseif "Comment" == _exp_0 then - return nil + return NomsuCode:from(tree.source) elseif "Error" == _exp_0 then return error("Can't compile errors") else @@ -397,7 +397,7 @@ tree_to_nomsu = function(tree) nomsu:append(": ", value_nomsu) return nomsu elseif "Comment" == _exp_0 then - nomsu:append("#", tree[1]:gsub("\n", "\n ")) + nomsu:append("#", (tree[1]:gsub("\n", "\n "))) return nomsu elseif "IndexChain" == _exp_0 or "Number" == _exp_0 or "Var" == _exp_0 or "Comment" == _exp_0 or "Error" == _exp_0 then return tree_to_inline_nomsu(tree) -- cgit v1.2.3