read a .we minetest schema

- use ground has maze walls
This commit is contained in:
philippe lhardy
2020-11-04 22:12:17 +01:00
parent 6402766371
commit 52a2d3f1e3
13 changed files with 430 additions and 16 deletions

View File

@@ -1,5 +1,7 @@
package org.artisanlogiciel.lua;
import org.artisanlogiciel.games.minetest.World;
import java.util.ArrayList;
import java.util.List;
@@ -128,7 +130,7 @@ public class Parser {
return new LuaNumber(number);
}
LuaObject parse()
public LuaObject parse()
{
char c = 0;
while ( ((c = getNextchar()) != 0 ) && ( errors == null ))
@@ -223,6 +225,9 @@ public class Parser {
System.out.println(result.toString());
Object we = result.wrapToJava();
System.out.println(we);
World world = new World();
world.addList( (List<Object>) we);
System.out.println(world);
}
else
{