| Both sides previous revisionPrevious revisionNext revision | Previous revision |
| games:linux:2004scape_localhost [2026/06/03 23:45] – [Server Start] Sean Rhone | games:linux:2004scape_localhost [2026/07/02 18:11] (current) – [Information] Sean Rhone |
|---|
| * ''225'' | * ''225'' |
| * [[https://lostcity.rs/t/singleplayer-main-branch-scripts-and-desktop-start-launchers-on-windows-linux-freebsd/54|Lost City Forums]] | * [[https://lostcity.rs/t/singleplayer-main-branch-scripts-and-desktop-start-launchers-on-windows-linux-freebsd/54|Lost City Forums]] |
| | |
| | ===== Media ===== |
| | |
| | * [[https://media.realmofespionage.xyz/index/category/2|Progress Pics]] |
| | * [[https://www.youtube.com/watch?v=E21y7rLZaNc|Presentation Video]] |
| |
| ===== Prerequisites ===== | ===== Prerequisites ===== |
| ===== bun ===== | ===== bun ===== |
| |
| * [[https://github.com/oven-sh/bun/releases|oven-sh/bun]] ((''bun-linux-x64-baseline.zip'' for older CPU, [[https://bun.com/docs/installation#baseline-builds|more info]])) | * https://bun.com/ |
| * Last tested version: ''1.3.14'' | * https://github.com/oven-sh/bun |
| | * Latest [[https://github.com/oven-sh/bun/releases/latest/download/bun-linux-x64.zip|bun-linux-x64.zip]] (([[https://github.com/oven-sh/bun/releases/latest/download/bun-linux-x64-baseline.zip|baseline]] for older CPU, [[https://bun.com/docs/installation#baseline-builds|more info]])) |
| |
| rm -Rf '/tmp/bun-linux-x64'* && mkdir -p ~/'Projects/LostCity-225-EngineTS/ext' && wget -O '/tmp/bun-linux-x64.zip' 'https://github.com/oven-sh/bun/releases/latest/download/bun-linux-x64.zip' && unzip '/tmp/bun-linux-x64.zip' -d '/tmp' && mv -f '/tmp/bun-linux-x64/bun' ~/'Projects/LostCity-225-EngineTS/ext' && ~/'Projects/LostCity-225-EngineTS/ext/bun' --version && rm -Rf '/tmp/bun-linux-x64'* | rm -Rf '/tmp/bun-linux-x64'* && mkdir -p ~/'Projects/LostCity-225-EngineTS/ext' && wget -O '/tmp/bun-linux-x64.zip' 'https://github.com/oven-sh/bun/releases/latest/download/bun-linux-x64.zip' && unzip '/tmp/bun-linux-x64.zip' -d '/tmp' && mv -f '/tmp/bun-linux-x64/bun' ~/'Projects/LostCity-225-EngineTS/ext' && ~/'Projects/LostCity-225-EngineTS/ext/bun' --version && rm -Rf '/tmp/bun-linux-x64'* |
| |
| ==== Canary Test ==== | |
| |
| * https://github.com/oven-sh/bun/releases/tag/canary | |
| * Last tested version: ''1.4.0'' | |
| |
| rm -Rf '/tmp/bun-linux-x64'* && mkdir -p ~/'Projects/LostCity-225-EngineTS/ext' && wget -O '/tmp/bun-linux-x64.zip' 'https://github.com/oven-sh/bun/releases/download/canary/bun-linux-x64.zip' && unzip '/tmp/bun-linux-x64.zip' -d '/tmp' && mv -f '/tmp/bun-linux-x64/bun' ~/'Projects/LostCity-225-EngineTS/ext' && ~/'Projects/LostCity-225-EngineTS/ext/bun' --version && rm -Rf '/tmp/bun-linux-x64'* | |
| |
| ====== Download Source ====== | ====== Download Source ====== |
| * Set up as a development world | * Set up as a development world |
| |
| ~/'Projects/LostCity-225-EngineTS/ext/bun' --cwd=$HOME/'Projects/LostCity-225-EngineTS/src' run 'setup' | ~/'Projects/LostCity-225-EngineTS/ext/bun' --cwd=$HOME/'Projects/LostCity-225-EngineTS/src' run ~/'Projects/LostCity-225-EngineTS/src/tools/server/setup.ts' |
| |
| ====== Settings ====== | ====== Settings ====== |
| git -C ~/'Projects/LostCity-225-EngineTS/content' pull origin '225' --rebase | git -C ~/'Projects/LostCity-225-EngineTS/content' pull origin '225' --rebase |
| |
| ~/'Projects/LostCity-225-EngineTS/ext/bun' --cwd=$HOME/'Projects/LostCity-225-EngineTS/src' run 'clean' | ~/'Projects/LostCity-225-EngineTS/ext/bun' --cwd=$HOME/'Projects/LostCity-225-EngineTS/src' run ~/'Projects/LostCity-225-EngineTS/src/tools/pack/Clean.ts' |
| ~/'Projects/LostCity-225-EngineTS/ext/bun' --cwd=$HOME/'Projects/LostCity-225-EngineTS/src' 'install' | ~/'Projects/LostCity-225-EngineTS/ext/bun' --cwd=$HOME/'Projects/LostCity-225-EngineTS/src' 'install' |
| ~/'Projects/LostCity-225-EngineTS/ext/bun' --cwd=$HOME/'Projects/LostCity-225-EngineTS/src' run 'setup' | ~/'Projects/LostCity-225-EngineTS/ext/bun' --cwd=$HOME/'Projects/LostCity-225-EngineTS/src' run ~/'Projects/LostCity-225-EngineTS/src/tools/server/setup.ts' |
| | |
| | # Extras |
| | |
| | # Extras End |
| |
| zenity --title '2004Scape Updater' --text 'localhost server update complete' --icon ~/'Projects/LostCity-225-EngineTS/ext/favicon.ico' --timeout '1' --info | zenity --title '2004Scape Updater' --text 'localhost server update complete' --icon ~/'Projects/LostCity-225-EngineTS/ext/favicon.ico' --timeout '1' --info |
| | : |
| |
| # End</code> | # End</code> |
| * ''SC55_zzdenis_v0.5.sf2'' | * ''SC55_zzdenis_v0.5.sf2'' |
| |
| mkdir -p ~/'Projects/LostCity-225-EngineTS/ext' && sha384sum ~/'Downloads/SC55_zzdenis_v0.5.sf2' | grep 'f386f638777072fc220e39afbd7efcd227ca2bfcf13403bf47fbb2e2b8f4d151239710cc36c8530a75c3b4c3f55066b7' > '/dev/null' && mv -f ~/'Downloads/SC55_zzdenis_v0.5.sf2' ~/'Projects/LostCity-225-EngineTS/ext' | mkdir -p ~/'Projects/LostCity-225-EngineTS/ext' && sha384sum ~/'Downloads/SC55_zzdenis_v0.5.sf2' | grep 'f386f638777072fc220e39afbd7efcd227ca2bfcf13403bf47fbb2e2b8f4d151239710cc36c8530a75c3b4c3f55066b7' > '/dev/null' && mv -f ~/'Downloads/SC55_zzdenis_v0.5.sf2' ~/'Projects/LostCity-225-EngineTS/ext' && ln -s -f ~/'Projects/LostCity-225-EngineTS/ext/SC55_zzdenis_v0.5.sf2' ~/'Projects/LostCity-225-EngineTS/src/public/client/SCC1_Florestan.sf2' && ls -la ~/'Projects/LostCity-225-EngineTS/src/public/client/SCC1_Florestan.sf2' |
| |
| ==== Update Script ==== | ==== Update Script ==== |
| |
| * Above ''zenity'' line | * Within ''# Extras'' section |
| |
| nano ~/'Projects/LostCity-225-EngineTS/scripts/localhost-server-update.sh' | nano ~/'Projects/LostCity-225-EngineTS/scripts/localhost-server-update.sh' |
| # SF End</code> | # SF End</code> |
| |
| ===== Login Autofill ===== | ===== Client Settings ===== |
| |
| * [[https://github.com/2004Scape/Server/issues/1498|#1498]] | * Modifies ''client.js'' to have pre-filled username/password ([[https://github.com/2004Scape/Server/issues/1498|#1498]]) |
| * Modifies ''client.js'' to have pre-filled username/password | * Defaults ''Pixel Scaling'' instead of ''Auto'' |
| |
| sed -i -e 's/usernameInput="";passwordInput=""/usernameInput="Espionage724";passwordInput="1"/g' ~/'Projects/LostCity-225-EngineTS/src/public/client/client.js' | sed -i -e 's/usernameInput="";passwordInput=""/usernameInput="Espionage724";passwordInput="1"/g' ~/'Projects/LostCity-225-EngineTS/src/public/client/client.js' |
| | |
| | sed -i -e "s#'pixelated' : 'auto'#'pixelated' : 'pixelated'#g" ~/'Projects/LostCity-225-EngineTS/src/view/client.ejs' |
| |
| ==== Update Script ==== | ==== Update Script ==== |
| |
| * Above ''zenity'' line | * Within ''# Extras'' section |
| |
| nano ~/'Projects/LostCity-225-EngineTS/scripts/localhost-server-update.sh' | nano ~/'Projects/LostCity-225-EngineTS/scripts/localhost-server-update.sh' |
| # Login Autofill | # Login Autofill |
| sed -i -e 's/usernameInput="";passwordInput=""/usernameInput="Espionage724";passwordInput="1"/g' ~/'Projects/LostCity-225-EngineTS/src/public/client/client.js' | sed -i -e 's/usernameInput="";passwordInput=""/usernameInput="Espionage724";passwordInput="1"/g' ~/'Projects/LostCity-225-EngineTS/src/public/client/client.js' |
| # Autofill End</code> | # Pixel Scaling |
| | sed -i -e "s#'pixelated' : 'auto'#'pixelated' : 'pixelated'#g" ~/'Projects/LostCity-225-EngineTS/src/view/client.ejs' |
| | # Settings End</code> |
| |
| ====== Desktop Launcher ====== | ====== Desktop Launcher ====== |
| Name=2004Scape | Name=2004Scape |
| Categories=Game; | Categories=Game; |
| | Path=/tmp |
| Exec='/bin/bash' -c "WEBKIT_DISABLE_COMPOSITING_MODE='1' '/usr/libexec/libwebkitgtk-6_0-0/MiniBrowser' --dark-mode --autoplay-policy 'allow' --private --features='-PreferPageRenderingUpdatesNear60FPS' 'http://localhost:8888/rs2.cgi'" | Exec='/bin/bash' -c "WEBKIT_DISABLE_COMPOSITING_MODE='1' '/usr/libexec/libwebkitgtk-6_0-0/MiniBrowser' --dark-mode --autoplay-policy 'allow' --private --features='-PreferPageRenderingUpdatesNear60FPS' 'http://localhost:8888/rs2.cgi'" |
| Type=Application | Type=Application |
| |
| mkdir -p ~/'Projects/LostCity-225-EngineTS/src/data/players/localhost' && gio open ~/'Projects/LostCity-225-EngineTS/src/data/players/localhost' | mkdir -p ~/'Projects/LostCity-225-EngineTS/src/data/players/localhost' && gio open ~/'Projects/LostCity-225-EngineTS/src/data/players/localhost' |
| | |
| | ===== Bun Commands ===== |
| | |
| | **** |
| | |
| | ~/'Projects/LostCity-225-EngineTS/ext/bun' --cwd=$HOME/'Projects/LostCity-225-EngineTS/src' run |
| | |
| | ===== Bun Canary ===== |
| | |
| | * https://github.com/oven-sh/bun/releases/tag/canary |
| | * Last tested version: ''1.4.0'' |
| | |
| | rm -Rf '/tmp/bun-linux-x64'* && mkdir -p ~/'Projects/LostCity-225-EngineTS/ext' && wget -O '/tmp/bun-linux-x64.zip' 'https://github.com/oven-sh/bun/releases/download/canary/bun-linux-x64.zip' && unzip '/tmp/bun-linux-x64.zip' -d '/tmp' && mv -f '/tmp/bun-linux-x64/bun' ~/'Projects/LostCity-225-EngineTS/ext' && ~/'Projects/LostCity-225-EngineTS/ext/bun' --version && rm -Rf '/tmp/bun-linux-x64'* |
| |
| ===== MiniBrowser ===== | ===== MiniBrowser ===== |
| |
| * ''WEBKIT_DISABLE_COMPOSITING_MODE=1'' disables GPU acceleration and improves stability ((used to randomly crash on laptop battery)) | * ''WEBKIT_DISABLE_COMPOSITING_MODE=1'' disables GPU acceleration and improves stability ((used to randomly crash on laptop battery)) |
| | * :?: ''wpewebkit-minibrowser'' |
| |
| zypper search 'minibrowser' | zypper search 'minibrowser' |
| |
| rpm -ql 'webkit2gtk3-minibrowser' | rpm -ql 'webkit2gtk4-minibrowser' |
| |
| ls '/usr/libexec/libwebkit'*'/MiniBrowser' | ls '/usr/libexec/libwebkit'*'/MiniBrowser' |
| | |
| | ==== GTK4 ==== |
| |
| sudo zypper install 'webkitgtk4-minibrowser' | sudo zypper install 'webkitgtk4-minibrowser' |
| |
| WEBKIT_DISABLE_COMPOSITING_MODE='1' '/usr/libexec/libwebkitgtk-6_0-0/MiniBrowser' --dark-mode --autoplay-policy 'allow' --private --features='-PreferPageRenderingUpdatesNear60FPS' 'http://localhost:8888/rs2.cgi' | WEBKIT_DISABLE_COMPOSITING_MODE='1' '/usr/libexec/libwebkitgtk-6_0-0/MiniBrowser' --dark-mode --autoplay-policy 'allow' --private --features='-PreferPageRenderingUpdatesNear60FPS' 'http://localhost:8888/rs2.cgi' |
| | |
| | === Live === |
| | |
| | * High Detail |
| | * World 2 |
| | |
| | WEBKIT_DISABLE_COMPOSITING_MODE='1' '/usr/libexec/libwebkitgtk-6_0-0/MiniBrowser' --dark-mode --autoplay-policy 'allow' --private --features='-PreferPageRenderingUpdatesNear60FPS' 'https://2004.lostcity.rs/client?world=2&detail=high&method=0' |
| | |
| | ==== GTK3 ==== |
| |
| sudo zypper install 'webkitgtk3-minibrowser' | sudo zypper install 'webkitgtk3-minibrowser' |