Update 'RestoolsBBWatchReloaded.js'
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
// ==UserScript==
|
||||
// @name IITC plugin: ResTools BB Watch Reloaded
|
||||
// @namespace https://git.martinvylet.cz/vykend/ResTools-BB-Watch-Reloaded
|
||||
// @version 0.5
|
||||
// @version 0.5.1
|
||||
// @description Scan window for BBs on ornamented portals, then check results
|
||||
// @author vikend
|
||||
// @icon
|
||||
@@ -85,8 +85,8 @@ function wrapper(plugin_info)
|
||||
const timezoneOffsetHours = window.plugin.restoolsBBWatchReloaded.timezone; // Assuming the offset is stored in hours
|
||||
const offsetMilliseconds = timezoneOffsetHours * 60 * 60 * 1000; // Convert offset to milliseconds
|
||||
const currentTimeWithOffset = new Date(currentTime.getTime() + offsetMilliseconds);
|
||||
const currentTimeString = currentTimeWithOffset.toLocaleTimeString([], { hour: '2-digit', minute: '2-digit' });
|
||||
const currentTimePlus5Minutes = (new Date(currentTimeWithOffset.getTime() + 5 * 60000)).toLocaleTimeString([], { hour: '2-digit', minute: '2-digit' });
|
||||
const currentTimeString = currentTimeWithOffset.toLocaleTimeString([], { hour: '2-digit', minute: '2-digit', hour12: false });
|
||||
const currentTimePlus5Minutes = (new Date(currentTimeWithOffset.getTime() + 5 * 60000)).toLocaleTimeString([], { hour: '2-digit', minute: '2-digit', hour12: false });
|
||||
|
||||
let currentWave = 0;
|
||||
let battleOver = false;
|
||||
@@ -154,7 +154,7 @@ function wrapper(plugin_info)
|
||||
console.log("BBWatchReloaded: According to timetable anomaly haven't started yet, skipping");
|
||||
return;
|
||||
}
|
||||
if (waveNo > 7) {
|
||||
if (waveNo >= 7) {
|
||||
console.log("BBWatchReloaded: According to timetable anomaly already ended, skipping");
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user