mirror of
https://github.com/DRE2N/DungeonsXL.git
synced 2024-09-16 01:57:14 +02:00
Fix title signs
This commit is contained in:
parent
51cccb3afb
commit
02c159e3df
@ -50,16 +50,18 @@ public class TitleSign extends MessageSign {
|
||||
|
||||
@Override
|
||||
public void initialize() {
|
||||
super.initialize();
|
||||
|
||||
String[] line1 = text.split(",");
|
||||
String[] line1 = getLine(1).split(",");
|
||||
Map<Integer, String> messages = getGameWorld().getDungeon().getRules().getState(GameRule.MESSAGES);
|
||||
int id0 = NumberUtil.parseInt(line1[0], -1);
|
||||
title = id0 != -1 ? messages.get(id0) : "";
|
||||
title = messages.get(id0);
|
||||
if (title == null) {
|
||||
title = "";
|
||||
}
|
||||
if (line1.length > 1) {
|
||||
int id1 = NumberUtil.parseInt(line1[1], -1);
|
||||
subtitle = id1 != -1 ? messages.get(id1) : "";
|
||||
} else {
|
||||
subtitle = messages.get(id1);
|
||||
}
|
||||
if (subtitle == null) {
|
||||
subtitle = "";
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user