mirror of
https://github.com/PikaMug/Quests.git
synced 2024-12-24 18:18:20 +01:00
Compare against milliseconds with literals for #574
This commit is contained in:
parent
bd1b5619c2
commit
ab265cab74
@ -3677,36 +3677,36 @@ public class Quests extends JavaPlugin implements ConversationAbandonedListener
|
||||
long minutes = ((milliseconds % 86400000) % 3600000) / 60000;
|
||||
long seconds = (((milliseconds % 86400000) % 3600000) % 60000) / 1000;
|
||||
long milliSeconds2 = (((milliseconds % 86400000) % 3600000) % 60000) % 1000;
|
||||
if (days > 0) {
|
||||
if (days == 1) {
|
||||
if (days > 0L) {
|
||||
if (days == 1L) {
|
||||
message += " 1 " + Lang.get("timeDay") + ",";
|
||||
} else {
|
||||
message += " " + days + " " + Lang.get("timeDays") + ",";
|
||||
}
|
||||
}
|
||||
if (hours > 0) {
|
||||
if (hours == 1) {
|
||||
if (hours > 0L) {
|
||||
if (hours == 1L) {
|
||||
message += " 1 " + Lang.get("timeHour") + ",";
|
||||
} else {
|
||||
message += " " + hours + " " + Lang.get("timeHours") + ",";
|
||||
}
|
||||
}
|
||||
if (minutes > 0) {
|
||||
if (minutes == 1) {
|
||||
if (minutes > 0L) {
|
||||
if (minutes == 1L) {
|
||||
message += " 1 " + Lang.get("timeMinute") + ",";
|
||||
} else {
|
||||
message += " " + minutes + " " + Lang.get("timeMinutes") + ",";
|
||||
}
|
||||
}
|
||||
if (seconds > 0) {
|
||||
if (seconds == 1) {
|
||||
if (seconds > 0L) {
|
||||
if (seconds == 1L) {
|
||||
message += " 1 " + Lang.get("timeSecond") + ",";
|
||||
} else {
|
||||
message += " " + seconds + " " + Lang.get("timeSeconds") + ",";
|
||||
}
|
||||
} else {
|
||||
if (milliSeconds2 > 0) {
|
||||
if (milliSeconds2 == 1) {
|
||||
if (milliSeconds2 > 0L) {
|
||||
if (milliSeconds2 == 1L) {
|
||||
message += " 1 " + Lang.get("timeMillisecond") + ",";
|
||||
} else {
|
||||
message += " " + milliSeconds2 + " " + Lang.get("timeMilliseconds") + ",";
|
||||
|
Loading…
Reference in New Issue
Block a user