Fixed variable casting when outputting from IronPython scope.

This commit is contained in:
ruri
2019-04-05 18:47:08 +02:00
parent 0e69bd0cc0
commit 6508fb63d7
+1 -1
View File
@@ -516,7 +516,7 @@ namespace RuriLib.LS
{
// Add it to the variables and print info
var value = scope.GetVariable(name);
data.Variables.Set(new CVar(name, (value.GetType() == typeof(string[])) ? CVar.VarType.List : CVar.VarType.Single, value));
data.Variables.Set(new CVar(name, (value.GetType() == typeof(string[])) ? CVar.VarType.List : CVar.VarType.Single, value.ToString()));
data.Log(new LogEntry($"SET VARIABLE {name} WITH VALUE {value}", Colors.Yellow));
}
catch { data.Log(new LogEntry($"COULD NOT FIND VARIABLE {name}", Colors.Tomato)); }