proper colour blending of light, opacity is now "how much RGB value the tile absorbs", added partial support of Japanese Kana and Icelandic in polyglot.csv

Former-commit-id: 9f9b510c8155f2d93fd428bd90692c2298105aa8
Former-commit-id: fc3f15d5b0127c212a12e5126a4954420aa076ad
This commit is contained in:
Song Minjae
2016-02-22 01:37:17 +09:00
parent 90c4154fb8
commit 60fdff7528
35 changed files with 298 additions and 233 deletions

View File

@@ -45,8 +45,8 @@ public class GameFontWhite extends GameFontBase {
);
uniHan = new SpriteSheet(
"./res/graphics/fonts/unifont_unihan"
+ (((Terrarum.gameLocale.contains("jp") || Terrarum.gameLocale.contains("ko")))
? "_jp" : "")
+ ((!Terrarum.gameLocale.contains("zh"))
? "_ja" : "")
+".png"
, W_UNIHAN, H_UNIHAN
);
@@ -79,8 +79,8 @@ public class GameFontWhite extends GameFontBase {
public void reloadUnihan() throws SlickException {
uniHan = new SpriteSheet(
"./res/graphics/fonts/unifont_unihan"
+ ((!Terrarum.gameLocale.contains("cn"))
? "_jp" : "")
+ ((!Terrarum.gameLocale.contains("zh"))
? "_ja" : "")
+".png"
, W_UNIHAN, H_UNIHAN
);

View File

@@ -55,7 +55,7 @@ public class Player extends ActorWithBody implements Controllable, Pocketed, Fac
private final int TSIZE = MapDrawer.TILE_SIZE;
private char LUMINANCE_RGB = 63999;
private char LUMINANCE_RGB = 1560;
private HashSet<Faction> factionSet = new HashSet<>();

View File

@@ -17,6 +17,7 @@ public class CommandInterpreter {
CommandInput[] cmd = parse(command);
for (CommandInput single_command : cmd) {
ConsoleCommand commandObj = null;
try {
if (single_command.getName().equalsIgnoreCase("auth")) {
Terrarum.game.auth.execute(single_command.toStringArray());
@@ -35,9 +36,9 @@ public class CommandInterpreter {
}
else {
if (Terrarum.game.auth.b()) {
ConsoleCommand commandObj = CommandDict.getCommand(
single_command.getName().toLowerCase());
commandObj.execute(single_command.toStringArray());
commandObj = CommandDict.getCommand(
single_command.getName().toLowerCase()
);
}
else {
throw new NullPointerException(); // if not authorised, say "Unknown command"
@@ -47,6 +48,17 @@ public class CommandInterpreter {
catch (NullPointerException e) {
echoUnknownCmd(single_command.getName());
}
finally {
try {
if (commandObj != null)
commandObj.execute(single_command.toStringArray());
}
catch (Exception e) {
System.out.println("[CommandInterpreter] ");
e.printStackTrace();
new Echo().execute(Lang.get("ERROR_GENERIC_TEXT"));
}
}
}
}

View File

@@ -5,7 +5,7 @@ package com.Torvald.Terrarum.ConsoleCommand;
*/
interface ConsoleCommand {
void execute(String[] args);
void execute(String[] args) throws Exception;
void printUsage();

View File

@@ -11,9 +11,9 @@ public class GetLocale implements ConsoleCommand {
public void execute(String[] args) {
new Echo().execute(
"Locale: "
+ Lang.get("MENU_LANGUAGE_THIS")
+ Lang.get("LANGUAGE_THIS")
+ " ("
+ Lang.get("MENU_LANGUAGE_THIS_EN")
+ Lang.get("LANGUAGE_EN")
+ ")"
);
}

View File

@@ -3,6 +3,7 @@ package com.Torvald.Terrarum.ConsoleCommand;
import com.Torvald.ImageFont.GameFontBase;
import com.Torvald.Terrarum.LangPack.Lang;
import com.Torvald.Terrarum.Terrarum;
import org.apache.commons.csv.CSVRecord;
import org.newdawn.slick.SlickException;
import java.io.IOException;
@@ -25,6 +26,13 @@ public class SetLocale implements ConsoleCommand {
Terrarum.gameLocale = prevLocale;
}
}
else if (args.length == 1) {
Echo echo = new Echo();
echo.execute("Locales:");
CSVRecord record = Lang.getRecord("LANGUAGE_ID");
record.forEach(field -> echo.execute("] " + field));
}
else {
printUsage();
}

View File

@@ -80,6 +80,15 @@ public class Lang {
lang.put(record.get(CSV_COLUMN_FIRST), record);
}
public static CSVRecord getRecord(String key) {
CSVRecord record = lang.get(key);
if (record == null) {
System.out.println("[Lang] No such record.");
throw new NullPointerException();
}
return record;
}
public static String get(String key) {
String value = null;
try { value = lang.get(key).get(Terrarum.gameLocale); }

View File

@@ -248,109 +248,80 @@ public class LightmapRenderer {
private static char calculate(int x, int y){
if (!outOfBounds(x, y)){
float lightColorR = 1f;
float lightColorG = 1f;
float lightColorB = 1f;
char lightColorInt;
char lightLevelThis = 0;
int thisTerrain = Terrarum.game.map.getTileFromTerrain(x, y);
int thisWall = Terrarum.game.map.getTileFromWall(x, y);
char thisTileLuminosity = TilePropCodex.getProp(thisTerrain).getLuminosity();
// open air
if (thisTerrain == AIR && thisWall == AIR) {
lightColorInt = Terrarum.game.map.getGlobalLight();
lightLevelThis = screenBlend(lightLevelThis, Terrarum.game.map.getGlobalLight());
}
else {
// mix light emitter
if (TilePropCodex.getProp(thisTerrain).getLuminosity() != 0) {
char lum = TilePropCodex.getProp(thisTerrain).getLuminosity();
lightColorR = getR(lum);
lightColorG = getG(lum);
lightColorB = getB(lum);
// mix luminous tile
if (thisTileLuminosity > 0) {
lightLevelThis = screenBlend(lightLevelThis, thisTileLuminosity);
}
// mix lantern
for (LightmapLantern lantern : lanterns) {
if (lantern.getX() == x && lantern.getY() == y) {
lightLevelThis = screenBlend(lightLevelThis, lantern.getIntensity());
break;
}
}
// mix lantern
for (LightmapLantern lantern : lanterns) {
if (lantern.getX() == x && lantern.getY() == y) {
char lum = lantern.getIntensity();
lightColorR = getR(lum);
lightColorG = getG(lum);
lightColorB = getB(lum);
break;
}
}
// mix luminous actor
// test player TODO for all actor.Luminous in the game
int tileX = Math.round(Terrarum.game.getPlayer().getHitbox().getPointedX() / TSIZE);
int tileY = Math.round(Terrarum.game.getPlayer().getHitbox().getPointedY() / TSIZE)
- 1;
char actorLuminosity = Terrarum.game.getPlayer().getLuminance();
if (x == tileX && y == tileY) {
lightLevelThis = screenBlend(lightLevelThis, actorLuminosity);
}
// mix actor Luminous
// test player TODO for all actor.Luminous in the game
int tileX = Math.round(Terrarum.game.getPlayer().getHitbox().getPointedX() / TSIZE);
int tileY = Math.round(Terrarum.game.getPlayer().getHitbox().getPointedY() / TSIZE)
- 1;
char lum = Terrarum.game.getPlayer().getLuminance();
if (x == tileX && y == tileY) {
lightColorR = getR(lum);
lightColorG = getG(lum);
lightColorB = getB(lum);
}
float[] bgrVal = new float[3]; // {B, G, R}
// test for each B, G, R channel
for (int i = 0; i < 3; i++) {
int brightest = 0;
//get brightest of nearby 4 tiles
int nearby = 0b0;
findNearbyBrightest:
for (int yoff = -1; yoff <= 1; yoff++) {
for (int xoff = -1; xoff <= 1; xoff++) {
/**
* filter for 'v's as:
* +-+-+-+
* |a|v|a|
* +-+-+-+
* |v| |v|
* +-+-+-+
* |a|v|a|
* +-+-+-+
*/
if (xoff != yoff && -xoff != yoff) { // 'v' tiles
if (!outOfMapBounds(x + xoff, y + yoff)) {
nearby = getRaw(staticLightMap[y + yoff][x + xoff], i);
}
}
else if (xoff != 0 && yoff != 0) { // 'a' tiles
if (!outOfMapBounds(x + xoff, y + yoff)) {
nearby = darken((char) getRaw(staticLightMap[y + yoff][x + xoff], i)
, 0x3); //mix some to have more 'spreading'
// so that light spreads in a shape of an octagon instead of a diamond
}
}
if (nearby > brightest) {
brightest = nearby;
}
if (brightest == CHANNEL_MAX) break findNearbyBrightest;
// calculate and mix ambient
char ambient = 0; char nearby = 0;
findNearbyBrightest:
for (int yoff = -1; yoff <= 1; yoff++) {
for (int xoff = -1; xoff <= 1; xoff++) {
/**
* filter for 'v's as:
* +-+-+-+
* |a|v|a|
* +-+-+-+
* |v| |v|
* +-+-+-+
* |a|v|a|
* +-+-+-+
*/
if (xoff != yoff && -xoff != yoff) { // 'v' tiles
if (!outOfMapBounds(x + xoff, y + yoff)) {
nearby = staticLightMap[y + yoff][x + xoff];
}
}
else if (xoff != 0 && yoff != 0) { // 'a' tiles
if (!outOfMapBounds(x + xoff, y + yoff)) {
nearby = darkenUniformInt(staticLightMap[y + yoff][x + xoff]
, 2);
// mix some to have more 'spreading'
// so that light spreads in a shape of an octagon instead of a diamond
}
}
else {
nearby = 0; // exclude 'me' tile
}
//return: brightest - opacity
bgrVal[i] = darkenFloat(
(char) (brightest)
, TilePropCodex.getProp(thisTerrain).getOpacity()
);
ambient = additiveBlend(ambient, nearby); // keep base value as brightest nearby
}
// construct lightColor from bgrVal
lightColorInt = constructRGBFromFloat(
bgrVal[OFFSET_R] * lightColorR
, bgrVal[OFFSET_G] * lightColorG
, bgrVal[OFFSET_B] * lightColorB
);
}
return lightColorInt;
char opacity = TilePropCodex.getProp(thisTerrain).getOpacity();
ambient = darkenColoured(ambient, opacity); // get real ambient by appling opacity value
return screenBlend(lightLevelThis, ambient);
}
else {
throw new IllegalArgumentException("Out of bounds of lightMap");
@@ -361,19 +332,43 @@ public class LightmapRenderer {
*
* @param data Raw channel value [0-39] per channel
* @param darken [0-39] per channel
* @return darkened data [0-9] per channel (darken-int divided by 39)
* @return darkened data [0-39] per channel
*/
private static float darkenFloat(char data, int darken) {
return (darken(data, darken) / CHANNEL_MAX_FLOAT);
private static char darkenColoured(char data, char darken) {
if (darken < 0 || darken >= COLOUR_DOMAIN_SIZE) { throw new IllegalArgumentException("darken: out of " +
"range"); }
float r = clampZero(getR(data) - getR(darken));
float g = clampZero(getG(data) - getG(darken));
float b = clampZero(getB(data) - getB(darken));
return constructRGBFromFloat(r, g, b);
}
/**
*
* @param data Raw channel value [0-39] per channel
* @param darken [0-39] per channel
* @return darkened data [0-39] per channel
* Darken each channel by 'darken' argument
* @param data [0-39] per channel
* @param darken [0-1]
* @return
*/
private static char darken(char data, int darken) {
private static char darkenUniformFloat(char data, float darken) {
if (darken < 0 || darken > 1f) { throw new IllegalArgumentException("darken: out of " +
"range"); }
float r = clampZero(getR(data) - darken);
float g = clampZero(getG(data) - darken);
float b = clampZero(getB(data) - darken);
return constructRGBFromFloat(r, g, b);
}
/**
* Darken each channel by 'darken' argument
* @param data [0-39] per channel
* @param darken [0-39]
* @return
*/
private static char darkenUniformInt(char data, int darken) {
if (darken < 0 || darken > CHANNEL_MAX) { throw new IllegalArgumentException("darken: out of " +
"range"); }
@@ -384,6 +379,46 @@ public class LightmapRenderer {
return constructRGBFromInt(r, g, b);
}
/**
*
* @param data Raw channel value [0-39] per channel
* @param brighten [0-39] per channel
* @return brightened data [0-39] per channel
*/
private static char brightenColoured(char data, char brighten) {
if (brighten < 0 || brighten >= COLOUR_DOMAIN_SIZE) { throw new IllegalArgumentException("brighten: out of " +
"range"); }
float r = clampFloat(getR(data) + getR(brighten));
float g = clampFloat(getG(data) + getG(brighten));
float b = clampFloat(getB(data) + getB(brighten));
return constructRGBFromFloat(r, g, b);
}
/**
*
* @param rgb
* @param rgb2
* @return
*/
private static char additiveBlend(char rgb, char rgb2) {
int r1 = getRawR(rgb); int r2 = getRawR(rgb2); int newR = (r1 > r2) ? r1 : r2;
int g1 = getRawG(rgb); int g2 = getRawG(rgb2); int newG = (g1 > g2) ? g1 : g2;
int b1 = getRawB(rgb); int b2 = getRawB(rgb2); int newB = (b1 > b2) ? b1 : b2;
return constructRGBFromInt(newR, newG, newB);
}
private static char screenBlend(char rgb, char rgb2) {
float r1 = getR(rgb); float r2 = getR(rgb2); float newR = 1 - (1 - r1) * (1 - r2);
float g1 = getG(rgb); float g2 = getG(rgb2); float newG = 1 - (1 - g1) * (1 - g2);
float b1 = getB(rgb); float b2 = getB(rgb2); float newB = 1 - (1 - b1) * (1 - b2);
return constructRGBFromFloat(newR, newG, newB);
}
public static int getRawR(char RGB) {
return RGB / MUL_2;
}
@@ -500,6 +535,10 @@ public class LightmapRenderer {
return (i < 0) ? 0 : (i > CHANNEL_MAX) ? CHANNEL_MAX : i;
}
private static float clampFloat(float i) {
return (i < 0) ? 0 : (i > 1) ? 1 : i;
}
public static char[][] getStaticLightMap() {
return staticLightMap;
}

View File

@@ -392,8 +392,13 @@ public class MapCamera {
if (ty < 0) ty = 0;
else if (ty >= map.width) ty = map.width;
if (!isOpaque(map.getTileFromTerrain(tx, ty))) {
return true;
try {
if (!isOpaque(map.getTileFromTerrain(tx, ty))) {
return true;
}
}
catch (ArrayIndexOutOfBoundsException e) {
return false;
}
}
return false;

View File

@@ -8,7 +8,7 @@ public class TileProp {
private int id;
private String name;
private int opacity;
private char opacity;
private int strength;
@@ -42,11 +42,11 @@ public class TileProp {
this.name = name;
}
public int getOpacity() {
public char getOpacity() {
return opacity;
}
void setOpacity(int opacity) {
void setOpacity(char opacity) {
this.opacity = opacity;
}

View File

@@ -60,7 +60,7 @@ public class TilePropCodex {
prop.setId(intVal(record, "id"));
prop.setOpacity(intVal(record, "opacity"));
prop.setOpacity((char) intVal(record, "opacity"));
prop.setStrength(intVal(record, "strength"));
prop.setLuminosity((char) intVal(record, "lumcolor"));
prop.setDrop(intVal(record, "drop"));
@@ -71,7 +71,7 @@ public class TilePropCodex {
prop.setWallable(boolVal(record, "wall"));
prop.setFallable(boolVal(record, "fall"));
if (prop.isFluid()) prop.setOpacity(intVal(record, "opacity"));
if (prop.isFluid()) prop.setViscocity(intVal(record, "opacity"));
System.out.print(prop.getId());
System.out.println("\t" + prop.getName());

View File

@@ -1,38 +1,38 @@
"id";"name" ;"opacity";"strength";"fluid";"viscosity";"solid";"wall";"lumcolor";"drop";"fall";"friction"
# Friction: 0: frictionless, <16: slippery, 16: regular, >16: sticky
"0";"TILE_AIR" ; "1"; "0"; "0"; "N/A"; "0"; "0"; "0"; "0"; "0";"16"
"1";"TILE_STONE" ; "5"; "25"; "0"; "N/A"; "1"; "1"; "0"; "1"; "0";"16"
"2";"TILE_DIRT" ; "5"; "6"; "0"; "N/A"; "1"; "1"; "0"; "2"; "0";"16"
"3";"TILE_GRASS" ; "5"; "6"; "0"; "N/A"; "1"; "1"; "0"; "2"; "0";"16"
"4";"TILE_PLANK_NORMAL" ; "5"; "12"; "0"; "N/A"; "1"; "1"; "0"; "4"; "0";"16"
"5";"TILE_PLANK_EBONY" ; "5"; "12"; "0"; "N/A"; "1"; "1"; "0"; "5"; "0";"16"
"6";"TILE_PLANK_BIRCH" ; "5"; "12"; "0"; "N/A"; "1"; "1"; "0"; "6"; "0";"16"
"7";"TILE_PLANK_BLOODROSE" ; "5"; "12"; "0"; "N/A"; "1"; "1"; "0"; "7"; "0";"16"
"8";"TILE_TRUNK_NORMAL" ; "5"; "12"; "0"; "N/A"; "1"; "0"; "0"; "8"; "0";"16"
"9";"TILE_TRUNK_EBONY" ; "5"; "12"; "0"; "N/A"; "1"; "0"; "0"; "9"; "0";"16"
"10";"TILE_TRUNK_BIRCH" ; "5"; "12"; "0"; "N/A"; "1"; "0"; "0"; "10"; "0";"16"
"11";"TILE_TRUNK_BLOODROSE" ; "5"; "12"; "0"; "N/A"; "1"; "0"; "0"; "11"; "0";"16"
"12";"TILE_STONE_QUARRIED" ; "5"; "25"; "0"; "N/A"; "1"; "1"; "0"; "12"; "0";"16"
"13";"TILE_SAND" ; "5"; "6"; "0"; "N/A"; "1"; "1"; "0"; "13"; "1";"16"
"14";"TILE_GRAVEL" ; "5"; "6"; "0"; "N/A"; "1"; "0"; "0"; "14"; "1";"16"
# Friction: 0: frictionless, <16: slippery, 16: regular, >16: sticky | Opacity/Lumcolor: 40-step RGB
"0";"TILE_AIR" ; "1641"; "0"; "0"; "N/A"; "0"; "0"; "0"; "0"; "0";"16"
"1";"TILE_STONE" ; "8205"; "25"; "0"; "N/A"; "1"; "1"; "0"; "1"; "0";"16"
"2";"TILE_DIRT" ; "8205"; "6"; "0"; "N/A"; "1"; "1"; "0"; "2"; "0";"16"
"3";"TILE_GRASS" ; "8205"; "6"; "0"; "N/A"; "1"; "1"; "0"; "2"; "0";"16"
"4";"TILE_PLANK_NORMAL" ; "8205"; "12"; "0"; "N/A"; "1"; "1"; "0"; "4"; "0";"16"
"5";"TILE_PLANK_EBONY" ; "8205"; "12"; "0"; "N/A"; "1"; "1"; "0"; "5"; "0";"16"
"6";"TILE_PLANK_BIRCH" ; "8205"; "12"; "0"; "N/A"; "1"; "1"; "0"; "6"; "0";"16"
"7";"TILE_PLANK_BLOODROSE" ; "8205"; "12"; "0"; "N/A"; "1"; "1"; "0"; "7"; "0";"16"
"8";"TILE_TRUNK_NORMAL" ; "8205"; "12"; "0"; "N/A"; "1"; "0"; "0"; "8"; "0";"16"
"9";"TILE_TRUNK_EBONY" ; "8205"; "12"; "0"; "N/A"; "1"; "0"; "0"; "9"; "0";"16"
"10";"TILE_TRUNK_BIRCH" ; "8205"; "12"; "0"; "N/A"; "1"; "0"; "0"; "10"; "0";"16"
"11";"TILE_TRUNK_BLOODROSE" ; "8205"; "12"; "0"; "N/A"; "1"; "0"; "0"; "11"; "0";"16"
"12";"TILE_STONE_QUARRIED" ; "8205"; "25"; "0"; "N/A"; "1"; "1"; "0"; "12"; "0";"16"
"13";"TILE_SAND" ; "8205"; "6"; "0"; "N/A"; "1"; "1"; "0"; "13"; "1";"16"
"14";"TILE_GRAVEL" ; "8205"; "6"; "0"; "N/A"; "1"; "0"; "0"; "14"; "1";"16"
"15";"TILE_ORE_MALACHITE" ; "5"; "25"; "0"; "N/A"; "1"; "0"; "0"; "15"; "0";"16"
"16";"TILE_ORE_HEMATITE" ; "5"; "25"; "0"; "N/A"; "1"; "0"; "0"; "16"; "0";"16"
"17";"TILE_ORE_NATURAL_GOLD" ; "5"; "25"; "0"; "N/A"; "1"; "0"; "0"; "17"; "0";"16"
"18";"TILE_ORE_NATURAL_SILVER" ; "5"; "25"; "0"; "N/A"; "1"; "0"; "0"; "18"; "0";"16"
"19";"TILE_ORE_RUTILE" ; "5"; "25"; "0"; "N/A"; "1"; "0"; "0"; "19"; "0";"16"
"20";"TILE_ORE_AURICHALCUMITE" ; "5"; "25"; "0"; "N/A"; "1"; "0"; "0"; "20"; "0";"16"
"21";"TILE_GEM_RUBY" ; "5"; "25"; "0"; "N/A"; "1"; "0"; "0"; "21"; "0";"16"
"22";"TILE_GEM_EMERALD" ; "5"; "25"; "0"; "N/A"; "1"; "0"; "0"; "22"; "0";"16"
"23";"TILE_GEM_SAPPHIRE" ; "5"; "25"; "0"; "N/A"; "1"; "0"; "0"; "23"; "0";"16"
"24";"TILE_GEM_TOPAZ" ; "5"; "25"; "0"; "N/A"; "1"; "0"; "0"; "24"; "0";"16"
"25";"TILE_GEM_DIAMOND" ; "5"; "25"; "0"; "N/A"; "1"; "0"; "0"; "25"; "0";"16"
"26";"TILE_GEM_AMETHYST" ; "5"; "25"; "0"; "N/A"; "1"; "0"; "0"; "26"; "0";"16"
"15";"TILE_ORE_MALACHITE" ; "8205"; "25"; "0"; "N/A"; "1"; "0"; "0"; "15"; "0";"16"
"16";"TILE_ORE_HEMATITE" ; "8205"; "25"; "0"; "N/A"; "1"; "0"; "0"; "16"; "0";"16"
"17";"TILE_ORE_NATURAL_GOLD" ; "8205"; "25"; "0"; "N/A"; "1"; "0"; "0"; "17"; "0";"16"
"18";"TILE_ORE_NATURAL_SILVER" ; "8205"; "25"; "0"; "N/A"; "1"; "0"; "0"; "18"; "0";"16"
"19";"TILE_ORE_RUTILE" ; "8205"; "25"; "0"; "N/A"; "1"; "0"; "0"; "19"; "0";"16"
"20";"TILE_ORE_AURICHALCUMITE" ; "8205"; "25"; "0"; "N/A"; "1"; "0"; "0"; "20"; "0";"16"
"21";"TILE_GEM_RUBY" ; "8205"; "25"; "0"; "N/A"; "1"; "0"; "0"; "21"; "0";"16"
"22";"TILE_GEM_EMERALD" ; "8205"; "25"; "0"; "N/A"; "1"; "0"; "0"; "22"; "0";"16"
"23";"TILE_GEM_SAPPHIRE" ; "8205"; "25"; "0"; "N/A"; "1"; "0"; "0"; "23"; "0";"16"
"24";"TILE_GEM_TOPAZ" ; "8205"; "25"; "0"; "N/A"; "1"; "0"; "0"; "24"; "0";"16"
"25";"TILE_GEM_DIAMOND" ; "8205"; "25"; "0"; "N/A"; "1"; "0"; "0"; "25"; "0";"16"
"26";"TILE_GEM_AMETHYST" ; "8205"; "25"; "0"; "N/A"; "1"; "0"; "0"; "26"; "0";"16"
"27";"TILE_SNOW" ; "5"; "6"; "0"; "N/A"; "1"; "1"; "0"; "27"; "0";"16"
"28";"TILE_ICE_FRAGILE" ; "2"; "1"; "0"; "N/A"; "1"; "0"; "0"; "28"; "0";"16"
"29";"TILE_ICE_NATURAL" ; "4"; "25"; "0"; "N/A"; "1"; "1"; "0"; "29"; "0"; "8"
"30";"TILE_ICE_CLEAR_MAGICAL" ; "5"; "25"; "0"; "N/A"; "1"; "1"; "4967"; "30"; "0"; "8"
"27";"TILE_SNOW" ; "8205"; "6"; "0"; "N/A"; "1"; "1"; "0"; "27"; "0";"16"
"28";"TILE_ICE_FRAGILE" ; "3282"; "1"; "0"; "N/A"; "1"; "0"; "0"; "28"; "0";"16"
"29";"TILE_ICE_NATURAL" ; "6564"; "25"; "0"; "N/A"; "1"; "1"; "0"; "29"; "0"; "8"
"30";"TILE_ICE_CLEAR_MAGICAL" ; "8205"; "25"; "0"; "N/A"; "1"; "1"; "4967"; "30"; "0"; "8"
# see scandinavian name set female of this tile id!
"31";"TILE_PLATFORM_STONE" ; "0"; "0"; "0"; "N/A"; "0"; "0"; "0"; "31"; "0";"16"
"32";"TILE_PLATFORM_WOODEN" ; "0"; "0"; "0"; "N/A"; "0"; "0"; "0"; "32"; "0";"16"
@@ -42,5 +42,5 @@
"36";"TILE_TORCH" ; "0"; "0"; "0"; "N/A"; "0"; "0";"63680"; "36"; "0";"16"
"239";"TILE_WATER" ; "2"; "100"; "1"; "2"; "0"; "0";"59159"; "239"; "0";"16"
"255";"TILE_LAVA" ; "0"; "100"; "1"; "2"; "0"; "0";"48320"; "239"; "0";"16"
"239";"TILE_WATER" ; "6522"; "100"; "1"; "2"; "0"; "0"; "0"; "239"; "0";"16"
"255";"TILE_LAVA" ; "62358"; "100"; "1"; "2"; "0"; "0";"48320"; "239"; "0";"16"
Can't render this file because it contains an unexpected character in line 1 and column 12.

View File

@@ -69,12 +69,7 @@ public class BasicDebugInfoWindow implements UICanvas {
printLine(g, 4, "veloY : " + String.valueOf(playerDbg.veloY()));
printLine(g, 5, "grounded : " + String.valueOf(playerDbg.grounded()));
printLine(g, 6, "noClip : " + String.valueOf(playerDbg.noClip()));
printLine(g, 7
, Lang.get("TERM_PHYS_MASS")
+ " : "
+ String.valueOf(playerDbg.mass())
+ " [kg]"
);
printLine(g, 7, "mass : " + String.valueOf(playerDbg.mass()) + " [kg]");
String lightVal;
try {