+ Added core base for dew
This commit is contained in:
@@ -0,0 +1,5 @@
|
|||||||
|
package commands.dew.core.api;
|
||||||
|
|
||||||
|
public interface IDewCore {
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
package commands.dew.core.api;
|
||||||
|
|
||||||
|
public interface IDewLuaCore
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
package commands.dew.core.api;
|
||||||
|
|
||||||
|
public interface IDewLuaSerializable<T>
|
||||||
|
{
|
||||||
|
// Type info for derived class encoded in T
|
||||||
|
}
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
package commands.dew.core.api;
|
||||||
|
|
||||||
|
public interface IDewPlayer
|
||||||
|
{
|
||||||
|
public String getName();
|
||||||
|
}
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
package commands.dew.core.data;
|
||||||
|
|
||||||
|
import commands.dew.core.api.IDewLuaSerializable;
|
||||||
|
|
||||||
|
public final class DewMap implements IDewLuaSerializable<DewMap>
|
||||||
|
{
|
||||||
|
public int mapWidth = 20;
|
||||||
|
public int mapHeight = 20;
|
||||||
|
public DewMapTile[][] map;
|
||||||
|
}
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package commands.dew.core.data;
|
||||||
|
|
||||||
|
public enum DewMapTile
|
||||||
|
{
|
||||||
|
Default(0), Tree(1);
|
||||||
|
|
||||||
|
private final int value;
|
||||||
|
private DewMapTile(int value)
|
||||||
|
{
|
||||||
|
this.value = value;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getValue()
|
||||||
|
{
|
||||||
|
return value;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package commands.dew.core.impl;
|
||||||
|
|
||||||
|
import java.lang.reflect.Field;
|
||||||
|
|
||||||
|
import commands.dew.core.api.IDewLuaCore;
|
||||||
|
import commands.dew.core.api.IDewLuaSerializable;
|
||||||
|
|
||||||
|
public class DewLuaCore implements IDewLuaCore
|
||||||
|
{
|
||||||
|
public void Parse(IDewLuaSerializable item)
|
||||||
|
{
|
||||||
|
for(Field field : item.getClass().getDeclaredFields())
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user