webclient-css/README.md
2026-07-27 11:41:14 +01:00

4.1 KiB

css-ze webclient to play on unloze with: https://webclient.unloze.com/

the entire code base of Dockerfile, html, python, json, sh and js is AI Code with almost no human edits being made.

notes

uses gstreamer, weston, lavapipe, css inbuilt DXVK, vulkan, a signaling server, html, docker and cloudflare serverless SFU.

docker rm css-test docker build -t css-client .

pre installment step for signaling-server

cd ~/webclient_css_ze/streaming-agent && npm install

pre shader creation for mounting

mkdir -p /home/gameservers/webclient_css_ze/mesa-shader-cache chmod 777 /home/gameservers/webclient_css_ze/mesa-shader-cache

first run

./start-signaling.sh

second run mounting points for content

mkdir -p /mnt/merged-cstrike/{maps,materials,models,sound}

for asset in maps materials models sound; do mount -t overlay overlay
-o lowerdir=/home/gameservers/css_ze/cstrike/$asset:/home/gameservers/css_mg/cstrike/$asset:/home/gameservers/css_zr/cstrike/$asset
/mnt/merged-cstrike/$asset done

vim /etc/fstab overlay /mnt/merged-cstrike/maps overlay ro,lowerdir=/home/gameservers/css_ze/cstrike/maps:/home/gameservers/css_mg/cstrike/maps:/home/gameservers/css_zr/cstrike/maps,nofail,x-systemd.requires-mounts-for=/home/gameservers/css_ze,x-systemd.requires-mounts-for=/home/gameservers/css_mg,x-systemd.requires-mounts-for=/home/gameservers/css_zr 0 0 overlay /mnt/merged-cstrike/materials overlay ro,lowerdir=/home/gameservers/css_ze/cstrike/materials:/home/gameservers/css_mg/cstrike/materials:/home/gameservers/css_zr/cstrike/materials,nofail 0 0 overlay /mnt/merged-cstrike/models overlay ro,lowerdir=/home/gameservers/css_ze/cstrike/models:/home/gameservers/css_mg/cstrike/models:/home/gameservers/css_zr/cstrike/models,nofail 0 0 overlay /mnt/merged-cstrike/sound overlay ro,lowerdir=/home/gameservers/css_ze/cstrike/sound:/home/gameservers/css_mg/cstrike/sound:/home/gameservers/css_zr/cstrike/sound,nofail 0 0

third run

docker run -d --name css-test -e SIG_URL=ws://172.17.0.1:3000 -e CONTAINER_NAME=css-test -e CF_APP_ID= -e CF_APP_TOKEN= -e CAP_FPS=60 -e CAP_W=800 -e CAP_H=600 --cpus="10.0"
-v /mnt/merged-cstrike/maps:/home/ubuntu/Counter-Strike\ Source/cstrike/maps:ro
-v /mnt/merged-cstrike/materials:/home/ubuntu/Counter-Strike\ Source/cstrike/materials:ro
-v /mnt/merged-cstrike/models:/home/ubuntu/Counter-Strike\ Source/cstrike/models:ro
-v /mnt/merged-cstrike/sound:/home/ubuntu/Counter-Strike\ Source/cstrike/sound:ro
-v /home/gameservers/webclient-ubuntu26/mesa-shader-cache:/home/ubuntu/.cache/mesa_shader_cache
css-client

docker logs -f css-test

pkill -f signaling-server.js

pgrep -f signaling-server.js

to change screen resolution:

autoexec.cfg -> mat_setvideomode 800 600 0

start.sh -> weston --backend=headless-backend.so --width=800 --height=600 --no-config &

the nosteam.zip and the wine_user_folder.zip are not intended to be uploaded to git.

the wine_user_folder.zip is just the generic .wine folder that is used. the nosteam.zip is the Counter Strike Source folder for nosteam when using 7launcher.

However both are uploaded to the unloze fastdownload over at: https://uk-fastdl.unloze.com/css_ze/webclient_zips/

of course if you view this repository 7-10 years later in the future theres a good chance the url is probably not working any longer.

the client launches the game with -vulkan parameter specified in the rev.ini.

CSS DirectX9 → built-in DXVK → Vulkan → Wine Wayland driver → Weston (lavapipe/llvmpipe) → Xwayland → X11 → ximagesrc capture for gst_agent

using MESA_SHADER_CACHE which are mounted volumes

the inbuilt DXVK version 2.3 is replaced with DXVK 3.0 downloaded from https://github.com/doitsujin/dxvk/releases/download/v3.0/dxvk-3.0.tar.gz

docker cp dxvk-3.0/x64/d3d9.dll 'css-test:/home/ubuntu/Counter-Strike Source/bin/x64/dxvk_d3d9.dll' #probably was like this to copy it in.

relies on nosteam_celt plugin for receiving the name correctly. -> https://git.unloze.com/UNLOZE/sm-plugins/src/branch/master/CELT_VOICE

this also relies on the unloze edition of the connect extension found over at -> https://git.unloze.com/UNLOZE/sm-ext-connect