Skip to content

About

Show CS ZE player data for my own needs.

Topics

Resources

Code of conduct

Stars

7 stars

Watchers

1 watching

Forks

Latest commit

 

History

1,085 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ZE Graph Website

Code Size TypeScript React Rust JavaScript SQL Total line of code

Description

This track all Zombie Escape related servers (CS2, CS:GO, CS:S and TF2) that I’m aware of, allowing you to view player playtime on each server. It was originally created to monitor only the GFL Zombie Escape server, but has since expanded to include several servers in the western community. Chinese servers are not tracked due to technical limitations on their servers. Only GFL and Mapeadores servers provide Steam IDs, enabling consistent tracking of individual players. Other servers rely solely on player names for tracking. Any request for me to track your own server, you can contact me through the provided email address on the website.

This is codebase is purely for displaying data from the database. Itself does not store the player data and webscraping. Those are hidden. If you wish to host your own, you would need to implement your own datascraping mechanism.

How it works

The scraper (hidden) pulls from all the sources below and dumps everything into the database (PostgreSQL). The backend (Rust) does the heavy queries on top of it and caches the results in redis so the smol vps doesn't die. The frontend (Next.js) is the website you see. Radar maps are rendered by QGIS straight from PostGIS, and profile pictures come from multiple sources that i wrote originally in Python. Literally ported to Rust for that service tbh.

flowchart LR
  %% Scraper sources
  subgraph EXS["🔗 Scraper Sources"]
    direction TB
    SteamA2s("Steam A2S")
    GFLAPI("GFL API")
    GFLBans("GFLBans")
    Nide("Nide.GG")
    Cola("Cola Team Bans")
    Otaku("Otaku Bans")
    RSS("RSS Bans")
    MusicNames("GitHub Music-Names")
    YouTube("Youtube API v3")
    SteamAPI("Steam API")
  end

  %% Scraper & Database
  subgraph DSDB["🗄️ Scraper & Database"]
    direction TB
    DataScraper("Data Scraper (Hidden)")
    Database[("PostgreSQL")]
  end

  %% Backend sources
  subgraph EXB["🔗 Backend Sources"]
    direction TB
    ExternalProfileProvider("External Profile Provider")
    Vauff("Vauff.com")
    S2ZE("s2ze.com")
  end

  %% Backend & GIS
  subgraph BE["🖥️ Backend Services"]
    direction TB
    ProfileProvider("Profile Picture Provider")
    Backend("Backend")
    QGIS("QGIS Server")
  end

  %% Frontend
  subgraph FE["🌐 Frontend"]
    direction TB
    Website("The Website")
  end

  %% Scraper inputs
  SteamA2s       ==>|Players & Map| DataScraper
  GFLAPI         ==>|Match Score & Misc data| DataScraper
  GFLBans        ==>|Players & Infraction| DataScraper
  Nide           ==>|Players & Infraction| DataScraper
  Cola           ==>|Players & Infraction| DataScraper
  Otaku          ==>|Players & Infraction| DataScraper
  RSS            ==>|Players & Infraction| DataScraper
  MusicNames     ==>|Map Music| DataScraper
  YouTube        ==>|Map Music Video| DataScraper
  SteamAPI       ==>|Location| DataScraper

  %% Profile + backend inputs
  SteamAPI                ==> ProfileProvider
  ExternalProfileProvider ==> ProfileProvider
  Vauff          ==>|Map Images| Backend
  S2ZE           ==>|Map Metadata| Backend

  %% Core flow (left to right)
  DataScraper    <==> Database
  Database       ==>|Heavy Query| Backend
  Backend        ==>|Write Only| Database
  Database       ==>|PostGIS| QGIS
  ProfileProvider ==>|Image URL| Backend
  Backend        <==> Website
  QGIS           ==>|WMS| Website

  %% Node styles
  classDef fe fill:#e1f5fe,stroke:#0277bd,stroke-width:2px,color:#000000
  classDef be fill:#e8f5e9,stroke:#2e7d32,stroke-width:2px,color:#000000
  classDef db fill:#f3e5f5,stroke:#7b1fa2,stroke-width:2px,color:#000000
  classDef ex fill:#fff3e0,stroke:#ef6c00,stroke-width:2px,color:#000000

  class Website fe
  class Backend,QGIS,ProfileProvider be
  class DataScraper,Database db
  class ExternalProfileProvider,MusicNames,YouTube,SteamAPI,SteamA2s,GFLBans,Vauff,S2ZE,GFLAPI,Nide,Cola,Otaku,RSS ex

  %% Subgraph styles
  style FE fill:#e1f5fe,stroke:#0277bd,stroke-width:2px,color:#000000
  style BE fill:#e8f5e9,stroke:#2e7d32,stroke-width:2px,color:#000000
  style DSDB fill:#f3e5f5,stroke:#7b1fa2,stroke-width:2px,color:#000000
  style EXS fill:#fff3e0,stroke:#ef6c00,stroke-width:2px,color:#000000
  style EXB fill:#fff3e0,stroke:#ef6c00,stroke-width:2px,color:#000000
Loading

Deploy

  1. Get a PostgreSQL with PostGIS and pg_cron extensions, then run db.sql on it.
  2. Copy default.env to .env and fill it in. Inside docker, localhost is the container itself, so point REDIS_URL at redis://redis:6379/ and DB_HOST at host.docker.internal if postgres is on the host.
  3. Generate VAPID keys for push notifications, and point VAPIDS_PATH at ./vapids:
    openssl ecparam -genkey -name prime256v1 -out vapids/vapid_private.pem
    openssl ec -in vapids/vapid_private.pem -pubout -out vapids/vapid_public.pem
  4. Running it
    docker compose up --build -d                  # production, on port 51020
    docker compose -f compose.dev.yaml up --build # development, on port 3002

How I actually deploy it (swarm, staging, CI) is all in deployment/README.md.

Preview

Main Page

More pages
Server Page
Server
Players Page
Players
Player Page
Player
Maps Page
Maps
Map Page
Map
Live Radar Page
Live Radar
Radar Page
Radar
Radar Page2
Radar by Country
Tracker Page
Tracker
3D Viewer
3D Viewer
Info Sharing
Info Sharing
Statuses
Statuses

About

Show CS ZE player data for my own needs.

Topics

Resources

Code of conduct

Stars

7 stars

Watchers

1 watching

Forks

Releases

Sponsor this project

Packages

Used by

Contributors

Languages