Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
319 commits
Select commit Hold shift + click to select a range
c1401ab
WEVENTS: make the events area scrollable instead of scrolling the page
mascaldotfr Aug 19, 2025
e94e675
MENU: use html() instead of append()
mascaldotfr Aug 19, 2025
338311e
WEVENTS: the previous change didn't go well on small screens
mascaldotfr Aug 19, 2025
75b7b65
BZ: remove useless occurrences of empty()
mascaldotfr Aug 20, 2025
3047215
tz picker: cache the generated html in localstorage
mascaldotfr Aug 20, 2025
9a028b1
MENU: don't call api_url where it's not needed
mascaldotfr Aug 20, 2025
c503a33
BZ/BOSSES: remove calendar artefact ...
mascaldotfr Aug 20, 2025
8c378d6
WSTATS: remove useless use of empty() + append() with html()
mascaldotfr Aug 20, 2025
9279ff1
wztools/events: remove some constants in a loop
mascaldotfr Aug 20, 2025
3869b70
humanize_events: bad use of <b> + duplicate code removed
mascaldotfr Aug 21, 2025
91b89e7
BZ: fix some bad use of <b>
mascaldotfr Aug 21, 2025
663844b
BZ/BOSSES: don't use pixels wherever it's possible
mascaldotfr Aug 21, 2025
1ea878a
WZ: use scaling instead of transform
mascaldotfr Aug 21, 2025
fd3a3c8
TRAINER : put spaces for points around '/'s
mascaldotfr Aug 21, 2025
f9cf17e
BZ: some nitpicking style wise
mascaldotfr Aug 21, 2025
3f1dcc1
BOSSES: update all respawn times
mascaldotfr Aug 22, 2025
491b0cf
Fix addtocalendar button width
mascaldotfr Aug 26, 2025
2d72893
Update gitignore
mascaldotfr Aug 29, 2025
f14719e
BOSSES: update <noscript>
mascaldotfr Aug 29, 2025
0f22594
WSTATS: fix duplicate anchors
mascaldotfr Aug 29, 2025
b501aaf
BOSSES: update Daen respawn and adjust TK
mascaldotfr Sep 1, 2025
053ab90
GLOBAL: fuse all wztools modules as a single one
mascaldotfr Sep 2, 2025
da1f19c
GLOBAL: fuse i18n and its db
mascaldotfr Sep 2, 2025
3c1242c
GLOBAL: don't load cursors on mobile
mascaldotfr Sep 2, 2025
7f82cb1
GLOBAL: lazy load cursors
mascaldotfr Sep 2, 2025
9e45925
GLOBAL: merge onlinemanager.js in api_url.js
mascaldotfr Sep 3, 2025
e95b811
TRAINER: load lzstring.js on demand
mascaldotfr Sep 3, 2025
f342e8c
GLOBAL: fuse all CoRT js libs into a single file
mascaldotfr Sep 3, 2025
d96186e
GLOBAL: ensure the scrollbar is computer in any page
mascaldotfr Sep 3, 2025
bc1dcfd
GLOBAL: don't load add to calendar everywhere!
mascaldotfr Sep 3, 2025
bcdb28b
WEVENTS: when no filter is set, add events 100 by 100
mascaldotfr Sep 6, 2025
2a8db63
WZ/WEVENTS: optimize events display
mascaldotfr Sep 6, 2025
a2cf6d1
WEVENTS: mostly revert bcdb28b3
mascaldotfr Sep 6, 2025
48f7681
GLOBAL: sprinkle Intl.DateTimeFormat where it counts
mascaldotfr Sep 6, 2025
a85e941
WZ: refactor map drawing
mascaldotfr Sep 6, 2025
da01814
lamaiquery: add addClass and removeClass
mascaldotfr Sep 7, 2025
db179d8
TRAINER: use CSS classes to determine icon visibility ...
mascaldotfr Sep 7, 2025
302e70f
TRAINER: compute max discipline levels less naively
mascaldotfr Sep 7, 2025
379486f
TRAINER: try to reduce selector and array lookup time
mascaldotfr Sep 7, 2025
5277d34
TRAINER: use arrays instead of big string concats
mascaldotfr Sep 7, 2025
e0031c4
MENU: add link to backup site
mascaldotfr Sep 7, 2025
f9f499e
WZ: don't refresh the display and show notifications for nothing
mascaldotfr Sep 7, 2025
8e02773
README: some changes
mascaldotfr Sep 8, 2025
d1202a8
WZTOOLS: best effort to make some unsupported browsers work
mascaldotfr Sep 8, 2025
614cf0e
WSTATS: string concatenation optimization
mascaldotfr Sep 10, 2025
bb232d5
GLOBAL: remove debug links for external libs
mascaldotfr Sep 10, 2025
09a2b87
UPDATING.md: add infos about how to update bosses respawns
mascaldotfr Sep 10, 2025
0860f03
BOSSES: update daen's respawn
mascaldotfr Sep 10, 2025
3b3d37c
cortlibs: fix lamaiquery's attr
mascaldotfr Sep 12, 2025
3010e1d
TRAINER: stop using text(), use attr() instead
mascaldotfr Sep 12, 2025
3e0d5ad
TRAINER: missed a parseInt()
mascaldotfr Sep 12, 2025
0785e42
TSTATS: "modernise" the code
mascaldotfr Sep 13, 2025
0355375
TSTATS: CLS fix
mascaldotfr Sep 13, 2025
155a75f
TSTATS: remove 1.33.2 and 1.33.3
mascaldotfr Sep 13, 2025
8210caa
TSTATS: add a link to Halv's trainer stats
mascaldotfr Sep 13, 2025
86d114c
TSTATS: make the chart more centered, force font size
mascaldotfr Sep 13, 2025
55ab3cb
TSTATS: it's now the default trainer stats page
mascaldotfr Sep 13, 2025
fed2601
GLOBAL: give more sense to meta name="description" across the site
mascaldotfr Sep 13, 2025
39af401
lamaiquery: finally use a single selector resolving code
mascaldotfr Sep 13, 2025
d5c1ebd
WSTATUS: draw directly on a canvas instead of using a <img> tag
mascaldotfr Sep 13, 2025
6031e50
BOSSES: update Eve and Server
mascaldotfr Sep 14, 2025
a82c451
README: remove extra tstats stuff
mascaldotfr Sep 14, 2025
ed16e2c
api_url: [jshint] fix an issue in onlinemanager
mascaldotfr Sep 14, 2025
f9d6ac8
bosses.js: [jshint] missing semicolons
mascaldotfr Sep 14, 2025
4356944
bz.js: [jshint] missing semicolons
mascaldotfr Sep 14, 2025
abcc877
menu.js: [jshint] missing semicolon + warning ignore
mascaldotfr Sep 14, 2025
c59192f
trainer.js: [jshint] missing semicolons + warnings fixes
mascaldotfr Sep 14, 2025
507b73f
tstats.js: [jshint] missing semicolons
mascaldotfr Sep 14, 2025
1198c71
wstats.js: [jshint] missing semicolons + warning fixes
mascaldotfr Sep 14, 2025
db0cf0a
wz.js: [jshint] missing semicolons + warning fixes
mascaldotfr Sep 14, 2025
10c50de
wztools.js: [jshint] missing semicolons + warning fixes
mascaldotfr Sep 14, 2025
2adbfb2
cortlibs.js: [jshint] missing semicolons
mascaldotfr Sep 14, 2025
61f2771
CONTRIBUTING: don't push too hard on jshint
mascaldotfr Sep 14, 2025
8dae53f
retrigger github pages build
mascaldotfr Sep 14, 2025
4713b15
BZ/BOSSES: fix a race condition if visited for the frist time
mascaldotfr Sep 14, 2025
b6730db
collect: update README.md
mascaldotfr Sep 14, 2025
6e3830e
stats' README: update a few things
mascaldotfr Sep 14, 2025
72a8f01
TRAINER: Big refactoring
mascaldotfr Sep 17, 2025
7b326c7
WSTATS: fixed yet another race condition
mascaldotfr Sep 17, 2025
17c126d
TRAINER: fix bad_shared_link()
mascaldotfr Sep 18, 2025
76e7c4e
lamaiquery: add prependTo()
mascaldotfr Sep 18, 2025
63f12f5
TRAINER: replace <dialog> by a fake modal
mascaldotfr Sep 18, 2025
919a767
BOSSES: move from png to webp
mascaldotfr Sep 19, 2025
4217688
TRAINER: Refactor skill visibility code
mascaldotfr Sep 19, 2025
a88fc36
TRAINER: move all icons to webp
mascaldotfr Sep 19, 2025
389cc4d
GLOBAL: convert cursors to webp
mascaldotfr Sep 19, 2025
4e53b89
TRAINER: yet another load of performance improvements
mascaldotfr Sep 20, 2025
8ebbba6
GLOBAL: update addtocalendar to 2.11.5
mascaldotfr Sep 20, 2025
e15ec11
Fix previous (missed removal of sourcemap)
mascaldotfr Sep 20, 2025
466e2be
TRAINER: remove a wrongly scoped is_beta ...
mascaldotfr Sep 20, 2025
5a76921
TRAINER: replace some string concats with some array push/join
mascaldotfr Sep 20, 2025
173a88b
TRAINER: fix some minor mistakes
mascaldotfr Sep 20, 2025
e65c698
i18n: fix some errors
mascaldotfr Sep 21, 2025
4573d8b
TRAINER: CLS fix for info zone.
mascaldotfr Sep 23, 2025
732fb6f
WZ: responsive CSS refactoring.
mascaldotfr Sep 23, 2025
4bc72ea
Fix previous: bad URL for the map background
mascaldotfr Sep 23, 2025
154b8cf
TSTATS: simplify the layout and reduce CLS
mascaldotfr Sep 24, 2025
f820613
TSTATS: use an API for way better performance
mascaldotfr Sep 25, 2025
3873536
WEVENTS: move the dump generator around and make it more configurable
mascaldotfr Sep 25, 2025
c7ffb4f
WARSTATUS: fix second run
mascaldotfr Sep 25, 2025
e22df08
DOCS: add a deploy part
mascaldotfr Sep 25, 2025
c7ab1bb
DEPLOY: naivety fixes for the Caddyfile
mascaldotfr Sep 27, 2025
9a4adec
GLOBAL: activate maintenance mode
mascaldotfr Sep 27, 2025
979582a
GLOBAL: put definitive API urls
mascaldotfr Sep 27, 2025
067e3e6
GLOBAL: maintenance message didn't appear in mobile
mascaldotfr Sep 27, 2025
c2f4032
DEPLOY: add git workflow for modified CoRTs
mascaldotfr Sep 27, 2025
752217d
GLOBAL: remove maintenance message
mascaldotfr Sep 27, 2025
ca637e5
DEPLOY: add '--no-edit' while merging
mascaldotfr Sep 27, 2025
503aeb5
GLOBAL: reduce backend gzip compression
mascaldotfr Sep 29, 2025
578b323
BOSSES: update TK's respawn time
mascaldotfr Oct 1, 2025
adedf64
GLOBAL: create /api and put all API related stuff in it.
mascaldotfr Oct 3, 2025
218645f
WARSTATUS, TRAINER: set up new files
mascaldotfr Oct 3, 2025
d7c9d9c
TRAINER: fix collector URL
mascaldotfr Oct 3, 2025
374c819
WARSTATUS: mention that you need to wait for a WZ event
mascaldotfr Oct 3, 2025
4107315
DEPLOY: update URLs and small fixes to the docs
mascaldotfr Oct 3, 2025
c98b87d
TSTATS: fix stats generation
mascaldotfr Oct 4, 2025
b42e498
BZ/BOSSES: use an API
mascaldotfr Oct 4, 2025
f3240b6
BZ: CLS and QA fixes
mascaldotfr Oct 4, 2025
11a4d02
BOSSES: forgot to change API url in <noscript>
mascaldotfr Oct 4, 2025
c6e9c98
API: fix bad enpoint URL in README.
mascaldotfr Oct 4, 2025
92989a2
little fixes to various READMEs
mascaldotfr Oct 5, 2025
2561ac6
further README fixes and improvements
mascaldotfr Oct 5, 2025
ec41b91
Dump generator: fix data locations
mascaldotfr Oct 6, 2025
cf76b56
TSTATS: improve backend performance
mascaldotfr Oct 6, 2025
6869b53
TSTATS: move the trainerstat generator to PHP
mascaldotfr Oct 11, 2025
29e70f8
GLOBAL: stop using 'cd' in crontab calls
mascaldotfr Oct 11, 2025
1e87356
WEVENTS: create a PHP based dump_generator
mascaldotfr Oct 11, 2025
0d15bca
BOSSES: update Eve's respawn time
mascaldotfr Oct 11, 2025
6ce5ae8
TSTATS: directly call the PHP code
mascaldotfr Oct 11, 2025
da87a22
fix previous (CORS issue)
mascaldotfr Oct 11, 2025
9ead4cf
deploy: update dockerfile and fix first run
mascaldotfr Oct 11, 2025
933199c
TSTATS: stop reloading when there is no available setup.
mascaldotfr Oct 11, 2025
a704965
deploy: update the dockerfile
mascaldotfr Oct 11, 2025
8d1007d
DOCS: centralize deployment in README.md
mascaldotfr Oct 11, 2025
3e0ac05
WSTATS: don't link directly to the CSV.
mascaldotfr Oct 11, 2025
4ddd050
deploy: minor changes
mascaldotfr Oct 11, 2025
bf98c0b
TRAINER: externalize CoRT-icons
mascaldotfr Oct 12, 2025
3668d6f
deploy: advise against automatic merging
mascaldotfr Oct 12, 2025
7d7f006
deploy: small comment corrections in Dockerfile
mascaldotfr Oct 12, 2025
02edcc1
GLOBAL: add adaptative API URLs
mascaldotfr Oct 12, 2025
02dd433
BOSSES: update daen's and server respawn time
mascaldotfr Oct 12, 2025
d59131d
WZ/WSTATS/WEVENTS: move from python to php
mascaldotfr Oct 15, 2025
be51fd8
WSTATS: ensure proper return value for wishes on empty DB
mascaldotfr Oct 15, 2025
6232027
deploy: add missing packages
mascaldotfr Oct 15, 2025
97a14e4
WSTATS: follow-up for be51fd8cc3cc7
mascaldotfr Oct 15, 2025
825e12d
WARSTATUS: ensure there are no DW straight from the 1st run
mascaldotfr Oct 15, 2025
e77837b
deploy: more infos on website population after install
mascaldotfr Oct 15, 2025
5a7d298
deploy/Dockerfile: fix events dumps generation
mascaldotfr Oct 15, 2025
4477e9b
Configure Dependabot for Composer packages
mascaldotfr Oct 15, 2025
e6bcd5c
API: remove onlinemanager
mascaldotfr Oct 15, 2025
4f124de
APIs: let localhost run the official API
mascaldotfr Oct 15, 2025
0d49876
APIs: drop frontsite_dir
mascaldotfr Oct 15, 2025
457922c
deploy: mention troublesome stuff for people hosting the site without…
mascaldotfr Oct 15, 2025
29ae1de
Fix regression from 0d49876
mascaldotfr Oct 15, 2025
f8bbe45
GLOBAL: add a workflow for creating releases on tag push
mascaldotfr Oct 16, 2025
9f7bbb1
deploy: brand new docs
mascaldotfr Oct 16, 2025
ace2919
deploy/noapi: put a \ where i should not
mascaldotfr Oct 16, 2025
d7481cf
GLOBAL: add fixed version to managed tarballs and fix wording
mascaldotfr Oct 16, 2025
84b3a01
deploy: copy pasta failure
mascaldotfr Oct 16, 2025
e47e618
deploy: add an integration guide in an already existing server
mascaldotfr Oct 16, 2025
311601d
fix for previous
mascaldotfr Oct 16, 2025
c8ebde6
deploy: various little README fixes
mascaldotfr Oct 16, 2025
6e30d61
GLOBAL: hide github links out of mascaldotfr.github.io
mascaldotfr Oct 17, 2025
d5c7e5e
CONTRIBUTING: remove python mention
mascaldotfr Oct 17, 2025
875f30f
deploy: fix for managed update
mascaldotfr Oct 17, 2025
493b7bf
WARSTATUS: notify the last 9 events in case there are more
mascaldotfr Oct 17, 2025
f3b0cd0
GLOBAL: generate website from the latest release
mascaldotfr Oct 17, 2025
cb538a6
GLOBAL: improve the release GH Action
mascaldotfr Oct 18, 2025
7e0b6e9
deploy: CoRT can run on Windows
mascaldotfr Oct 18, 2025
4228f0b
APIs: Mention 127.0.0.1 trick to use your own API data
mascaldotfr Oct 18, 2025
485f456
deploy/integrated: mention clearly that only php deps matter.
mascaldotfr Oct 18, 2025
4f1f3f9
deploy: mention Discord server to get new releases
mascaldotfr Oct 18, 2025
44c9ae2
Release 1.35.19-2.0
mascaldotfr Oct 18, 2025
6a0b4a1
Release 1.35.19-2.0
mascaldotfr Oct 18, 2025
72d0753
api/bosses: make respawn schedule generation reusable
mascaldotfr Oct 20, 2025
88836cc
api/bz: make schedule generation reusable
mascaldotfr Oct 20, 2025
355f769
deploy/noapi: fix clumsy wording for API access
mascaldotfr Oct 20, 2025
3bdc8d8
API: add "sentinel" endpoint
mascaldotfr Oct 22, 2025
61863dd
api: use readfile() instead of redirections
mascaldotfr Oct 24, 2025
7408d3c
API: centralize headers
mascaldotfr Oct 25, 2025
84ddab1
fix previous
mascaldotfr Oct 25, 2025
a7a5f71
GLOBAL: remove ping code
mascaldotfr Oct 25, 2025
d7b047d
GLOBAL: add an API endpoint for maintenance
mascaldotfr Oct 25, 2025
8a957ed
gitignore cleanup
mascaldotfr Oct 26, 2025
e0f1ee6
api/var: add maintenance to README
mascaldotfr Oct 26, 2025
fd661a5
deploy: docker changes, and some rewording here and there
mascaldotfr Oct 26, 2025
dd8cc7a
deploy: share the script used for automagic managed tarball creation
mascaldotfr Oct 26, 2025
9e2d983
WZ: reduce server calls
mascaldotfr Oct 28, 2025
3538ac2
WZ: reduce server calls (take 2)
mascaldotfr Oct 28, 2025
9751da2
WZ: make the scheduler more generic
mascaldotfr Oct 29, 2025
18beeee
BOSSES: update eve's respawn time
mascaldotfr Oct 29, 2025
3cfc304
WZ: reduce server calls (take 3)
mascaldotfr Oct 29, 2025
d5fd089
ticker: add a guard against 0 or negative delay
mascaldotfr Oct 30, 2025
9c66311
BOSSES: update daen and server time
mascaldotfr Oct 30, 2025
4100fc4
ticker.js: prevent hypothetical timer stacking
mascaldotfr Oct 30, 2025
8a5b670
WZ: add a 5s debounce on focus event
mascaldotfr Oct 30, 2025
d7d25e8
WZ: Add comment so people understand why it's between :10 and :15
mascaldotfr Oct 30, 2025
3ccb4f1
GLOBAL: call maintenance API only every 5 minutes
mascaldotfr Oct 31, 2025
3d3fb9e
api/bosses: add a way to get minutely respawns
mascaldotfr Oct 31, 2025
5fff76a
BOSSES: ensure countdowns are right on mobile
mascaldotfr Oct 31, 2025
630932f
WZ: small code nitpick
mascaldotfr Oct 31, 2025
b2be14d
api/bosses: for fake respawn, put the epoch at one hour ago
mascaldotfr Oct 31, 2025
d18f3ab
collect: stop rewriting all saved setups everytime
mascaldotfr Oct 31, 2025
e81b149
WSTATS: reduce API calls
mascaldotfr Oct 31, 2025
6aaba1e
WSTATS/BOSSES: ensure a refresh will occur if the page become visible
mascaldotfr Oct 31, 2025
30691c5
api/tstats: round as a number, not as a string!
mascaldotfr Nov 1, 2025
440e146
BOSSES/BZ/WSTATS/WZ: ensure a unique run after sleep
mascaldotfr Nov 1, 2025
c6a6888
api/bosses: improve fake mode
mascaldotfr Nov 2, 2025
bb02127
api/bz: add a fake mode for development and testing
mascaldotfr Nov 2, 2025
18979d4
WZ/BZ/BOSSES: drop setInterval on main thread
mascaldotfr Nov 2, 2025
37286c8
BOSSES: announce update are minutely
mascaldotfr Nov 2, 2025
afda4bf
BZ: reduce min-height and center dialogs
mascaldotfr Nov 2, 2025
bcaf865
BOSSES: update TK's respawn time
mascaldotfr Nov 2, 2025
623b96c
wztools: allow minute flooring in Time.timestamp_ago()
mascaldotfr Nov 2, 2025
8701993
GH release actions: change release draft status to true
mascaldotfr Nov 2, 2025
4dd9f31
deploy: add a script automating the noapi method
mascaldotfr Nov 2, 2025
8d996c1
deploy/noapi: fix link formatting for noapi_auto script
mascaldotfr Nov 2, 2025
8a97d42
BOSSES: improve responsive display of bosses icons
Nov 3, 2025
cabda7e
BOSSES: avoid spam notifications on refocus just before respawn
Nov 3, 2025
e6b4804
GLOBAL: timezone picker responsive fix
Nov 3, 2025
329d4db
TSTATS: fix bad index height on small devices (512-800px)
mascaldotfr Nov 3, 2025
978ecd8
deploy: sprinkle jq magic in READMEs
mascaldotfr Nov 3, 2025
573966d
MENU: add a external tools section
mascaldotfr Nov 4, 2025
74ab0fa
MENU: Further improvements
mascaldotfr Nov 4, 2025
ddd1472
MENU: put all languages inline on mobile
mascaldotfr Nov 5, 2025
450843a
MENU: align submenus to the left, add Sentinel link
mascaldotfr Nov 5, 2025
71c25cb
i18n: fix 2 german translations
Joshua2504 Nov 5, 2025
2259144
release.yml: add partial cache busting
mascaldotfr Nov 5, 2025
9618332
ghpage.yml: same as previous
mascaldotfr Nov 5, 2025
ec1263a
GH actions: remove useless newline when generating cache busting para…
mascaldotfr Nov 6, 2025
f01ddf8
deploy/noapi: remove API and PHP deps in examples
mascaldotfr Nov 6, 2025
238c91f
GLOBAL: use "&nbsp;" instead of English text
mascaldotfr Nov 6, 2025
e3cf023
add2calendar: hide branding and put friendly ICS filenames
mascaldotfr Nov 6, 2025
cff51a6
add2calendar: move dynamic import where it's used
mascaldotfr Nov 6, 2025
16285cd
GLOBAL: sprinkle rel="modulepreload" on key JS modules
mascaldotfr Nov 6, 2025
5693084
TRAINER: removing a forgotten hardcoded title
mascaldotfr Nov 6, 2025
469cc5b
GLOBAL: avoid self closing tags for preloaded js
mascaldotfr Nov 7, 2025
ccdb670
TSTATS: yet another hardcoded title removed
mascaldotfr Nov 7, 2025
c5fd89d
BOSSES: update eve's respawn time
mascaldotfr Nov 7, 2025
c881409
GLOBAL: generate less html tags from javascript
mascaldotfr Nov 8, 2025
1080113
WZ: preload the base map
mascaldotfr Nov 8, 2025
8f4b1b7
i18n/{fr,es}: use shorter titles
mascaldotfr Nov 8, 2025
9aa8bd7
BOSSES: update daen's respawn time
mascaldotfr Nov 8, 2025
3f41d5d
MENU: move misplaced flex element, grow button to take all the space
mascaldotfr Nov 9, 2025
ada1cab
WZ: give a winning chance to 1366 and 1024 px width screens
mascaldotfr Nov 9, 2025
c5bf435
WZ: fix display at 1549px width
mascaldotfr Nov 9, 2025
908cd1c
WZ: make realm infos grow on very small screens
mascaldotfr Nov 9, 2025
269c406
api/bosses: make respawns time auto drift
mascaldotfr Nov 9, 2025
551c126
BOSSES: update tk's and server's respawns
mascaldotfr Nov 11, 2025
4420e06
BOSSES: tk gets 2 seconds adjustment
mascaldotfr Nov 11, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
11 changes: 11 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# To get started with Dependabot version updates, you'll need to specify which
# package ecosystems to update and where the package manifests are located.
# Please see the documentation for all configuration options:
# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file

version: 2
updates:
- package-ecosystem: "composer"
directory: "/" # Location of package manifests
schedule:
interval: "weekly"
41 changes: 41 additions & 0 deletions .github/workflows/ghpage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Deploy to GitHub Pages from latest tag

on:
push:
tags:
- '*'

permissions:
contents: read
pages: write
id-token: write

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout tagged commit
uses: actions/checkout@v4
with:
ref: ${{ github.ref }}

- name: Fix version and cache bust
run: |
sed -i -E 's/(<!--VERSION-->Version: ).+/\1'"${{ github.ref_name }}"'/' js/menu.js
# Cache bust top js and css
VERSION="${{ github.ref_name }}"
ESCAPED_VERSION=$(printf '%s' "$VERSION" | sha1sum | cut -c1-8)

find . -name '*.html' -print0 | xargs -0 sed -E -i'' 's/\.(css|js)(\?[^"]*)?">/.\1?'$ESCAPED_VERSION'">/g'
find . -name '*.js' -print0 | xargs -0 sed -E -i'' '/^[[:space:]]*import.*\.js"/s/(\.js)(\?[^"]*)?"/\.js?'$ESCAPED_VERSION'"/g'

- name: Setup Pages
uses: actions/configure-pages@v5

- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: '.'

- name: Deploy to GitHub Pages
uses: actions/deploy-pages@v4
59 changes: 59 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
name: Create Release

on:
push:
tags:
- '*'

permissions:
contents: write

jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Clean up files with sed
run: |
# Remove all preload statements
sed -i '/<link rel="preload"/d' *.html

# Cache bust top js and css
VERSION="${{ github.ref_name }}"
ESCAPED_VERSION=$(printf '%s' "$VERSION" | sha1sum | cut -c1-8)
find . -name '*.html' -print0 | xargs -0 sed -E -i'' 's/\.(css|js)(\?[^"]*)?">/.\1?'$ESCAPED_VERSION'">/g'
find . -name '*.js' -print0 | xargs -0 sed -E -i'' '/^[[:space:]]*import.*\.js"/s/(\.js)(\?[^"]*)?"/\.js?'$ESCAPED_VERSION'"/g'

# Put a fixed version
sed -i -E 's/(<!--VERSION-->Version: ).+/\1'"${{ github.ref_name }}"'/' js/menu.js

- name: Create custom tarball
run: |
sudo apt install composer &&
composer install &&
tar -czf ${{ runner.temp }}/CoRT-${{ github.ref_name }}.tar.gz \
--transform "s,^,CoRT-${{ github.ref_name }}/," \
*

- name: Create Release
uses: softprops/action-gh-release@v1
with:
name: ${{ github.ref_name }}
body: |
### About

This is an automated release.

See https://github.com/mascaldotfr/CoRT/tree/main/deploy/README.md to deploy it

To setup CoRT on managed webhosting or integrating it on your own server, use **CoRT-${{ github.ref_name }}.tar.gz** instead of the source code.

### Changelog
draft: true
prerelease: false
generate_release_notes: true
files: ${{ runner.temp }}/CoRT-${{ github.ref_name }}.tar.gz
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
16 changes: 7 additions & 9 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
collect/data.*
ping.js
warstatus/*.json
warstatus/*.json.gz
warstatus/stats/*.json
warstatus/stats/*.json.gz
warstatus/stats/*.sqlite
__pycache__**
# dynamic API data
api/var/*
!api/var/README.md

# Composer modules
vendor

# for macOS users
.DS_Store
.DS_Store
13 changes: 4 additions & 9 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,14 @@ If you plan to bring code improvements:
maintaining.
2. Keep the style consistent, even if sometimes it's gross like not using dot
notation for hashes.
3. The javascript used in CoRT must follow ECMAScript <= 8, please use
[JSHint](https://jshint.com/) to check this out, or mention
you didn't. Linux usage:
3. Optionally use [JSHint](https://jshint.com/). Linux usage:
```shell
cd /tmp
npm install jshint
cd node_modules/jshint
echo '{ "esversion" : 8 }' > jshintrc
./jshint -c jshintrc /where/is/CoRT/js/*.js | grep esversion
# Should return nothing out of chartist.js which is not considered essential
echo '{ "esversion": 11, "sub": true }' > jshintrc
./bin/jshint -c jshintrc /where/is/CoRT/js/*.js
```
4. If you touch the python code, try to not adding extra modules as a dependency.

### Why using Firefox 78 as a baseline

Expand All @@ -41,7 +37,6 @@ in a virtual machine to test.
Note that this requirement will change over time, for example if TLS technology
changes and makes this version unable to connect to https sites.


### Commit hook for versioning in the footer

This is mostly a note to myself.
Expand All @@ -59,5 +54,5 @@ git add "${GIT_WORK_TREE}/js/menu.js"
echo "Updated last commit date"
```

Don't forget to make it executable. This will update the versoin for each
Don't forget to make it executable. This will update the version for each
commit, including non user facing changes.
29 changes: 14 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@

> [!IMPORTANT]
> **CoRT is in maintenance mode: no new features will be added, only minor fixes or data updates. The site will stay up though.**

# Champions of Regnum trainer (and more)

Since the famous regnumsentinel trainer is dead, all is left are operating
Expand All @@ -9,12 +13,13 @@ This is a (simpler) knockoff of the regnumsentinel website trainer, this one
will be alive as long as GitHub exists and is open source software. On top of
that, there are countdown pages for bosses and BZ, WZ status and statistics.

The website just requires a webserver serving static files to run, everything
is run client side, with the exception of the WZ status and statistics (see the
`warstatus` directory) that can partly be replaced by a link to NGE's official
page, and anonymous setup collection (see the `collect` directory) which by
default only works for https://mascaldotfr.github.io and can be completely
skipped.
The trainer just requires a webserver serving static files to run, everything
is run client side. All the rest depends on an API server though.

Deploying CoRT (with or without the API) is explained [there](deploy/README.md)

There is also a [wiki](https://github.com/mascaldotfr/CoRT/wiki) containing
extra infos about using and deploying CoRT.

## Known issues

Expand All @@ -26,16 +31,8 @@ skipped.
to have a database server, since it then would require a separate server and
a domain for such a feature, that could go down like regnumsentinel.

## Setting a local webserver

If you want to make changes to CoRT or run it locally, you can use python to
[create a temporary local webserver](https://developer.mozilla.org/en-US/docs/Learn/Common_questions/Tools_and_setup/set_up_a_local_testing_server#using_python).

## Hidden pages

* **[tstats.html](https://mascaldotfr.github.io/CoRT/tstats.html)** is CoRT's own
Trainer statistics page. For more infos on why it's not the default, see
[the collect README](collect/README.md#Javascript).
* **[beta.html](https://mascaldotfr.github.io/CoRT/beta.html)** is a part of the
[upgrade cycle process](UPDATING.md).
* **[tests.html](https://mascaldotfr.github.io/CoRT/tests.html)** includes
Expand Down Expand Up @@ -70,6 +67,8 @@ If you want to make changes to CoRT or run it locally, you can use python to
[Anpu](https://github.com/Anpu) did a thing or two about it as well iirc.
* [Joshua2504](https://github.com/Joshua2504) and
[Shaiko](https://github.com/Shaiko35) from https://cor-forum.de/ for keeping
the spell database updated
the spell database updated before I took over
* Slartibartfast, the regnumsentinel.com creator, site that gave me big hints about
the UI should be done.
* Halvdan. His own trainer stats page has been a major influence on
[tstats.html](https://mascaldotfr.github.io/CoRT/tstats.html)
43 changes: 36 additions & 7 deletions UPDATING.md
Original file line number Diff line number Diff line change
@@ -1,48 +1,77 @@
# TRAINER UPDATE PROCESS
# UPDATE PROCESS


## TRAINER

Upgrade cycle when balance changes are released by NGE. Note that doing the
change will require you to know how to operate a webserver to test, and doing
some minor changes in the source code. While not complicated, you still need to
know these basics.

## Doing a balance update
### Doing a balance update

There are shorter ways to do so, but this way you can update a new trainer
dataset beta after beta, until the final release, making 0-day releases of the
live version without spending a lot of time on the said release day.

### Create a new version
#### Create a new version

As soon as the first beta/rc is released, remove the `data/beta` directory and
copy the newest version folder to `data/beta` (called "beta folder" later).

### Change the trainer data
#### Change the trainer data

Modify the new `trainerdata.json` in the beta folder with the new balance
changes in [#experimental](https://discord.com/channels/542061814704373782/542403024417456138).

Until the final release is live, you can checkout `beta.html` to test things
out, beta after beta.

### Change the icons
#### Change the icons

Icons size is 47px width x 48px height. The ratio hasn't been kept to deal with
some artifacts as there are different icon styles used by the game (square, rounded,
with or without black border).

**It's not recommended to re-edit the images from the older version**, due to the
quality loss it implies. Lossless icons for all skills are available in the
[CoRT Icons pack](https://github.com/mascaldotfr/CoRT/releases).
[CoRT Icons pack](https://github.com/mascaldotfr/CoRT-icons).

That pack also includes a python script to automatically refresh skills icons from
your edited `trainerdata.json`. Its usage is explained in the pack's README, and
is the **heavily recommended method**.

### Making the new version available on the website once the new version is live
#### Making the new version available on the website once the new version is live

Copy the beta folder to `data/trainer/1.x.x` according to the new version number.

Update the array containing all available versions in
`js/trainertools/constants.js` with the newest version last.

That's it.


## BOSSES

It's very important to check out bosses respawns at least every 3 months, as
the respawn time is slowly drifting in the future.

Updating the bosses requires to change `api/bin/bosses/BossesCalculator.php`
with a Unix timestamp corresponding to the observated boss respawn.

If you run MacOS or Linux, run this in a Terminal while waiting for the boss
and press `Ctrl-C` when you see it. The last number is the good Unix timestamp:

```shell
while :; do date +%s; sleep 1; done
```

Alternatively, you can check out [this website](https://time.is/Unix_time) but
you can't stop the counter.


## BZ

Updating the BZ beginning and ending times requires to change
`api/bin/bz/Battlezone.php` with their respective hours in UTC (currently, the
ingame schedule shows UTC hours already), while keeping the ascending order.
22 changes: 22 additions & 0 deletions api/MAINTENANCE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# MAINTENANCE

This API endpoint allows to display a message in a red card on top of each
page, to warn for servers issues and potentially other stuff, if
`/api/var/maintenance.txt` exists and is non-empty.

## URL

https://cort.thebus.top/api/var/maintenance.txt

## Usage

### Add a maintenance message

Create/Open the `maintenance.txt` file inside `/api/var`, and put your
maintenance message there. HTML is allowed.

### Remove a maintenance message

Just empty the file. It must be zero byte long.

It's not recommended to delete the file, for SEO reasons.
34 changes: 34 additions & 0 deletions api/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# APIs

## About

Each API endpoint has a README.md explaining what they do.

The whole API is written in PHP.

See the [deploy docs](../deploy/README.md) as well if you want to deploy it.

## READMEs list

- [setups collector and trainer stats](bin/collect/README.md)
- [bosses](bin/bosses/README.md)
- [bz](bin/bz/README.md)
- [warstatus](bin/warstatus/README.md)
- [warzone stats and events](bin/warstatus/stats/README.md)
- [sentinel](bin/sentinel/README.md)

Special stuff:

- [put a maintenance message](MAINTENANCE.md)

## API endpoints

To get the whole list:

1. Open https://mascaldotfr.github.io/CoRT/
2. Open the dev tools (F12)
3. Paste this line in the console and press enter:

```js
(await import("./js/api_url.js")).__api__urls
```
Loading