deploy: 2688e86b9d
parent
8041a5434a
commit
4ef55dc831
File diff suppressed because one or more lines are too long
6
game.js
6
game.js
|
@ -5090,9 +5090,11 @@ function aAn() {
|
|||
t3 = Math.min(t3, aBC);
|
||||
8 === qc.aBD && (t3 -= t3 % 2);
|
||||
aBC = bk.t1.t2[e0].splice(0, t3), bk.t1.t3[e0] -= t3, t3 = function(aBE) {
|
||||
if (bk.aAl)
|
||||
if (bk.aAl) {
|
||||
if (__fx.customLobby.isActive()) return __fx.customLobby.getPlayerId();
|
||||
for (var eY = aBE.length, qu = bk.aAl.qu, a7 = 0; a7 < eY; a7++)
|
||||
if (aBE[a7].qu === qu) return a7;
|
||||
if (aBE[a7].qu === qu) return a7
|
||||
}
|
||||
return -1
|
||||
}(aBC);
|
||||
return -1 === t3 ? (bk.s.aAx += 29 === n.rw && bk.s.qb[0] === e0 && 1 === bk.s.qb[2], !1) : (8 === qc.aBD && (qc.aBH = (qc.aBH + (t3 >> 1)) % 1024, e0 = t3 - t3 % 2, t3 %= 2, aBC = aBC.slice(e0, 2 + e0)), ar.dU(qc, aBC, t3), !0)
|
||||
|
|
13
index.html
13
index.html
|
@ -35,7 +35,7 @@
|
|||
<meta itemprop="image" content="https://fxclient.github.io/FXclient/assets/logo.png">
|
||||
|
||||
<!-- FX Client CSS -->
|
||||
<link rel="stylesheet" href="main.css?1738839933879">
|
||||
<link rel="stylesheet" href="main.css?1739048704124">
|
||||
<!-- Game CSS -->
|
||||
<style>
|
||||
html,
|
||||
|
@ -83,9 +83,14 @@
|
|||
<h1>Donation history for </h1>
|
||||
<p id="donationhistory_note">Note: donations from bots are not shown here</p>
|
||||
<table><tbody id="donationhistory_content"></tbody></table>
|
||||
</div>
|
||||
<div class="window" style="display: none" id="updateNotification">
|
||||
<h3>A new version of FX is available! Reload to update</h3>
|
||||
<button onclick="window.location.reload()">Reload</button>
|
||||
<button onclick="document.getElementById('updateNotification').style.display = 'none'">Dismiss</button>
|
||||
</div></span>
|
||||
<script src="variables.js?1738839933879"></script>
|
||||
<script src="fx.bundle.js?1738839933879"></script>
|
||||
<script src="game.js?1738839933879"></script>
|
||||
<script src="variables.js?1739048704124"></script>
|
||||
<script src="fx.bundle.js?1739048704124"></script>
|
||||
<script src="game.js?1739048704124"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -0,0 +1,47 @@
|
|||
const cacheName = "1739048704124"; // this gets replaced by the build script
|
||||
|
||||
self.addEventListener("install", (e) => {
|
||||
console.log("[Service Worker] Install");
|
||||
self.skipWaiting();
|
||||
});
|
||||
|
||||
self.addEventListener("fetch", (e) => {
|
||||
const url = e.request.url;
|
||||
// Cache http and https only, skip unsupported chrome-extension:// and file://...
|
||||
if (!(url.startsWith('http:') || url.startsWith('https:'))) {
|
||||
return;
|
||||
}
|
||||
e.respondWith(
|
||||
(async () => {
|
||||
const r = await caches.match(e.request);
|
||||
console.log(`[Service Worker] Fetching resource: ${url}`);
|
||||
if (r) {
|
||||
return r;
|
||||
}
|
||||
const response = await fetch(e.request);
|
||||
const cache = await caches.open(cacheName);
|
||||
console.log(`[Service Worker] Caching new resource: ${url}`);
|
||||
cache.put(e.request, response.clone());
|
||||
return response;
|
||||
})(),
|
||||
);
|
||||
});
|
||||
|
||||
self.addEventListener("activate", (e) => {
|
||||
console.log("[Service Worker] Activated", cacheName);
|
||||
self.clients.matchAll().then(clients => {
|
||||
clients.forEach(client => client.postMessage({ event: "activate", version: cacheName }));
|
||||
});
|
||||
e.waitUntil(
|
||||
caches.keys().then((keyList) => {
|
||||
return Promise.all(
|
||||
keyList.map((key) => {
|
||||
if (key === cacheName) {
|
||||
return;
|
||||
}
|
||||
return caches.delete(key);
|
||||
}),
|
||||
);
|
||||
}),
|
||||
);
|
||||
});
|
Loading…
Reference in New Issue