# h6rd/dota2pornfxweb architecture

> Architecture diagram of the GitHub repository h6rd/dota2pornfxweb, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-10-23). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/h6rd/dota2pornfxweb
- Repository: https://github.com/h6rd/dota2pornfxweb

## Overview

##### Project type and purpose
- This is a static, front-end–only web application (no server-side code) whose sole purpose is to present and allow downloads of Dota 2 mod files (`.vpk`, `.zip`) and video previews. Users browse categories (heroes, terrains, shaders, etc.), see previews (MP4), and click to download.

##### File structure
- Top-level:
- index.html – main entry point
- style.css – presentation layer
- script.js – client logic (category filtering, preview playback, download links)
- assets/
– files/… (all mod archives organized by category)
– previews/… (video previews organized by the same categories)
- No “backend” folder or server‐side scripts—everything is served statically.
- No build tools or deployment scripts—just raw HTML/CSS/JS and an asset tree.

##### README for additional insights
- README contains user-facing installation instructions for each mod type (vpk, packs, terrains, weather changer, etc.), but no developer docs.
- No mention of dynamic data sources, API endpoints, or database.

a. Components
- CLIENT: Browser (renders index.html, executes script.js, applies style.css)
- STATIC WEB SERVER (e.g., Nginx, Apache, GitHub Pages)
- FILE STORAGE:
– /index.html, /style.css, /script.js
– /assets/files (mod packages)
– /assets/previews (video previews)
- EXTERNAL SERVICE: Telegram channel link (for support/updates)
b. Relationships & Data flow
1. User opens URL → HTTP GET /index.html
2. Browser GETs style.css & script.js
3. Browser GETs category data implicitly by requesting static URLs under /assets/files and /assets/previews when user interacts (e.g., clicks category or preview thumbnail)
4. Browser GETs mod file link → download
5. Browser “external link” click → Telegram channel
c. Architectural patterns & principles
– Separation of concerns: HTML (structure), CSS (presentation), JS (behavior)
– Static asset hosting: no dynamic back end, leverage CDN or web-server caching
– Directory-per-category for easy scaling: adding new categories simply means dropping a new folder under assets/files and assets/previews
d. Key technologies
– HTML5, CSS3, vanilla JavaScript
– Standard HTTP/HTTPS, static file serving
– Optional: web server (Nginx/Apache) or static host (GitHub Pages, Netlify)

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% Compute nodes
    classDef compute fill:#cce5ff,stroke:#3399ff,color:#000;
    classDef storage fill:#e6ffe6,stroke:#33cc33,color:#000;
    classDef external fill:#fff0b3,stroke:#e6b800,color:#000;

    Browser["Browser / Client"]:::compute

    subgraph "Front-end Files"
        HTML["index.html"]:::compute
        CSS["style.css"]:::compute
        JS["script.js"]:::compute
    end

    Server["Static Web Server"]:::compute

    subgraph "Assets"
        Files["assets/files/"]:::storage
        Previews["assets/previews/"]:::storage
    end

    External["Telegram Support"]:::external

    Browser -->|"GET index.html,style.css,script.js"| Server
    Server -->|"serves index.html"| HTML
    Server -->|"serves style.css"| CSS
    Server -->|"serves script.js"| JS

    Browser -->|"GET /assets/files/... "| Server
    Server -->|"serves mod packages"| Files

    Browser -->|"GET /assets/previews/... "| Server
    Server -->|"serves video previews"| Previews

    Browser -->|"Click support link"| External

    click HTML "https://github.com/h6rd/dota2pornfxweb/blob/main/index.html"
    click CSS "https://github.com/h6rd/dota2pornfxweb/blob/main/style.css"
    click JS "https://github.com/h6rd/dota2pornfxweb/blob/main/script.js"
    click Files "https://github.com/h6rd/dota2pornfxweb/tree/main/assets/files/"
    click Previews "https://github.com/h6rd/dota2pornfxweb/tree/main/assets/previews/"
```
