mirror of
https://github.com/Ale32bit/Capy64.git
synced 2025-01-18 18:46:43 +00:00
Fixed mess up
This commit is contained in:
parent
9d978fd9ab
commit
0f4acff113
3 changed files with 4 additions and 4 deletions
|
@ -19,13 +19,13 @@ public static class Utils
|
|||
long i = 1;
|
||||
foreach (var item in iterable)
|
||||
{
|
||||
L.PushObject(item);
|
||||
L.PushValue(item);
|
||||
L.RawSetInteger(-2, i++);
|
||||
}
|
||||
L.SetTop(-1);
|
||||
}
|
||||
#nullable enable
|
||||
public static int PushObject(this Lua L, object? obj)
|
||||
public static int PushValue(this Lua L, object? obj)
|
||||
{
|
||||
var type = obj?.GetType();
|
||||
switch (obj)
|
||||
|
|
|
@ -450,7 +450,7 @@ public class FileSystem : IPlugin
|
|||
foreach (var attribute in attributes)
|
||||
{
|
||||
L.PushString(attribute.Key);
|
||||
Extensions.Utils.PushObject(L, attribute.Value);
|
||||
L.PushValue(attribute.Value);
|
||||
|
||||
L.SetTable(-3);
|
||||
}
|
||||
|
|
|
@ -124,7 +124,7 @@ public class Runtime
|
|||
{
|
||||
foreach (var par in ev.Parameters)
|
||||
{
|
||||
Thread.PushObject(par);
|
||||
Thread.PushValue(par);
|
||||
}
|
||||
}
|
||||
return (ev.Parameters?.Length ?? 0) + 1;
|
||||
|
|
Loading…
Reference in a new issue