mirror of
https://github.com/MewoLab/AquaDX.git
synced 2026-02-11 23:17:28 +08:00
Revert "[ongeki] Fix play reception time lockout"
This reverts commit 535af15e6a.
This commit is contained in:
@@ -12,8 +12,6 @@ import org.slf4j.LoggerFactory;
|
|||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Component;
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
import java.time.LocalDateTime;
|
|
||||||
import java.time.format.DateTimeFormatter;
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -38,29 +36,17 @@ public class GetGameSettingHandler implements BaseHandler {
|
|||||||
@Override
|
@Override
|
||||||
public String handle(Map<String, Object> request) throws JsonProcessingException {
|
public String handle(Map<String, Object> request) throws JsonProcessingException {
|
||||||
|
|
||||||
/*
|
|
||||||
PropertyEntry start = propertyEntryRepository.findByPropertyKey("reboot_start_time")
|
PropertyEntry start = propertyEntryRepository.findByPropertyKey("reboot_start_time")
|
||||||
.orElseGet(() -> new PropertyEntry("reboot_start_time", "2020-01-01 23:59:00.0"));
|
.orElseGet(() -> new PropertyEntry("reboot_start_time", "2020-01-01 23:59:00.0"));
|
||||||
PropertyEntry end = propertyEntryRepository.findByPropertyKey("reboot_end_time")
|
PropertyEntry end = propertyEntryRepository.findByPropertyKey("reboot_end_time")
|
||||||
.orElseGet(() -> new PropertyEntry("reboot_end_time", "2020-01-01 23:59:00.0"));
|
.orElseGet(() -> new PropertyEntry("reboot_end_time", "2020-01-01 23:59:00.0"));
|
||||||
*/
|
|
||||||
|
|
||||||
/*
|
|
||||||
Ongeki is picky about reboot time value, and fixed one doesn't work very well.
|
|
||||||
So let's not use fixed value. Instead, give a dynamically adjusted time.
|
|
||||||
*/
|
|
||||||
|
|
||||||
LocalDateTime rebootTime = LocalDateTime.now().minusHours(2); // taken from some fork of minime.
|
|
||||||
|
|
||||||
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("uuuu-MM-dd HH:mm:ss");
|
|
||||||
String strRebootTime = rebootTime.format(formatter);
|
|
||||||
|
|
||||||
GameSetting gameSetting = new GameSetting(
|
GameSetting gameSetting = new GameSetting(
|
||||||
"1.05.00",
|
"1.05.00",
|
||||||
false,
|
false,
|
||||||
10,
|
10,
|
||||||
strRebootTime,
|
start.getPropertyValue(),
|
||||||
strRebootTime,
|
end.getPropertyValue(),
|
||||||
false,
|
false,
|
||||||
300,
|
300,
|
||||||
300,
|
300,
|
||||||
|
|||||||
Reference in New Issue
Block a user