Compare commits

..

2 Commits

Author SHA1 Message Date
Daniel Fragomeli
a50665b3da Merge branch 'hydralauncher:main' into hydra 2024-11-23 16:17:33 +01:00
dan098
681a07b44b Italian README file added 2024-05-28 14:27:11 +02:00
203 changed files with 3132 additions and 6948 deletions

View File

@@ -1,2 +1,4 @@
MAIN_VITE_API_URL=API_URL
MAIN_VITE_AUTH_URL=AUTH_URL
MAIN_VITE_STEAMGRIDDB_API_KEY=YOUR_API_KEY
RENDERER_VITE_INTERCOM_APP_ID=YOUR_APP_ID

View File

@@ -3,4 +3,3 @@ dist
out
.gitignore
migration.stub
hydra-python-rpc/

View File

@@ -26,9 +26,4 @@ module.exports = {
},
],
},
settings: {
react: {
version: "detect",
},
},
};

View File

@@ -2,6 +2,9 @@ name: Build
on: pull_request
env:
AWS_REGION: us-east-1
jobs:
build:
strategy:
@@ -19,6 +22,16 @@ jobs:
with:
node-version: 20.18.0
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v2
with:
aws-access-key-id: ${{ secrets.R2_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.R2_SECRET_ACCESS_KEY }}
aws-region: ${{ env.AWS_REGION }}
- name: Push build to R2
run: aws s3 sync ./docs s3://${{ vars.BUILDS_BUCKET_NAME }}
- name: Install dependencies
run: yarn
@@ -31,7 +44,7 @@ jobs:
run: pip install -r requirements.txt
- name: Build with cx_Freeze
run: python python_rpc/setup.py build
run: python torrent-client/setup.py build
- name: Build Linux
if: matrix.os == 'ubuntu-latest'
@@ -45,9 +58,7 @@ jobs:
MAIN_VITE_CHECKOUT_URL: ${{ vars.MAIN_VITE_STAGING_CHECKOUT_URL }}
MAIN_VITE_ANALYTICS_API_URL: ${{ vars.MAIN_VITE_ANALYTICS_API_URL }}
RENDERER_VITE_INTERCOM_APP_ID: ${{ vars.RENDERER_VITE_INTERCOM_APP_ID }}
RENDERER_VITE_EXTERNAL_RESOURCES_URL: ${{ vars.RENDERER_VITE_EXTERNAL_RESOURCES_URL }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MAIN_VITE_EXTERNAL_RESOURCES_URL: ${{ vars.MAIN_VITE_EXTERNAL_RESOURCES_URL }}
- name: Build Windows
if: matrix.os == 'windows-latest'
@@ -58,21 +69,7 @@ jobs:
MAIN_VITE_CHECKOUT_URL: ${{ vars.MAIN_VITE_STAGING_CHECKOUT_URL }}
MAIN_VITE_ANALYTICS_API_URL: ${{ vars.MAIN_VITE_ANALYTICS_API_URL }}
RENDERER_VITE_INTERCOM_APP_ID: ${{ vars.RENDERER_VITE_INTERCOM_APP_ID }}
RENDERER_VITE_EXTERNAL_RESOURCES_URL: ${{ vars.RENDERER_VITE_EXTERNAL_RESOURCES_URL }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MAIN_VITE_EXTERNAL_RESOURCES_URL: ${{ vars.MAIN_VITE_EXTERNAL_RESOURCES_URL }}
- name: Test Upload build
env:
BRANCH_NAME: ${{ github.head_ref || github.ref_name }}
S3_ENDPOINT: ${{ secrets.S3_ENDPOINT }}
S3_ACCESS_KEY_ID: ${{ secrets.S3_ACCESS_KEY_ID }}
S3_SECRET_ACCESS_KEY: ${{ secrets.S3_SECRET_ACCESS_KEY }}
S3_BUILDS_BUCKET_NAME: ${{ secrets.S3_BUILDS_BUCKET_NAME }}
BUILDS_URL: ${{ secrets.BUILDS_URL }}
BUILD_WEBHOOK_URL: ${{ secrets.BUILD_WEBHOOK_URL }}
GITHUB_ACTOR: ${{ github.actor }}
run: node scripts/upload-build.cjs
- name: Create artifact
uses: actions/upload-artifact@v4

View File

@@ -33,7 +33,7 @@ jobs:
run: pip install -r requirements.txt
- name: Build with cx_Freeze
run: python python_rpc/setup.py build
run: python torrent-client/setup.py build
- name: Build Linux
if: matrix.os == 'ubuntu-latest'
@@ -47,9 +47,7 @@ jobs:
MAIN_VITE_CHECKOUT_URL: ${{ vars.MAIN_VITE_CHECKOUT_URL }}
MAIN_VITE_ANALYTICS_API_URL: ${{ vars.MAIN_VITE_ANALYTICS_API_URL }}
RENDERER_VITE_INTERCOM_APP_ID: ${{ vars.RENDERER_VITE_INTERCOM_APP_ID }}
RENDERER_VITE_EXTERNAL_RESOURCES_URL: ${{ vars.RENDERER_VITE_EXTERNAL_RESOURCES_URL }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MAIN_VITE_EXTERNAL_RESOURCES_URL: ${{ vars.MAIN_VITE_EXTERNAL_RESOURCES_URL }}
- name: Build Windows
if: matrix.os == 'windows-latest'
run: yarn build:win
@@ -59,9 +57,7 @@ jobs:
MAIN_VITE_CHECKOUT_URL: ${{ vars.MAIN_VITE_CHECKOUT_URL }}
MAIN_VITE_ANALYTICS_API_URL: ${{ vars.MAIN_VITE_ANALYTICS_API_URL }}
RENDERER_VITE_INTERCOM_APP_ID: ${{ vars.RENDERER_VITE_INTERCOM_APP_ID }}
RENDERER_VITE_EXTERNAL_RESOURCES_URL: ${{ vars.RENDERER_VITE_EXTERNAL_RESOURCES_URL }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MAIN_VITE_EXTERNAL_RESOURCES_URL: ${{ vars.MAIN_VITE_EXTERNAL_RESOURCES_URL }}
- name: Create artifact
uses: actions/upload-artifact@v4
with:

6
.gitignore vendored
View File

@@ -1,5 +1,7 @@
.vscode/
node_modules/
hydra-download-manager/
fastlist.exe
__pycache__
dist
out
@@ -7,6 +9,4 @@ out
*.log*
.env
.vite
ludusavi/
hydra-python-rpc/
aria2/
ludusavi/

View File

@@ -1 +0,0 @@
3.9.20

183
README.it.md Normal file
View File

@@ -0,0 +1,183 @@
<br>
<div align="center">
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>
<p align="center">
<strong>Hydra è un game launcher con il proprio client bittorrent e autogestore di repacks.</strong>
</p>
[![build](https://img.shields.io/github/actions/workflow/status/hydralauncher/hydra/build.yml)](https://github.com/hydralauncher/hydra/actions)
[![release](https://img.shields.io/github/package-json/v/hydralauncher/hydra)](https://github.com/hydralauncher/hydra/releases)
[![be](https://img.shields.io/badge/lang-be-orange)](README.be.md)
[![pl](https://img.shields.io/badge/lang-pl-white)](README.pl.md)
[![pt-BR](https://img.shields.io/badge/lang-pt--BR-green.svg)](README.pt-BR.md)
[![ru](https://img.shields.io/badge/lang-ru-yellow.svg)](README.ru.md)
[![uk-UA](https://img.shields.io/badge/lang-uk--UA-blue)](README.uk-UA.md)
[![es](https://img.shields.io/badge/lang-es-red)](README.es.md)
[![ita](https://img.shields.io/badge/lang-it-red)](README.it.md)
![Hydra Catalogue](./docs/screenshot.png)
</div>
## Table of Contents
- [A proposito](#a-proposito)
- [Caratteristiche](#caratteristiche)
- [Installazione](#installazione)
- [Contribuire](#contribuire)
- [Uscisciti su Telegram](#unisciti-su-telegram)
- [Forka e Clona la tua repository](#forka-e-clona-la-tua-repository)
- [Modi in cui contribuire](#modi-in-cui-contribuire)
- [Struttura del Progetto](#struttura-del-progetto)
- [Compila il codice sorgente](#compila-il-codice-sorgente)
- [Installa Node.js](#installa-nodejs)
- [Installa Yarn](#installa-yarn)
- [Installa le Node Dependencies](#installa-node-dependencies)
- [Installa Python 3.9](#installa-python-39)
- [Installa le Python Dependencies](#installa-python-dependencies)
- [Variabili d'Ambiente](#variabili-di-ambiente)
- [Esecuzione](#esecuzione)
- [Compilazione](#compilazione)
- [Compilare il client bittorrent](#compilazione-client-bittorrent)
- [Compilare l'applicazione Electron](#compilazione-applicazione-electron)
- [Collaboratori](#collaboratori)
## A proposito
**Hydra** è un **Game Launcher** con il proprio **Client BitTorrent** e **autogestore di repack**.
<br>
Il launcher è scritto in TypeScript (Electron) and Python, che gestisce il sistema di torrenting appoggiandosi a libtorrent.
## Caratteristiche
- Motore di ricerca automatizzato sulle fonti di repack dal [Megathread]("https://www.reddit.com/r/Piracy/wiki/megathread/")
- Client Bittorrent integrato
- Integrazione How Long To Beat (HLTB) nella pagina del gioco
- Percorso del download Personalizzato
- Notifiche di aggiornamenti sulla list dei repacks
- Supporto Windows e Linux
- Costantemente Aggiornato
- E molto altro ...
## Installazione
Segui i seguenti passi:
1. Scarica l'ultima versione di Hydra dalla pagina [Releases](https://github.com/hydralauncher/hydra/releases/latest).
- Scarica solo il file .exe per installare Hydra su Windows.
- Scarica il file .deb o .rpm o .zip per Linux. (Dipende dalla tua distro Linux)
2. Esegui il file scaricato.
3. Goditi Hydra!
## <a name="contribuire"> Contribuire
### <a name="unisciti-su-telegram"></a> Unisciti su Telegram
Puoi unirti alle nostre conversazioni sul canale [Telegram](https://t.me/hydralauncher).
### Forka e Clona la repository
1. Forka la repository [(clicca qui per forkare)](https://github.com/hydralauncher/hydra/fork)
2. Clona il tuo codice forkato `git clone https://github.com/your_username/hydra`
3. Crea un nuovo branch
4. Aggiungi le modifiche (push)
5. Invia la richiesta di pull
### Modi in cui contribuire
- Traduzione: Vogliamo rendere Hydra disponibile a più persone possibile. Sentiti libero di tradurre in altre lingue o aggiornare e migliorare quelle già disponibili su Hydra.
- Programmazione: Hydra è programmato in TypeScript, Electron e un po' di Python. Se intendi contribuire unisciti al nostro [Telegram](https://t.me/hydralauncher)!
### Struttura del Progetto
- client-torrent: Usiamo libtorrent, una libreria Python, per gestire i download dei torrent
- src/renderer: l'UI dell'applicazione
- src/main: tutta la logica qui.
## Compilazione
### Installa Node.js
Assicurati di avere Node.js installato sulla tua macchina. Scaricalo e installalo da [nodejs.org](https://nodejs.org/).
### Installa Yarn
Yarn è un gestore di pacchetti per Node.js. Se non hai ancora installato Yarn segui le istruzioni su [yarnpkg.com](https://classic.yarnpkg.com/lang/en/docs/install/).
### Installa le dipendenze Node
Naviga alla cartella del progetto e installa le dipendenze Node con Yarn:
```bash
cd hydra
yarn
```
### Installa Python 3.9
Assicurati di avere Python 3.9 installato. Puoi scaricarlo da [python.org](https://www.python.org/downloads/release/python-3913/).
### Installa le Dipendenze Python
Installa le dipendenze con pip:
```bash
pip install -r requirements.txt
```
## Variabili d'ambiente
Avrai bisogno di una chiave API SteamGridDB per poter caricare le icone di gioco.
Se intendi avere onlinefix come repacker dovrai aggiungere le tue credenziali al file .env
Una volta ottenuta, puoi copiare e rinominare il file `.env.example` a `.env` e metterlo in `STEAMGRIDDB_API_KEY`, `ONLINEFIX_USERNAME`, `ONLINEFIX_PASSWORD`.
## Esecuzione
Una volta impostato tutto, puoi eseguire il seguente comando per avviare il processo Electron e il client bittorrent:
```bash
yarn dev
```
## Compilazione
### Compila il bittorrent
Usa il comando:
```bash
python torrent-client/setup.py build
```
### Compila l'applicazione Electron
Usa il comando:
Per Windows:
```bash
yarn build:win
```
Per Linux:
```bash
yarn build:linux
```
## Collaboratori
<a href="https://github.com/hydralauncher/hydra/graphs/contributors">
<img src="https://contrib.rocks/image?repo=hydralauncher/hydra" />
</a>
## Licenza
Hydra è concesso in licenza secondo la [MIT License](LICENSE).

View File

@@ -2,7 +2,7 @@
<div align="center">
[<img src="./resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>
@@ -125,10 +125,6 @@ cd hydra
yarn
```
### Install OpenSSL 1.1
[OpenSSL 1.1](https://slproweb.com/download/Win64OpenSSL-1_1_1w.exe) is required by libtorrent in Windows environments.
### Install Python 3.9
Ensure you have Python 3.9 installed on your machine. You can download and install it from [python.org](https://www.python.org/downloads/release/python-3913/).

Binary file not shown.

Before

Width:  |  Height:  |  Size: 108 KiB

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

After

Width:  |  Height:  |  Size: 188 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

After

Width:  |  Height:  |  Size: 188 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 604 KiB

After

Width:  |  Height:  |  Size: 151 KiB

View File

@@ -2,7 +2,7 @@
<div align="center">
[<img src="../resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>

View File

@@ -2,7 +2,7 @@
<div align="center">
[<img src="./resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>

View File

@@ -2,7 +2,7 @@
<div align="center">
[<img src="../resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>

View File

@@ -2,7 +2,7 @@
<div align="center">
[<img src="../resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>

View File

@@ -2,7 +2,7 @@
<div align="center">
[<img src="./resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>

View File

@@ -1,6 +1,6 @@
<div align="center">
[<img src="../resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="../resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>

View File

@@ -2,7 +2,7 @@
<div align="center">
[<img src="./resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>

View File

@@ -2,7 +2,7 @@
<div align="center">
[<img src="./resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>

View File

@@ -2,7 +2,7 @@
<div align="center">
[<img src="./resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>

View File

@@ -2,7 +2,7 @@
<div align="center">
[<img src="./resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>

View File

@@ -2,7 +2,7 @@
<div align="center">
[<img src="../resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>
@@ -14,7 +14,7 @@
[![release](https://img.shields.io/github/package-json/v/hydralauncher/hydra)](https://github.com/hydralauncher/hydra/releases)
[![pt-BR](https://img.shields.io/badge/lang-pt--BR-green.svg)](README.pt-BR.md)
[![en](https://img.shields.io/badge/lang-en-red.svg)](../README.md)
[![en](https://img.shields.io/badge/lang-en-red.svg)](README.md)
[![ru](https://img.shields.io/badge/lang-ru-yellow.svg)](README.ru.md)
[![uk-UA](https://img.shields.io/badge/lang-uk--UA-blue)](README.uk-UA.md)
[![be](https://img.shields.io/badge/lang-be-orange)](README.be.md)

View File

@@ -2,7 +2,7 @@
<div align="center">
[<img src="../resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>
@@ -14,7 +14,7 @@
[![release](https://img.shields.io/github/package-json/v/hydralauncher/hydra)](https://github.com/hydralauncher/hydra/releases)
[![pt-BR](https://img.shields.io/badge/lang-pt--BR-green.svg)](README.pt-BR.md)
[![en](https://img.shields.io/badge/lang-en-red.svg)](../README.md)
[![en](https://img.shields.io/badge/lang-en-red.svg)](README.md)
[![ru](https://img.shields.io/badge/lang-ru-yellow.svg)](README.ru.md)
[![uk-UA](https://img.shields.io/badge/lang-uk--UA-blue)](README.uk-UA.md)
[![be](https://img.shields.io/badge/lang-be-orange)](README.be.md)

View File

@@ -2,7 +2,7 @@
<div align="center">
[<img src="./resources/icon.png" width="144"/>](https://help.hydralauncher.gg)
[<img src="./resources/icon.png" width="144"/>](https://hydralauncher.site)
<h1 align="center">Hydra Launcher</h1>

View File

@@ -3,9 +3,8 @@ productName: Hydra
directories:
buildResources: build
extraResources:
- aria2
- ludusavi
- hydra-python-rpc
- hydra-download-manager
- seeds
- from: node_modules/create-desktop-shortcuts/src/windows.vbs
- from: resources/achievement.wav

View File

@@ -1,6 +1,6 @@
{
"name": "hydralauncher",
"version": "3.1.2",
"version": "3.0.5",
"description": "Hydra",
"main": "./out/main/index.js",
"author": "Los Broxas",
@@ -23,7 +23,7 @@
"start": "electron-vite preview",
"dev": "electron-vite dev",
"build": "npm run typecheck && electron-vite build",
"postinstall": "electron-builder install-app-deps && node ./scripts/postinstall.cjs",
"postinstall": "electron-builder install-app-deps && node ./postinstall.cjs",
"build:unpack": "npm run build && electron-builder --dir",
"build:win": "electron-vite build && electron-builder --win",
"build:mac": "electron-vite build && electron-builder --mac",
@@ -34,27 +34,28 @@
"dependencies": {
"@electron-toolkit/preload": "^3.0.0",
"@electron-toolkit/utils": "^3.0.0",
"@fontsource/noto-sans": "^5.1.0",
"@hookform/resolvers": "^3.9.1",
"@fontsource/noto-sans": "^5.0.22",
"@hookform/resolvers": "^3.9.0",
"@intercom/messenger-js-sdk": "^0.0.14",
"@primer/octicons-react": "^19.9.0",
"@radix-ui/react-dropdown-menu": "^2.1.2",
"@reduxjs/toolkit": "^2.2.3",
"@vanilla-extract/css": "^1.14.2",
"@vanilla-extract/dynamic": "^2.1.2",
"@vanilla-extract/dynamic": "^2.1.1",
"@vanilla-extract/recipes": "^0.5.2",
"auto-launch": "^5.0.6",
"axios": "^1.7.9",
"better-sqlite3": "^11.7.0",
"axios": "^1.7.7",
"better-sqlite3": "^11.3.0",
"check-disk-space": "^3.4.0",
"classnames": "^2.5.1",
"color": "^4.2.3",
"color.js": "^1.2.0",
"create-desktop-shortcuts": "^1.11.0",
"date-fns": "^3.6.0",
"dexie": "^4.0.10",
"electron-log": "^5.2.4",
"dexie": "^4.0.9",
"electron-log": "^5.2.0",
"electron-updater": "^6.3.9",
"file-type": "^19.6.0",
"flexsearch": "^0.7.43",
"i18next": "^23.11.2",
"i18next-browser-languagedetector": "^7.2.1",
"jsdom": "^24.0.0",
@@ -63,7 +64,6 @@
"lodash-es": "^4.17.21",
"parse-torrent": "^11.0.17",
"piscina": "^4.7.0",
"rc-virtual-list": "^3.16.1",
"react-hook-form": "^7.53.0",
"react-i18next": "^14.1.0",
"react-loading-skeleton": "^3.4.0",
@@ -73,15 +73,14 @@
"sudo-prompt": "^9.2.1",
"tar": "^7.4.3",
"typeorm": "^0.3.20",
"user-agents": "^1.1.387",
"yaml": "^2.6.1",
"yup": "^1.5.0",
"zod": "^3.24.1"
"user-agents": "^1.1.193",
"yaml": "^2.4.1",
"yup": "^1.4.0",
"zod": "^3.23.8"
},
"devDependencies": {
"@aws-sdk/client-s3": "^3.705.0",
"@commitlint/cli": "^19.6.0",
"@commitlint/config-conventional": "^19.6.0",
"@commitlint/cli": "^19.5.0",
"@commitlint/config-conventional": "^19.5.0",
"@electron-toolkit/eslint-config-prettier": "^2.0.0",
"@electron-toolkit/eslint-config-ts": "^2.0.0",
"@electron-toolkit/tsconfig": "^1.0.1",
@@ -89,8 +88,8 @@
"@types/auto-launch": "^5.0.5",
"@types/color": "^3.0.6",
"@types/folder-hash": "^4.0.4",
"@types/jsdom": "^21.1.7",
"@types/jsonwebtoken": "^9.0.7",
"@types/jsdom": "^21.1.6",
"@types/jsonwebtoken": "^9.0.6",
"@types/lodash-es": "^4.17.12",
"@types/node": "^20.12.7",
"@types/parse-torrent": "^5.8.7",
@@ -100,15 +99,15 @@
"@types/user-agents": "^1.0.4",
"@vanilla-extract/vite-plugin": "^4.0.7",
"@vitejs/plugin-react": "^4.2.1",
"electron": "^31.7.6",
"electron": "^30.3.0",
"electron-builder": "^25.1.8",
"electron-vite": "^2.0.0",
"eslint": "^8.56.0",
"eslint-plugin-jsx-a11y": "^6.10.2",
"eslint-plugin-react": "^7.37.2",
"eslint-plugin-jsx-a11y": "^6.8.0",
"eslint-plugin-react": "^7.33.2",
"eslint-plugin-react-hooks": "^4.6.0",
"husky": "^9.1.7",
"prettier": "^3.4.2",
"husky": "^9.0.11",
"prettier": "^3.2.4",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"sass-embedded": "^1.80.6",

49
postinstall.cjs Normal file
View File

@@ -0,0 +1,49 @@
const { default: axios } = require("axios");
const util = require("node:util");
const fs = require("node:fs");
const path = require("node:path");
const exec = util.promisify(require("node:child_process").exec);
const fileName = {
win32: "ludusavi-v0.25.0-win64.zip",
linux: "ludusavi-v0.25.0-linux.zip",
darwin: "ludusavi-v0.25.0-mac.zip",
};
const downloadLudusavi = async () => {
if (fs.existsSync("ludusavi")) {
console.log("Ludusavi already exists, skipping download...");
return;
}
const file = fileName[process.platform];
const downloadUrl = `https://github.com/mtkennerly/ludusavi/releases/download/v0.25.0/${file}`;
console.log(`Downloading ${file}...`);
const response = await axios.get(downloadUrl, { responseType: "stream" });
const stream = response.data.pipe(fs.createWriteStream(file));
stream.on("finish", async () => {
console.log(`Downloaded ${file}, extracting...`);
const pwd = process.cwd();
const targetPath = path.join(pwd, "ludusavi");
await exec(`npx extract-zip ${file} ${targetPath}`);
if (process.platform !== "win32") {
fs.chmodSync(path.join(targetPath, "ludusavi"), 0o755);
}
console.log("Extracted. Renaming folder...");
console.log(`Extracted ${file}, removing compressed downloaded file...`);
fs.rmSync(file);
});
};
downloadLudusavi();

View File

@@ -1,47 +0,0 @@
import aria2p
class HttpDownloader:
def __init__(self):
self.download = None
self.aria2 = aria2p.API(
aria2p.Client(
host="http://localhost",
port=6800,
secret=""
)
)
def start_download(self, url: str, save_path: str, header: str):
if self.download:
self.aria2.resume([self.download])
else:
downloads = self.aria2.add(url, options={"header": header, "dir": save_path})
self.download = downloads[0]
def pause_download(self):
if self.download:
self.aria2.pause([self.download])
def cancel_download(self):
if self.download:
self.aria2.remove([self.download])
self.download = None
def get_download_status(self):
if self.download == None:
return None
download = self.aria2.get_download(self.download.gid)
response = {
'folderName': download.name,
'fileSize': download.total_length,
'progress': download.completed_length / download.total_length if download.total_length else 0,
'downloadSpeed': download.download_speed,
'numPeers': 0,
'numSeeds': 0,
'status': download.status,
'bytesDownloaded': download.completed_length,
}
return response

View File

@@ -1,183 +0,0 @@
from flask import Flask, request, jsonify
import sys, json, urllib.parse, psutil
from torrent_downloader import TorrentDownloader
from http_downloader import HttpDownloader
from profile_image_processor import ProfileImageProcessor
import libtorrent as lt
app = Flask(__name__)
# Retrieve command line arguments
torrent_port = sys.argv[1]
http_port = sys.argv[2]
rpc_password = sys.argv[3]
start_download_payload = sys.argv[4]
start_seeding_payload = sys.argv[5]
downloads = {}
# This can be streamed down from Node
downloading_game_id = -1
torrent_session = lt.session({'listen_interfaces': '0.0.0.0:{port}'.format(port=torrent_port)})
if start_download_payload:
initial_download = json.loads(urllib.parse.unquote(start_download_payload))
downloading_game_id = initial_download['game_id']
if initial_download['url'].startswith('magnet'):
torrent_downloader = TorrentDownloader(torrent_session)
downloads[initial_download['game_id']] = torrent_downloader
try:
torrent_downloader.start_download(initial_download['url'], initial_download['save_path'], "")
except Exception as e:
print("Error starting torrent download", e)
else:
http_downloader = HttpDownloader()
downloads[initial_download['game_id']] = http_downloader
try:
http_downloader.start_download(initial_download['url'], initial_download['save_path'], initial_download.get('header'))
except Exception as e:
print("Error starting http download", e)
if start_seeding_payload:
initial_seeding = json.loads(urllib.parse.unquote(start_seeding_payload))
for seed in initial_seeding:
torrent_downloader = TorrentDownloader(torrent_session, lt.torrent_flags.upload_mode)
downloads[seed['game_id']] = torrent_downloader
try:
torrent_downloader.start_download(seed['url'], seed['save_path'], "")
except Exception as e:
print("Error starting seeding", e)
def validate_rpc_password():
"""Middleware to validate RPC password."""
header_password = request.headers.get('x-hydra-rpc-password')
if header_password != rpc_password:
return jsonify({"error": "Unauthorized"}), 401
@app.route("/status", methods=["GET"])
def status():
auth_error = validate_rpc_password()
if auth_error:
return auth_error
downloader = downloads.get(downloading_game_id)
if downloader:
status = downloads.get(downloading_game_id).get_download_status()
return jsonify(status), 200
else:
return jsonify(None)
@app.route("/seed-status", methods=["GET"])
def seed_status():
auth_error = validate_rpc_password()
if auth_error:
return auth_error
seed_status = []
for game_id, downloader in downloads.items():
if not downloader:
continue
response = downloader.get_download_status()
if response is None:
continue
if response.get('status') == 5:
seed_status.append({
'gameId': game_id,
**response,
})
return jsonify(seed_status), 200
@app.route("/healthcheck", methods=["GET"])
def healthcheck():
return "", 200
@app.route("/process-list", methods=["GET"])
def process_list():
auth_error = validate_rpc_password()
if auth_error:
return auth_error
process_list = [proc.info for proc in psutil.process_iter(['exe', 'pid', 'name'])]
return jsonify(process_list), 200
@app.route("/profile-image", methods=["POST"])
def profile_image():
auth_error = validate_rpc_password()
if auth_error:
return auth_error
data = request.get_json()
image_path = data.get('image_path')
try:
processed_image_path, mime_type = ProfileImageProcessor.process_image(image_path)
return jsonify({'imagePath': processed_image_path, 'mimeType': mime_type}), 200
except Exception as e:
return jsonify({"error": str(e)}), 400
@app.route("/action", methods=["POST"])
def action():
global torrent_session
global downloading_game_id
auth_error = validate_rpc_password()
if auth_error:
return auth_error
data = request.get_json()
action = data.get('action')
game_id = data.get('game_id')
if action == 'start':
url = data.get('url')
existing_downloader = downloads.get(game_id)
if url.startswith('magnet'):
if existing_downloader and isinstance(existing_downloader, TorrentDownloader):
existing_downloader.start_download(url, data['save_path'], "")
else:
torrent_downloader = TorrentDownloader(torrent_session)
downloads[game_id] = torrent_downloader
torrent_downloader.start_download(url, data['save_path'], "")
else:
if existing_downloader and isinstance(existing_downloader, HttpDownloader):
existing_downloader.start_download(url, data['save_path'], data.get('header'))
else:
http_downloader = HttpDownloader()
downloads[game_id] = http_downloader
http_downloader.start_download(url, data['save_path'], data.get('header'))
downloading_game_id = game_id
elif action == 'pause':
downloader = downloads.get(game_id)
if downloader:
downloader.pause_download()
downloading_game_id = -1
elif action == 'cancel':
downloader = downloads.get(game_id)
if downloader:
downloader.cancel_download()
elif action == 'resume_seeding':
torrent_downloader = TorrentDownloader(torrent_session, lt.torrent_flags.upload_mode)
downloads[game_id] = torrent_downloader
torrent_downloader.start_download(data['url'], data['save_path'], "")
elif action == 'pause_seeding':
downloader = downloads.get(game_id)
if downloader:
downloader.cancel_download()
else:
return jsonify({"error": "Invalid action"}), 400
return "", 200
if __name__ == "__main__":
app.run(host="0.0.0.0", port=int(http_port))

View File

@@ -4,5 +4,3 @@ cx_Logging; sys_platform == 'win32'
pywin32; sys_platform == 'win32'
psutil
Pillow
flask
aria2p

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

After

Width:  |  Height:  |  Size: 188 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 59 KiB

View File

@@ -1,120 +0,0 @@
const { default: axios } = require("axios");
const util = require("node:util");
const fs = require("node:fs");
const path = require("node:path");
const { spawnSync } = require("node:child_process");
const exec = util.promisify(require("node:child_process").exec);
const fileName = {
win32: "ludusavi-v0.25.0-win64.zip",
linux: "ludusavi-v0.25.0-linux.zip",
darwin: "ludusavi-v0.25.0-mac.zip",
};
const downloadLudusavi = async () => {
if (fs.existsSync("ludusavi")) {
console.log("Ludusavi already exists, skipping download...");
return;
}
const file = fileName[process.platform];
const downloadUrl = `https://github.com/mtkennerly/ludusavi/releases/download/v0.25.0/${file}`;
console.log(`Downloading ${file}...`);
const response = await axios.get(downloadUrl, { responseType: "stream" });
const stream = response.data.pipe(fs.createWriteStream(file));
stream.on("finish", async () => {
console.log(`Downloaded ${file}, extracting...`);
const pwd = process.cwd();
const targetPath = path.join(pwd, "ludusavi");
await exec(`npx extract-zip ${file} ${targetPath}`);
if (process.platform !== "win32") {
fs.chmodSync(path.join(targetPath, "ludusavi"), 0o755);
}
console.log("Extracted. Renaming folder...");
console.log(`Extracted ${file}, removing compressed downloaded file...`);
fs.rmSync(file);
});
};
const downloadAria2WindowsAndLinux = async () => {
if (fs.existsSync("aria2")) {
console.log("Aria2 already exists, skipping download...");
return;
}
const file =
process.platform === "win32"
? "aria2-1.37.0-win-64bit-build1.zip"
: "aria2-1.37.0-1-x86_64.pkg.tar.zst";
const downloadUrl =
process.platform === "win32"
? `https://github.com/aria2/aria2/releases/download/release-1.37.0/${file}`
: "https://archlinux.org/packages/extra/x86_64/aria2/download/";
console.log(`Downloading ${file}...`);
const response = await axios.get(downloadUrl, { responseType: "stream" });
const stream = response.data.pipe(fs.createWriteStream(file));
stream.on("finish", async () => {
console.log(`Downloaded ${file}, extracting...`);
if (process.platform === "win32") {
await exec(`npx extract-zip ${file}`);
console.log("Extracted. Renaming folder...");
fs.mkdirSync("aria2");
fs.copyFileSync(
path.join(file.replace(".zip", ""), "aria2c.exe"),
"aria2/aria2c.exe"
);
fs.rmSync(file.replace(".zip", ""), { recursive: true });
} else {
await exec(`tar --zstd -xvf ${file} usr/bin/aria2c`);
console.log("Extracted. Copying binary file...");
fs.mkdirSync("aria2");
fs.copyFileSync("usr/bin/aria2c", "aria2/aria2c");
fs.rmSync("usr", { recursive: true });
}
console.log(`Extracted ${file}, removing compressed downloaded file...`);
fs.rmSync(file);
});
};
const copyAria2Macos = async () => {
console.log("Checking if aria2 is installed...");
const isAria2Installed = spawnSync("which", ["aria2c"]).status;
if (isAria2Installed != 0) {
console.log("Please install aria2");
console.log("brew install aria2");
return;
}
console.log("Copying aria2 binary...");
fs.mkdirSync("aria2");
await exec(`cp $(which aria2c) aria2/aria2c`);
};
if (process.platform == "darwin") {
copyAria2Macos();
} else {
downloadAria2WindowsAndLinux();
}
downloadLudusavi();

View File

@@ -1,66 +0,0 @@
const fs = require("node:fs");
const { S3Client, PutObjectCommand } = require("@aws-sdk/client-s3");
const path = require("node:path");
const packageJson = require("../package.json");
if (!process.env.BUILD_WEBHOOK_URL) {
console.log("No BUILD_WEBHOOK_URL provided, skipping upload");
process.exit(0);
}
const s3 = new S3Client({
region: "auto",
endpoint: process.env.S3_ENDPOINT,
forcePathStyle: true,
credentials: {
accessKeyId: process.env.S3_ACCESS_KEY_ID,
secretAccessKey: process.env.S3_SECRET_ACCESS_KEY,
},
});
const dist = path.resolve(__dirname, "..", "dist");
const extensionsToUpload = [".deb", ".exe", ".pacman"];
fs.readdir(dist, async (err, files) => {
if (err) throw err;
const uploads = await Promise.all(
files
.filter((file) => extensionsToUpload.includes(path.extname(file)))
.map(async (file) => {
console.log(`⌛️ Uploading ${file}...`);
const fileName = `${new Date().getTime()}-${file}`;
const command = new PutObjectCommand({
Bucket: process.env.S3_BUILDS_BUCKET_NAME,
Key: fileName,
Body: fs.createReadStream(path.resolve(dist, file)),
// 3 days
Expires: new Date(Date.now() + 1000 * 60 * 60 * 24 * 3),
});
await s3.send(command);
return {
url: `${process.env.BUILDS_URL}/${fileName}`,
name: fileName,
};
})
);
if (uploads.length > 0) {
await fetch(process.env.BUILD_WEBHOOK_URL, {
method: "POST",
headers: {
"Content-Type": "application/json",
},
body: JSON.stringify({
uploads,
branchName: process.env.BRANCH_NAME,
version: packageJson.version,
githubActor: process.env.GITHUB_ACTOR,
}),
});
}
});

File diff suppressed because one or more lines are too long

View File

@@ -1,49 +1,33 @@
{
"language_name": "اَلْعَرَبِيَّةُ",
"app": {
"successfully_signed_in": "تم تسجيل الدخول بنجاح"
},
"home": {
"featured": "مميّز",
"surprise_me": "فاجئني",
"no_results": "لم يتم العثور على نتائج",
"start_typing": "بدء الكتابة للبحث...",
"hot": "الأكثر رواجا الآن",
"weekly": "📅 أفضل ألعاب الأسبوع",
"achievements": "🏆 ألعاب للتغلب عليها"
"no_results": "لم يتم العثور على نتائج"
},
"sidebar": {
"catalogue": "قائمة الألعاب",
"downloads": "التنزيلات",
"downloads": "التحميلات",
"settings": "إعدادات",
"my_library": "مكتبتي",
"downloading_metadata": "{{title}} (جارٍ تنزيل البيانات الوصفية...)",
"paused": "{{title}} (متوقف مؤقتًا)",
"downloading": "{{title}} ({{percentage}} - جاري التنزيل...)",
"paused": "{{title}} (متوقف)",
"downloading": "{{title}} ({{percentage}} - جارٍ التنزيل...)",
"filter": "بحث في المكتبة",
"home": "الرئيسية",
"queued": "{{title}} (في قائمة الانتظار)",
"game_has_no_executable": "لم يتم تحديد اللعبة القابلة للتنفيذ",
"sign_in": "تسجيل الدخول",
"friends": "أصدقاء",
"need_help": "بحاجة الى مساعدة؟"
"home": "الرئيسية"
},
"header": {
"search": "ابحث عن الألعاب",
"home": "الرئيسية",
"catalogue": "قائمة الألعاب",
"downloads": "التنزيلات",
"downloads": "التحميلات",
"search_results": "نتائج البحث",
"settings": "إعدادات",
"version_available_install": "إصدار {{version}} متاح. ",
"version_available_download": "إصدار {{version}} متاح. "
"settings": "إعدادات"
},
"bottom_panel": {
"no_downloads_in_progress": "لا توجد تنزيلات قيد التقدم",
"downloading_metadata": "جارٍ التنزيل {{title}} البيانات الوصفية...",
"downloading": "جارٍ التنزيل {{title}}… ({{percentage}} مكتملة) - الانتهاء {{eta}} - {{speed}}",
"calculating_eta": "جارٍ التنزيل {{title}}… ({{percentage}} مكتمل) - حساب الوقت المتبقي...",
"checking_files": "التحقق {{title}} ملفات…({{percentage}} مكتمل)"
"no_downloads_in_progress": "لا يوجد تنزيلات جارية",
"downloading_metadata": "جارٍ تنزيل بيانات وصف {{title}}",
"downloading": "جارٍ تنزيل {{title}}… ({{percentage}} مكتملة) - الانتهاء {{eta}} - {{speed}}"
},
"catalogue": {
"next_page": "الصفحة التالية",
@@ -51,242 +35,101 @@
},
"game_details": {
"open_download_options": "افتح خيارات التنزيل",
"download_options_zero": "{{count}} خيارات التنزيل",
"download_options_zero": "لا يوجد خيار تنزيل",
"download_options_one": "{{count}} خيار تنزيل",
"download_options_other": "{{count}} خيار تنزيل",
"updated_at": "تم التحديث {{updated_at}}",
"install": "ثَبَّتَ",
"install": "تثبيت",
"resume": "استئناف",
"pause": "إيقاف",
"cancel": "إلغاء",
"remove": "إزالة",
"space_left_on_disk": "{{space}} متبقية على القرص",
"eta": "الوقت المتبقي {{eta}}",
"calculating_eta": "جارٍ حساب الوقت المتبقي…",
"downloading_metadata": "جارٍ تنزيل البيانات الوصفية…",
"filter": "إعادة حزم التصفية",
"downloading_metadata": "جاري تنزيل البيانات الوصفية...",
"filter": "تصفية حزم إعادة التجميع",
"requirements": "متطلبات النظام",
"minimum": "الحد الأدنى",
"recommended": ُستَحسَن",
"paused": "متوقف مؤقتًا",
"release_date": "صدر بتاريخ {{date}}",
"publisher": "نشرت من قبل {{publisher}}",
"recommended": وصى به",
"release_date": "تم الإصدار في {{date}}",
"publisher": "نشر بواسطة {{publisher}}",
"hours": "ساعات",
"minutes": "دقائق",
"amount_hours": "{{amount}} ساعات",
"amount_minutes": "{{amount}} دقائق",
"accuracy": "{{accuracy}}٪ دقة",
"add_to_library": "أضف إلى المكتبة",
"accuracy": "دقة {{accuracy}}%",
"add_to_library": "إضافة إلى المكتبة",
"remove_from_library": "إزالة من المكتبة",
"no_downloads": "لا التنزيلات المتاحة",
"no_downloads": "لا توجد تنزيلات متاحة",
"play_time": "تم اللعب لمدة {{amount}}",
"last_time_played": "لعبت آخر مرة {{period}}",
"not_played_yet": "أنت لم تلعب {{title}} حتى الآن",
"last_time_played": "آخر مرة لعبت {{period}}",
"not_played_yet": "لم تلعب {{title}} بعد",
"next_suggestion": "الاقتراح التالي",
"play": "لعب",
"deleting": "جارٍ حذف المثبت",
"deleting": "جاري حذف المثبت...",
"close": "إغلاق",
"playing_now": "قيداللعب الآن",
"playing_now": "قيد التشغيل الآن",
"change": "تغيير",
"repacks_modal_description": "اختر الحزمة التي تريد تنزيلها",
"select_folder_hint": "لتغيير المجلد الافتراضي، انتقل إلى <0>إعدادات</0>",
"download_now": "قم بالتنزيل الآن",
"no_shop_details": ا يمكن استرداد تفاصيل المتجر.",
"select_folder_hint": "لتغيير المجلد الافتراضي، انتقل إلى الإعدادات",
"download_now": "تنزيل الآن",
"no_shop_details": م يتم استرداد تفاصيل المتجر.",
"download_options": "خيارات التنزيل",
"download_path": "مسار التحميل",
"download_path": "مسار التنزيل",
"previous_screenshot": "لقطة الشاشة السابقة",
"next_screenshot": "لقطة الشاشة التالية",
"screenshot": "لقطة الشاشة {{number}}",
"open_screenshot": "فتح لقطة الشاشة {{number}}",
"download_settings": "تحميل الإعدادات",
"downloader": "أداة التنزيل",
"select_executable": "يختار",
"no_executable_selected": "لم يتم تحديد أي ملف قابل للتنفيذ",
"open_folder": "افتح المجلد",
"open_download_location": "انظر الملفات التي تم تنزيلها",
"create_shortcut": "إنشاء اختصار سطح المكتب",
"clear": "واضح",
"remove_files": "إزالة الملفات",
"remove_from_library_title": "هل أنت متأكد؟",
"remove_from_library_description": "سيتم إزالة هذا {{game}} من مكتبتك",
"options": "خيارات",
"executable_section_title": "قابل للتنفيذ",
"executable_section_description": "مسار الملف الذي سيتم تنفيذه عند النقر فوق \"تشغيل\".",
"downloads_secion_title": "التنزيلات",
"downloads_section_description": "تحقق من التحديثات أو الإصدارات الأخرى من هذه اللعبة",
"danger_zone_section_title": "منطقة الخطر",
"danger_zone_section_description": "قم بإزالة هذه اللعبة من مكتبتك أو الملفات التي تم تنزيلها بواسطة Hydra",
"download_in_progress": "التنزيل قيد التقدم",
"download_paused": "تم إيقاف التنزيل مؤقتًا",
"last_downloaded_option": "آخر خيار تم تنزيله",
"create_shortcut_success": "تم إنشاء الاختصار بنجاح",
"create_shortcut_error": "حدث خطأ أثناء إنشاء الاختصار",
"nsfw_content_title": "تحتوي هذه اللعبة على محتوى غير مناسب",
"nsfw_content_description": "{{title}} يحتوي على محتوى قد لا يكون مناسبًا لجميع الأعمار. ",
"allow_nsfw_content": "اسمح",
"refuse_nsfw_content": "عُد",
"stats": "احصائيات",
"download_count": "التنزيلات",
"player_count": "اللاعبين النشطين",
"download_error": "خيار التنزيل هذا غير متوفر",
"download": "تحميل",
"executable_path_in_use": "قابل للتنفيذ قيد الاستخدام بالفعل بواسطة \"{{game}}\"",
"warning": "تحذير:",
"hydra_needs_to_remain_open": "لإجراء هذا التنزيل، يجب أن يظل Hydra مفتوحًا حتى اكتماله. ",
"achievements": "الإنجازات",
"achievements_count": "الإنجازات {{unlockedCount}}/{{achievementsCount}}",
"cloud_save": "حفظ السحابة",
"cloud_save_description": "احفظ تقدمك في السحابة واستمر في اللعب على أي جهاز",
"backups": "النسخ الاحتياطية",
"install_backup": "ثَبَّتَ",
"delete_backup": "يمسح",
"create_backup": "نسخة احتياطية جديدة",
"last_backup_date": "آخر نسخة احتياطية قيد التشغيل {{date}}",
"no_backup_preview": "لم يتم العثور على ألعاب محفوظة لهذا العنوان",
"restoring_backup": "استعادة النسخة الاحتياطية ({{progress}} مكتمل)…",
"uploading_backup": "جارٍ تحميل النسخة الاحتياطية…",
"no_backups": "لم تقم بإنشاء أي نسخ احتياطية لهذه اللعبة حتى الآن",
"backup_uploaded": "تم تحميل النسخة الاحتياطية",
"backup_deleted": "تم حذف النسخة الاحتياطية",
"backup_restored": "تمت استعادة النسخة الاحتياطية",
"see_all_achievements": "شاهد جميع الإنجازات",
"sign_in_to_see_achievements": "قم بتسجيل الدخول لرؤية الإنجازات",
"mapping_method_automatic": "تلقائي",
"mapping_method_manual": "يدوي",
"mapping_method_label": "طريقة رسم الخرائط",
"files_automatically_mapped": "تم تعيين الملفات تلقائيًا",
"no_backups_created": "لم يتم إنشاء نسخ احتياطية لهذه اللعبة",
"manage_files": "إدارة الملفات",
"loading_save_preview": "جارٍ البحث عن حفظ الألعاب...",
"wine_prefix": "بادئة النبيذ",
"wine_prefix_description": "بادئة Wine المستخدمة لتشغيل هذه اللعبة",
"no_download_option_info": "لا توجد معلومات متاحة",
"backup_deletion_failed": "فشل في حذف النسخة الاحتياطية",
"max_number_of_artifacts_reached": "تم الوصول إلى الحد الأقصى لعدد النسخ الاحتياطية لهذه اللعبة",
"achievements_not_sync": "لا تتم مزامنة إنجازاتك",
"manage_files_description": "إدارة الملفات التي سيتم نسخها احتياطيًا واستعادتها",
"select_folder": "حدد المجلد",
"backup_from": "نسخة احتياطية من {{date}}",
"custom_backup_location_set": "تعيين موقع النسخ الاحتياطي المخصص",
"no_directory_selected": "لم يتم تحديد أي دليل",
"download_options_one": "{{count}} خيار التنزيل",
"download_options_two": "{{count}} خيارات التنزيل",
"download_options_few": "{{count}} خيارات التنزيل",
"download_options_many": "{{count}} خيارات التنزيل",
"download_options_other": "{{count}} خيارات التنزيل"
"screenshot": "لقطة شاشة {{number}}",
"open_screenshot": "افتح لقطة الشاشة {{number}}"
},
"activation": {
"title": "تفعيل Hydra",
"title": "تفعيل هايدرا",
"installation_id": "معرف التثبيت:",
"enter_activation_code": "أدخل رمز التفعيل الخاص بك",
"message": "إذا كنت لا تعرف أين تطلب هذا، فلا ينبغي أن يكون لديك هذا.",
"activate": "فعل",
"loading": "تحميل…"
"message": "إذا كنت لا تعرف أين تسأل عن هذا ، فلا يجب أن يكون لديك هذا.",
"activate": "تفعيل",
"loading": "جار التحميل…"
},
"downloads": {
"resume": "استئناف",
"pause": "إيقاف مؤقت",
"eta": "الوقت المتبقي {{eta}}",
"paused": "متوقف مؤقتًا",
"verifying": "جارٍ التحقق…",
"completed": "مكتمل",
"removed": "لم يتم تحميلها",
"paused": "متوقفة مؤقتًا",
"verifying": "جار التحقق…",
"completed": "اكتمل",
"cancel": "إلغاء",
"filter": "تصفية الألعاب التي تم تنزيلها",
"remove": "إزالة",
"downloading_metadata": "جارٍ تنزيل البيانات الوصفية…",
"deleting": "جارٍ حذف المثبت…",
"downloading_metadata": "جار تنزيل البيانات الوصفية…",
"deleting": "جار حذف المثبت…",
"delete": "إزالة المثبت",
"delete_modal_title": "هل أنت متأكد؟",
"delete_modal_description": "سيؤدي هذا إلى إزالة كافة ملفات التثبيت من جهاز الكمبيوتر الخاص بك",
"install": "ثَبَّتَ",
"download_in_progress": "في تَقَدم",
"queued_downloads": "التنزيلات في قائمة الانتظار",
"downloads_completed": "مكتمل",
"queued": "في قائمة الانتظار",
"no_downloads_title": "هذا فارغ",
"no_downloads_description": "لم تقم بتنزيل أي شيء باستخدام Hydra بعد، ولكن لم يفت الأوان بعد للبدء.",
"checking_files": "جارٍ فحص الملفات…"
"delete_modal_description": "سيؤدي هذا إلى إزالة جميع ملفات التثبيت من جهاز الكمبيوتر الخاص بك",
"install": "تثبيت"
},
"settings": {
"downloads_path": "مسار التنزيلات",
"change": "تحديث",
"notifications": "إشعارات",
"notifications": "الإشعارات",
"enable_download_notifications": "عند اكتمال التنزيل",
"enable_repack_list_notifications": "عند إضافة حزمة جديدة",
"real_debrid_api_token_label": "رمز Real-Debrid API",
"quit_app_instead_hiding": "لا تخفي Hydra عند الإغلاق",
"launch_with_system": "قم بتشغيل Hydra عند بدء تشغيل النظام",
"real_debrid_api_token_label": "رمز واجهة برمجة التطبيقات (API) لـReal-Debrid ",
"quit_app_instead_hiding": "إنهاء هايدرا بدلاً من التصغير الى شريط الحالة",
"launch_with_system": "تشغيل هايدرا عند بدء تشغيل النظام",
"general": "عام",
"behavior": "سلوك",
"download_sources": حميل المصادر",
"language": "لغة",
"real_debrid_api_token": "رمز API",
"enable_real_debrid": "تمكين ريال ديبريد",
"real_debrid_description": "Real-Debrid هو برنامج تنزيل غير مقيد يسمح لك بتنزيل الملفات بسرعة، ولا يقتصر ذلك إلا على سرعة الإنترنت لديك.",
"real_debrid_invalid_token": "رمز API غير صالح",
"real_debrid_api_token_hint": "يمكنك الحصول على رمز API الخاص بك <0>هنا</0>",
"real_debrid_free_account_error": "الحساب \"{{username}}\" هو حساب مجاني. يرجى الاشتراك في Real-Debrid",
"real_debrid_linked_message": "حساب \"{{username}}\"مرتبط",
"save_changes": "حفظ التغييرات",
"changes_saved": "تم حفظ التغييرات بنجاح",
"download_sources_description": "ستقوم Hydra بجلب روابط التنزيل من هذه المصادر. ",
"validate_download_source": "التحقق من صحة",
"remove_download_source": "إزالة",
"add_download_source": "أضف المصدر",
"download_count_zero": "{{countFormatted}} خيارات التنزيل",
"download_source_url": "تنزيل عنوان URL المصدر",
"add_download_source_description": "أدخل عنوان URL لملف .json",
"download_source_up_to_date": "محدث",
"download_source_errored": "خطأ",
"sync_download_sources": "مصادر المزامنة",
"removed_download_source": "تمت إزالة مصدر التنزيل",
"added_download_source": "تمت إضافة مصدر التنزيل",
"download_sources_synced": "تتم مزامنة جميع مصادر التنزيل",
"insert_valid_json_url": "أدخل عنوان URL صالحًا لـ JSON",
"found_download_option_zero": "وجد {{countFormatted}} خيارات التنزيل",
"import": "يستورد",
"public": "عام",
"private": "خاص",
"friends_only": "الأصدقاء فقط",
"privacy": "خصوصية",
"profile_visibility": "رؤية الملف الشخصي",
"profile_visibility_description": "اختر من يمكنه رؤية ملفك الشخصي ومكتبتك",
"required_field": "هذه الخانة مطلوبه",
"source_already_exists": "تمت إضافة هذا المصدر بالفعل",
"must_be_valid_url": "يجب أن يكون المصدر عنوان URL صالحًا",
"blocked_users": "المستخدمين المحظورين",
"user_unblocked": "تم إلغاء حظر المستخدم",
"enable_achievement_notifications": "عندما يتم فتح الإنجاز",
"launch_minimized": "تم تصغير إطلاق Hydra",
"disable_nsfw_alert": "تعطيل تنبيه NSFW",
"show_hidden_achievement_description": "إظهار وصف الإنجازات المخفية قبل فتحها",
"download_count_one": "{{countFormatted}} خيار التنزيل",
"download_count_two": "{{countFormatted}} خيارات التنزيل",
"download_count_few": "{{countFormatted}} خيارات التنزيل",
"download_count_many": "{{countFormatted}} خيارات التنزيل",
"download_count_other": "{{countFormatted}} خيارات التنزيل",
"found_download_option_one": "وجد {{countFormatted}} خيار التنزيل",
"found_download_option_two": "وجد {{countFormatted}} خيارات التنزيل",
"found_download_option_few": "وجد {{countFormatted}} خيارات التنزيل",
"found_download_option_many": "وجد {{countFormatted}} خيارات التنزيل",
"found_download_option_other": "وجد {{countFormatted}} خيارات التنزيل"
"behavior": "السلوك",
"enable_real_debrid": فعيل Real-Debrid ",
"real_debrid_api_token_hint": "يمكنك الحصول على مفتاح API الخاص بك هنا",
"save_changes": "حفظ التغييرات"
},
"notifications": {
"download_complete": "اكتمل التنزيل",
"game_ready_to_install": "{{title}} جاهز للتثبيت",
"repack_list_updated": "تم تحديث قائمة إعادة التعبئة",
"new_update_available": "إصدار {{version}} متاح",
"restart_to_install_update": "أعد تشغيل Hydra لتثبيت التحديث",
"notification_achievement_unlocked_title": "تم فتح الإنجاز لـ {{game}}",
"notification_achievement_unlocked_body": "{{achievement}} وغيرها {{count}} تم فتحها",
"repack_count_zero": "{{count}} تمت إضافة العبوات",
"repack_count_one": "{{count}} تمت إضافة أعد حزم",
"repack_count_two": "{{count}} تمت إضافة العبوات",
"repack_count_few": "{{count}} تمت إضافة العبوات",
"repack_count_many": "{{count}} تمت إضافة العبوات",
"repack_count_other": "{{count}} تمت إضافة العبوات"
"download_complete": "تم التحميل",
"game_ready_to_install": "{{title}} جاهزة للتثبيت",
"repack_list_updated": "قائمة التجميعات المحدثة",
"repack_count_one": "{{count}} حزمة مضافة",
"repack_count_other": "{{count}} حزم مُضافة"
},
"system_tray": {
"open": "افتح Hydra",
"open": "فتح هايدرا",
"quit": "خروج"
},
"game_card": {
@@ -294,109 +137,10 @@
},
"binary_not_found_modal": {
"title": "البرامج غير مثبتة",
"description": "لم يتم العثور على الملفات التنفيذية الخاصة بـ Wine أو Lutris على نظامك",
"instructions": "تحقق من الطريقة الصحيحة لتثبيت أي منها على توزيعة Linux لديك حتى تعمل اللعبة بشكل طبيعي"
"description": "لم يتم العثور على ملفات Wine أو Lutris التنفيذية على نظامك",
"instructions": "تحقق من الطريقة الصحيحة لتثبيت أي منها على توزيعة Linux الخاصة بك حتى تعمل اللعبة بشكل طبيعي"
},
"modal": {
"close": "زر الإغلاق"
},
"forms": {
"toggle_password_visibility": "تبديل رؤية كلمة المرور"
},
"user_profile": {
"amount_hours": "{{amount}} ساعات",
"amount_minutes": "{{amount}} دقائق",
"last_time_played": "لعبت آخر مرة {{period}}",
"activity": "النشاط الأخير",
"library": "مكتبة",
"total_play_time": "إجمالي وقت اللعب",
"no_recent_activity_title": "هممم... لا شيء هنا",
"no_recent_activity_description": "لم تلعب أي مباراة مؤخرًا. ",
"display_name": "اسم العرض",
"saving": "توفير",
"save": "يحفظ",
"edit_profile": "تحرير الملف الشخصي",
"saved_successfully": "تم الحفظ بنجاح",
"try_again": "من فضلك، حاول مرة أخرى",
"sign_out_modal_title": "هل أنت متأكد؟",
"cancel": "إلغاء",
"successfully_signed_out": "تم تسجيل الخروج بنجاح",
"sign_out": "تسجيل الخروج",
"playing_for": "اللعب من أجل {{amount}}",
"sign_out_modal_text": "مكتبتك مرتبطة بحسابك الحالي. ",
"add_friends": "أضف أصدقاء",
"add": "يضيف",
"friend_code": "رمز الصديق",
"see_profile": "انظر الملف الشخصي",
"sending": "إرسال",
"friend_request_sent": "تم إرسال طلب الصداقة",
"friends": "أصدقاء",
"friends_list": "قائمة الأصدقاء",
"user_not_found": "لم يتم العثور على المستخدم",
"block_user": "حظر المستخدم",
"add_friend": "إضافة صديق",
"request_sent": "تم إرسال الطلب",
"request_received": "تم استلام الطلب",
"accept_request": "قبول الطلب",
"ignore_request": "تجاهل الطلب",
"cancel_request": "إلغاء الطلب",
"undo_friendship": "التراجع عن الصداقة",
"request_accepted": "تم قبول الطلب",
"user_blocked_successfully": "تم حظر المستخدم بنجاح",
"user_block_modal_text": "هذا سوف يمنع {{displayName}}",
"blocked_users": "المستخدمين المحظورين",
"unblock": "إلغاء الحظر",
"no_friends_added": "ليس لديك أي أصدقاء مضافين",
"pending": "قيد الانتظار",
"no_pending_invites": "ليس لديك أي دعوات معلقة",
"no_blocked_users": "ليس لديك أي مستخدمين محظورين",
"friend_code_copied": "تم نسخ رمز الصديق",
"undo_friendship_modal_text": "سيؤدي هذا إلى التراجع عن صداقتك معه {{displayName}}",
"privacy_hint": "لضبط من يمكنه رؤية هذا، انتقل إلى <0>إعدادات</0>",
"locked_profile": "هذا الملف الشخصي خاص",
"image_process_failure": "فشل أثناء معالجة الصورة",
"required_field": "هذه الخانة مطلوبه",
"displayname_min_length": "يجب أن يتكون اسم العرض من 3 أحرف على الأقل",
"displayname_max_length": "يجب ألا يزيد طول اسم العرض عن 50 حرفًا",
"report_profile": "الإبلاغ عن هذا الملف الشخصي",
"report_reason": "لماذا تقوم بالإبلاغ عن هذا الملف الشخصي؟",
"report_description": "معلومات إضافية",
"report_description_placeholder": "معلومات إضافية",
"report": "تقرير",
"report_reason_hate": "خطاب الكراهية",
"report_reason_sexual_content": "المحتوى الجنسي",
"report_reason_violence": "عنف",
"report_reason_spam": "رسائل إلكترونية مزعجة",
"profile_reported": "تم الإبلاغ عن الملف الشخصي",
"your_friend_code": "رمز صديقك:",
"upload_banner": "تحميل لافتة",
"uploading_banner": "جارٍ تحميل البانر…",
"background_image_updated": "تم تحديث صورة الخلفية",
"report_reason_zero": "آخر",
"report_reason_one": "لماذا تقوم بالإبلاغ عن هذا الملف الشخصي؟",
"report_reason_two": "آخر",
"report_reason_few": "آخر",
"report_reason_many": "آخر",
"report_reason_other": "آخر"
},
"achievement": {
"achievement_unlocked": "تم فتح الإنجاز",
"user_achievements": "{{displayName}}إنجازات",
"your_achievements": "إنجازاتك",
"unlocked_at": "مقفلة في: {{date}}",
"subscription_needed": "مطلوب اشتراك Hydra Cloud لرؤية هذا المحتوى",
"new_achievements_unlocked": "مفتوح {{achievementCount}} انجازات جديدة من {{gameCount}} ألعاب",
"achievement_progress": "{{unlockedCount}}/{{totalCount}} الإنجازات",
"achievements_unlocked_for_game": "مفتوح {{achievementCount}} انجازات جديدة ل {{gameTitle}}"
},
"hydra_cloud": {
"subscription_tour_title": "اشتراك Hydra كلاود",
"subscribe_now": "اشترك الآن",
"cloud_saving": "الحفظ السحابي",
"cloud_achievements": "احفظ إنجازاتك على السحابة",
"animated_profile_picture": "صور شخصية متحركة",
"premium_support": "دعم متميز",
"show_and_compare_achievements": "عرض ومقارنة إنجازاتك مع المستخدمين الآخرين",
"animated_profile_banner": "لافتة الملف الشخصي المتحركة"
"close": "زر إغلاق"
}
}

View File

@@ -29,7 +29,7 @@
"need_help": "Имате нужда от помощ??"
},
"header": {
"search": "Търсене",
"search": "Търси игри",
"home": "Начало",
"catalogue": "Каталог",
"downloads": "Изтегляния",
@@ -65,7 +65,7 @@
"calculating_eta": "Калкулиране на оставащо време…",
"downloading_metadata": "Изтегляне на метадата…",
"filter": "Филтрирай repacks",
"requirements": "Системни изисквания",
"requirements": "Състемни изисквания",
"minimum": "Минимални",
"recommended": "Препоръчителни",
"paused": "Паузирано",
@@ -79,8 +79,8 @@
"add_to_library": "Добави в библиотеката",
"remove_from_library": "Премахни от библиотеката",
"no_downloads": "Няма налични изтегляния",
"play_time": "Игрално време {{amount}}",
"last_time_played": "Последно пускане {{period}}",
"play_time": "Играно {{amount}}",
"last_time_played": "Последно играно {{period}}",
"not_played_yet": "Не сте играли {{title}} все още",
"next_suggestion": "Следващо предложение",
"play": "Пускане",
@@ -110,7 +110,7 @@
"remove_from_library_description": "Това ще премахне {{game}} от Библиотеката",
"options": "Опции",
"executable_section_title": "Стартиращ файл",
"executable_section_description": "Пътят на файла, който ще се изпълни, когато се щракне върху \"Пускане\"",
"executable_section_description": "Пътят на файла, който ще се изпълни, когато се щракне върху \"Играй\"",
"downloads_secion_title": "Свалени",
"downloads_section_description": "Вижте актуализации или други версии на тази игра",
"danger_zone_section_title": "Опасна зона",
@@ -162,7 +162,7 @@
"no_download_option_info": "Няма налични данни",
"backup_deletion_failed": "Неуспешно изтриване на резервно копие",
"max_number_of_artifacts_reached": "Достигнат максимален брой резервни копия за тази игра",
"achievements_not_sync": "Постиженията не са синхронизирани",
"achievements_not_sync": "Постиженията ви не са синхронизирани",
"manage_files_description": "Управлявайте кои файлове ще бъдат архивирани и възстановени",
"select_folder": "Избери папка",
"backup_from": "Резервно копие от {{date}}",
@@ -198,7 +198,7 @@
"downloads_completed": "Приключени",
"queued": "В опашка",
"no_downloads_title": "Толкова е празно",
"no_downloads_description": "Все още не сте изтеглили нищо с Hydra, но никога не е късно да започнете...",
"no_downloads_description": "Все още не сте изтеглили нищо с Hydra, но никога не е късно да започнете..",
"checking_files": "Проверка на файлове…"
},
"settings": {
@@ -293,7 +293,7 @@
"last_time_played": "Последно играно {{period}}",
"activity": "Скорошна активност",
"library": "Библиотека",
"total_play_time": "Общо време за игра",
"total_play_time": "Общо време за игра: {{amount}}",
"no_recent_activity_title": "Хмм… няма нищо тук",
"no_recent_activity_description": "Не сте играли игри напоследък. Време е да промените това.!",
"display_name": "Показване на името",
@@ -331,7 +331,7 @@
"blocked_users": "Блокирани потребители",
"unblock": "Отблокирай",
"no_friends_added": "Не сте добавили приятели",
"pending": "Чакащи",
"pending": "Чакащо",
"no_pending_invites": "Нямате чакащи покани",
"no_blocked_users": "Нямате блокирани потребители",
"friend_code_copied": "Приятелския код е копиран",
@@ -362,13 +362,13 @@
"achievement_unlocked": "Постижението е отключено",
"user_achievements": "Постиженията на {{displayName}} ",
"your_achievements": "Вашите Постижения",
"unlocked_at": "Отключено на: {{date}}",
"unlocked_at": "Отключено на:",
"subscription_needed": "Необходим е абонамент за Hydra Cloud, за да видите това съдържание",
"new_achievements_unlocked": "Отключени {{achievementCount}} нови постижения от {{gameCount}} игра",
"achievement_progress": "{{unlockedCount}}/{{totalCount}} постижения",
"achievements_unlocked_for_game": "Отключени {{achievementCount}} нови постижения за {{gameTitle}}"
},
"hydra_cloud": {
"tour": {
"subscription_tour_title": "Hydra Cloud Абонамент",
"subscribe_now": "Абонирай се сега",
"cloud_saving": "Запазване в облака",

View File

@@ -224,7 +224,7 @@
"last_time_played": "Última partida {{period}}",
"activity": "Activitat recent",
"library": "Biblioteca",
"total_play_time": "Temps total de joc",
"total_play_time": "Temps total de joc:{{amount}}",
"no_recent_activity_title": "Hmmm… encara no res",
"no_recent_activity_description": "No has jugat a cap joc recentment. És el moment de canviar-ho!",
"display_name": "Nom de visualització",

View File

@@ -6,11 +6,7 @@
"home": {
"featured": "Doporučené",
"surprise_me": "Překvap mě",
"no_results": "Výsledek nenalezen",
"start_typing": "Začni psát pro vyhledávání...",
"hot": "Teď populární",
"weekly": "📅 Nejlepší hry týdne",
"achievements": "🏆 Hry k překonání"
"no_results": "Výsledek nenalezen"
},
"sidebar": {
"catalogue": "Katalog",
@@ -24,9 +20,7 @@
"home": "Domov",
"queued": "{{title}} (V řadě)",
"game_has_no_executable": "Hra nemá zvolen žádný spustitelný soubor",
"sign_in": "Přihlásit se",
"friends": "Přátelé",
"need_help": "Potřebujete pomoc?"
"sign_in": "Přihlásit se"
},
"header": {
"search": "Vyhledat hry",
@@ -119,54 +113,7 @@
"download_paused": "Stahování pozastaveno",
"last_downloaded_option": "Poslední stažená možnost",
"create_shortcut_success": "Zástupce vytvořen úspěšně",
"create_shortcut_error": "Chyba při pokusu vytvořit zástupce",
"nsfw_content_title": "Tahle hra obsahuje nevhodný obsah",
"nsfw_content_description": "{{title}} obsahuje obsah, který by nemusel být vhodný pro všechny věkové skupiny. Jste si jisti, že chcete pokračovat?",
"allow_nsfw_content": "Pokračovat",
"refuse_nsfw_content": "Jít zpět",
"stats": "Statistiky",
"download_count": "Stažení",
"player_count": "Aktivní hráči",
"download_error": "Tahle možnost stažení není dostupná",
"download": "Stáhnout",
"executable_path_in_use": "Spustitelný soubor již používá \"{{game}}\"",
"warning": "Varování",
"hydra_needs_to_remain_open": "Pro tohle stažení, musí Hydra zůstat otevřená až do konce stahování. Pokud Hydru zavřete dříve, postup stahování bude ztracen.",
"achievements": "Achievementy",
"achievements_count": "Achievementy {{unlockedCount}}/{{achievementsCount}}",
"cloud_save": "Uložení v cloudu",
"cloud_save_description": "Uložte si svůj postup v cloud a pokračujte v hraní na jakémkoliv zářízení",
"backups": "Zálohy",
"install_backup": "Nainstalovat",
"delete_backup": "Smazat",
"create_backup": "Vytvořit zálohu",
"last_backup_date": "Poslední záloha vytvořena {{date}}",
"no_backup_preview": "Žádné zálohy nebyly nalezeny pro tuhle hru",
"restoring_backup": "Obnovuji zálohu ({{progress}} hotovo)...",
"uploading_backup": "Nahrávání zálohy...",
"no_backups": "Nemáte zatím vytvořeny žádné zálohy pro tuto hru",
"backup_uploaded": "Záloha nahrána",
"backup_deleted": "Záloha odstraněna",
"backup_restored": "Záloha obnovena",
"see_all_achievements": "Zobrazit všechny achievementy",
"sign_in_to_see_achievements": "Musíte se přihlásit pro zobrazení achievementů",
"mapping_method_automatic": "Automaticky",
"mapping_method_manual": "Manuálně",
"mapping_method_label": "Metoda mapování",
"files_automatically_mapped": "Soubory automaticky zmapovány",
"no_backups_created": "Žádné zálohy nebyly vytvořeny pro tuto hru",
"manage_files": "Spravovat soubory",
"loading_save_preview": "Hledání uložených her...",
"wine_prefix": "Wine Prefix",
"wine_prefix_description": "Wine Prefix použit pro spuštění této hry",
"no_download_option_info": "Žádné informace nejsou dostupny",
"backup_deletion_failed": "Nepovedlo se odstranit zálohu",
"max_number_of_artifacts_reached": "Dosáhli jste maximálního počtu záloh pro tuto hru",
"achievements_not_sync": "Vaše achievementy nejsou synchronizovány",
"manage_files_description": "Spravovat, které soubory budou zálohovány a obnoveny",
"select_folder": "Vybrat složku",
"backup_from": "Zálohy z {{date}}",
"custom_backup_location_set": "Vlastní umístění záloh nastaveno"
"create_shortcut_error": "Chyba při pokusu vytvořit zástupce"
},
"activation": {
"title": "Aktivovat hydru",
@@ -242,21 +189,7 @@
"found_download_option_zero": "Nenalezena žádná možnost stahování",
"found_download_option_one": "Nalezena {{countFormatted}} možnost stahování",
"found_download_option_other": "Nalezeny {{countFormatted}} možnosti stahování",
"import": "Importovat",
"public": "Veřejné",
"private": "Soukromé",
"friends_only": "Pouze přátelé",
"privacy": "Soukromí",
"profile_visibility": "Viditelnost profilu",
"profile_visibility_description": "Vyberte si, kdo může vidět váš profil a knihovnu",
"required_field": "Toto pole je povinné",
"source_already_exists": "Tento zdroj byl již přidán",
"must_be_valid_url": "Zdroj musí být platký odkaz URL",
"blocked_users": "Zablokovaní uživatelé",
"user_unblocked": "Uživatel byl odblokován",
"enable_achievement_notifications": "Když je odemknut achievement",
"launch_minimized": "Spustit v minimalizovaném režimu",
"disable_nsfw_alert": "Deaktivovat upozornění na nevhodný obsah"
"import": "Importovat"
},
"notifications": {
"download_complete": "Stahování dokončeno",
@@ -265,9 +198,7 @@
"repack_count_one": "{{count}} repack přidán",
"repack_count_other": "{{count}} repacky přidány",
"new_update_available": "Version {{version}} je dostupná",
"restart_to_install_update": "Restartuj Hydru pro aktualizaci",
"notification_achievement_unlocked_title": "Achievement pro {{game}} byl odemknut",
"notification_achievement_unlocked_body": "{{achievement}} a dalších {{count}} byly odemknuty"
"restart_to_install_update": "Restartuj Hydru pro aktualizaci"
},
"system_tray": {
"open": "Otevřít Hydru",
@@ -293,7 +224,7 @@
"last_time_played": "Naposledy hráno {{period}}",
"activity": "Nedávná aktivita",
"library": "Knihovna",
"total_play_time": "Celkový odehraný čas",
"total_play_time": "Celkový odehraný čas: {{amount}}",
"no_recent_activity_title": "Hmmm… nic tu není",
"no_recent_activity_description": "V poslední době si nehrál žádnout hru, můžeš to ale napravit!",
"display_name": "Zobrazované jméno",
@@ -335,47 +266,6 @@
"no_pending_invites": "Nemáte žádné příchozí žádosti",
"no_blocked_users": "Nemáte nikoho zablokovaného",
"friend_code_copied": "Kód přítele zkopírován",
"undo_friendship_modal_text": "Tímto zrušíte své přátelství s {{displayName}}",
"privacy_hint": "Pro změnu toho, kdo tohle může vidět, jděte do <0>Nastavení</0>",
"locked_profile": "Tento profil je soukromý",
"image_process_failure": "Nastala chyba při zpracování obrázku",
"required_field": "Toto pole je povinné",
"displayname_min_length": "Uživatelské jméno musí být minimálně 3 znaky dlouhé",
"displayname_max_length": "Uživatelské jméno musí být maximálně 50 znaků dlouhé",
"report_profile": "Nahlásit profil",
"report_reason": "Proč nahlašujete tento profil?",
"report_description": "Přídavné informace",
"report_description_placeholder": "Přídavné informace",
"report": "Nahlásit",
"report_reason_hate": "Nenávistné projevy",
"report_reason_sexual_content": "Sexuální obsah",
"report_reason_violence": "Násilí",
"report_reason_spam": "Spam",
"report_reason_other": "Ostatní",
"profile_reported": "Profil nahlášen",
"your_friend_code": "Tvůj kód přítele:",
"upload_banner": "Nahrát banner profilu",
"uploading_banner": "Nahrávání banneru",
"background_image_updated": "Obrázek pozadí byl změněn"
},
"achievement": {
"achievement_unlocked": "Achievement odemčen",
"user_achievements": "Achievementy uživatele {{displayName}}",
"your_achievements": "Vaše achievementy",
"unlocked_at": "Odemčeno: {{date}}",
"subscription_needed": "Je vyžadováno předplatné Hydra Cloud pro zobrazení tohoto obsahu",
"new_achievements_unlocked": "Odemčeno {{achievementCount}} nových achievementů z {{gameCount}} her",
"achievement_progress": "{{unlockedCount}}/{{totalCount}} achievementů",
"achievements_unlocked_for_game": "Odemčeno {{achievementCount}} nových achievementů pro {{gameTitle}}"
},
"hydra_cloud": {
"subscription_tour_title": "Předplatné Hydra Cloud",
"subscribe_now": "Připojit se",
"cloud_saving": "Ukládání v cloudu",
"cloud_achievements": "Ukládejte vaše achievementy do cloudu",
"animated_profile_picture": "Animované profilové obrázky",
"premium_support": "Prémiová podpora",
"show_and_compare_achievements": "Zobraz a porovnej achievementy s ostatními uživateli",
"animated_profile_banner": "Animovaný banner na profilu"
"undo_friendship_modal_text": "Tímto zrušíte své přátelství s {{displayName}}"
}
}

View File

@@ -251,7 +251,7 @@
"last_time_played": "Sidst spillet {{period}}",
"activity": "Seneste aktivitet",
"library": "Bibliotek",
"total_play_time": "Samlet spiltid",
"total_play_time": "Samlet spiltid: {{amount}}",
"no_recent_activity_title": "Hmmm… ikke noget her",
"no_recent_activity_description": "Du har ikke spillet nogen spil for nyligt. Dét er det på tide at lave om på!",
"display_name": "Brugernavn",

View File

@@ -224,7 +224,7 @@
"last_time_played": "Zuletzt gespielt {{period}}",
"activity": "Letzte Aktivität",
"library": "Bibliothek",
"total_play_time": "Gesamtspielzeit",
"total_play_time": "Gesamtspielzeit: {{amount}}",
"no_recent_activity_title": "Hmmm… hier ist nichts",
"no_recent_activity_description": "Du hast in letzter Zeit keine Spiele gespielt. Es wird Zeit das zu ändern!",
"display_name": "Anzeigename",

View File

@@ -46,15 +46,8 @@
"checking_files": "Checking {{title}} files… ({{percentage}} complete)"
},
"catalogue": {
"search": "Filter…",
"developers": "Developers",
"genres": "Genres",
"tags": "Tags",
"publishers": "Publishers",
"download_sources": "Download sources",
"result_count": "{{resultCount}} results",
"filter_count": "{{filterCount}} available",
"clear_filters": "Clear {{filterCount}} selected"
"next_page": "Next page",
"previous_page": "Previous page"
},
"game_details": {
"open_download_options": "Open download options",
@@ -112,7 +105,6 @@
"open_folder": "Open folder",
"open_download_location": "See downloaded files",
"create_shortcut": "Create desktop shortcut",
"clear": "Clear",
"remove_files": "Remove files",
"remove_from_library_title": "Are you sure?",
"remove_from_library_description": "This will remove {{game}} from your library",
@@ -170,12 +162,11 @@
"no_download_option_info": "No information available",
"backup_deletion_failed": "Failed to delete backup",
"max_number_of_artifacts_reached": "Maximum number of backups reached for this game",
"achievements_not_sync": "See how to synchronize your achievements",
"achievements_not_sync": "Your achievements are not synchronized",
"manage_files_description": "Manage which files will be backed up and restored",
"select_folder": "Select folder",
"backup_from": "Backup from {{date}}",
"custom_backup_location_set": "Custom backup location set",
"no_directory_selected": "No directory selected"
"custom_backup_location_set": "Custom backup location set"
},
"activation": {
"title": "Activate Hydra",
@@ -208,11 +199,7 @@
"queued": "Queued",
"no_downloads_title": "Such empty",
"no_downloads_description": "You haven't downloaded anything with Hydra yet, but it's never too late to start.",
"checking_files": "Checking files…",
"seeding": "Seeding",
"stop_seeding": "Stop seeding",
"resume_seeding": "Resume seeding",
"options": "Manage"
"checking_files": "Checking files…"
},
"settings": {
"downloads_path": "Downloads path",
@@ -269,9 +256,7 @@
"user_unblocked": "User has been unblocked",
"enable_achievement_notifications": "When an achievement is unlocked",
"launch_minimized": "Launch Hydra minimized",
"disable_nsfw_alert": "Disable NSFW alert",
"seed_after_download_complete": "Seed after download complete",
"show_hidden_achievement_description": "Show hidden achievements description before unlocking them"
"disable_nsfw_alert": "Disable NSFW alert"
},
"notifications": {
"download_complete": "Download complete",
@@ -308,7 +293,7 @@
"last_time_played": "Last played {{period}}",
"activity": "Recent Activity",
"library": "Library",
"total_play_time": "Total playtime",
"total_play_time": "Total playtime: {{amount}}",
"no_recent_activity_title": "Hmmm… nothing here",
"no_recent_activity_description": "You haven't played any games recently. It's time to change that!",
"display_name": "Display name",
@@ -371,34 +356,19 @@
"your_friend_code": "Your friend code:",
"upload_banner": "Upload banner",
"uploading_banner": "Uploading banner…",
"background_image_updated": "Background image updated",
"stats": "Stats",
"achievements": "achievements",
"games": "Games",
"top_percentile": "Top {{percentile}}%",
"ranking_updated_weekly": "Ranking is updated weekly",
"playing": "Playing {{game}}",
"achievements_unlocked": "Achievements Unlocked",
"earned_points": "Earned points",
"show_achievements_on_profile": "Show your achievements on your profile",
"show_points_on_profile": "Show your earned points on your profile"
"background_image_updated": "Background image updated"
},
"achievement": {
"achievement_unlocked": "Achievement unlocked",
"user_achievements": "{{displayName}}'s Achievements",
"your_achievements": "Your Achievements",
"unlocked_at": "Unlocked at: {{date}}",
"unlocked_at": "Unlocked at:",
"subscription_needed": "A Hydra Cloud subscription is required to see this content",
"new_achievements_unlocked": "Unlocked {{achievementCount}} new achievements from {{gameCount}} games",
"achievement_progress": "{{unlockedCount}}/{{totalCount}} achievements",
"achievements_unlocked_for_game": "Unlocked {{achievementCount}} new achievements for {{gameTitle}}",
"hidden_achievement_tooltip": "This is a hidden achievement",
"achievement_earn_points": "Earn {{points}} points with this achievement",
"earned_points": "Earned points:",
"available_points": "Available points:",
"how_to_earn_achievements_points": "How to earn achievements points?"
"achievements_unlocked_for_game": "Unlocked {{achievementCount}} new achievements for {{gameTitle}}"
},
"hydra_cloud": {
"tour": {
"subscription_tour_title": "Hydra Cloud Subscription",
"subscribe_now": "Subscribe now",
"cloud_saving": "Cloud saving",
@@ -406,9 +376,6 @@
"animated_profile_picture": "Animated profile pictures",
"premium_support": "Premium Support",
"show_and_compare_achievements": "Show and compare your achievements to other users",
"animated_profile_banner": "Animated profile banner",
"hydra_cloud": "Hydra Cloud",
"hydra_cloud_feature_found": "You've just discovered a Hydra Cloud feature!",
"learn_more": "Learn More"
"animated_profile_banner": "Animated profile banner"
}
}

View File

@@ -46,15 +46,8 @@
"checking_files": "Verificando archivos de {{title}}… ({{percentage}} completado)"
},
"catalogue": {
"search": "Filtrar…",
"developers": "Desarrolladores",
"genres": "Géneros",
"tags": "Marcadores",
"publishers": "Distribuidoras",
"download_sources": "Fuentes de descarga",
"result_count": "{{resultCount}} resultados",
"filter_count": "{{filterCount}} disponibles",
"clear_filters": "Limpiar {{filterCount}} seleccionados"
"next_page": "Siguiente página",
"previous_page": "Pagina anterior"
},
"game_details": {
"open_download_options": "Ver opciones de descargas",
@@ -86,7 +79,7 @@
"add_to_library": "Agregar a la biblioteca",
"remove_from_library": "Eliminar de la biblioteca",
"no_downloads": "No hay descargas disponibles",
"play_time": "Has jugado {{amount}}",
"play_time": "Jugado por {{amount}}",
"last_time_played": "Jugado por última vez: {{period}}",
"not_played_yet": "Aún no has jugado a {{title}}",
"next_suggestion": "Siguiente sugerencia",
@@ -107,7 +100,7 @@
"open_screenshot": "Abrir captura {{number}}",
"download_settings": "Ajustes de descarga",
"downloader": "Método de descarga",
"select_executable": "Seleccionar",
"select_executable": "Seleccionar ejecutable",
"no_executable_selected": "No se seleccionó un ejecutable",
"open_folder": "Abrir carpeta",
"open_download_location": "Ver archivos descargados",
@@ -173,9 +166,7 @@
"manage_files_description": "Gestiona los archivos que serán respaldados y restaurados",
"select_folder": "Seleccionar carpeta",
"backup_from": "Copia de seguridad de {{date}}",
"custom_backup_location_set": "Se configuró la carpeta de copia de seguridad",
"clear": "Limpiar",
"no_directory_selected": "No se seleccionó un directório"
"custom_backup_location_set": "Se configuró la carpeta de copia de seguridad"
},
"activation": {
"title": "Activar Hydra",
@@ -263,9 +254,7 @@
"must_be_valid_url": "La fuente debe ser una URL válida.",
"blocked_users": "Usuarios bloqueados",
"user_unblocked": "El usuario ha sido desbloqueado",
"enable_achievement_notifications": "Cuando un logro se desbloquea",
"launch_minimized": "Iniciar Hydra minimizado",
"disable_nsfw_alert": "Desactivar alerta NSFW"
"enable_achievement_notifications": "Cuando un logro se desbloquea"
},
"notifications": {
"download_complete": "Descarga completada",
@@ -302,7 +291,7 @@
"last_time_played": "Última vez jugado: {{period}}",
"activity": "Actividad reciente",
"library": "Biblioteca",
"total_play_time": "Has jugado",
"total_play_time": "Total de tiempo jugado: {{amount}}",
"no_recent_activity_title": "Que raro, no hay nada por acá...",
"no_recent_activity_description": "No has jugado ningún juego recientemente, ¡vamos a cambiar eso ahora!",
"display_name": "Nombre en pantalla",
@@ -315,7 +304,7 @@
"cancel": "Cancelar",
"successfully_signed_out": "Sesión cerrada exitosamente",
"sign_out": "Cerrar sesión",
"playing_for": "Llevas jugando {{amount}}",
"playing_for": "Jugando por {{amount}}",
"sign_out_modal_text": "Tu biblioteca se ha vinculado con tu cuenta. Cuando cierres sesión, tú biblioteca ya no será visible y cualquier progreso no se guardará. ¿Continuar con el cierre de sesión?",
"add_friends": "Añadir amigos",
"add": "Añadir",
@@ -365,20 +354,17 @@
"your_friend_code": "Tu código de amigo:",
"upload_banner": "Subir un banner",
"uploading_banner": "Subiendo banner…",
"background_image_updated": "Imagen de fondo actualizada",
"playing": "Jugando {{game}}"
"background_image_updated": "Imagen de fondo actualizada"
},
"achievement": {
"achievement_unlocked": "Logro desbloqueado",
"user_achievements": "Logros de {{displayName}}",
"your_achievements": "Tus Logros",
"unlocked_at": "Desbloqueado el: {{date}}",
"subscription_needed": "Se necesita una suscripción a Hydra Cloud necesita para ver este contenido",
"new_achievements_unlocked": "Desbloqueados {{achievementCount}} nuevos logros de {{gameCount}} juegos",
"achievement_progress": "{{unlockedCount}}/{{totalCount}} logros",
"achievements_unlocked_for_game": "Se han desbloqueado {{achievementCount}} nuevos logros de {{gameTitle}}"
"unlocked_at": "Desbloqueado el:",
"subscription_needed": "Se necesita una suscripción a Hydra Cloud se necesita para ver este contenido",
"new_achievements_unlocked": "Desbloqueados {{achievementCount}} nuevos logros de {{gameCount}} juegos"
},
"hydra_cloud": {
"tour": {
"subscription_tour_title": "Suscripción Hydra Cloud",
"subscribe_now": "Suscribirse ahora",
"cloud_saving": "Guardado en la nube",

View File

@@ -290,7 +290,7 @@
"last_time_played": "Viimati mängitud {{period}}",
"activity": "Hiljutine aktiivsus",
"library": "Kogu",
"total_play_time": "Kogu mängitud aeg",
"total_play_time": "Kogu mängitud aeg: {{amount}}",
"no_recent_activity_title": "Hmmm… siin pole midagi",
"no_recent_activity_description": "Sa pole hiljuti ühtegi mängu mänginud. On aeg seda muuta!",
"display_name": "Kuvatav nimi",
@@ -359,11 +359,11 @@
"achievement_unlocked": "Saavutus avatud",
"user_achievements": "{{displayName}} saavutused",
"your_achievements": "Sinu saavutused",
"unlocked_at": "Avatud: {{date}}",
"unlocked_at": "Avatud:",
"subscription_needed": "Selle sisu nägemiseks on vaja Hydra Cloud tellimust",
"new_achievements_unlocked": "Avatud {{achievementCount}} uut saavutust {{gameCount}} mängust"
},
"hydra_cloud": {
"tour": {
"subscription_tour_title": "Hydra Cloud Tellimus",
"subscribe_now": "Telli kohe",
"cloud_saving": "Pilvesalvestus",

View File

@@ -224,7 +224,7 @@
"last_time_played": "Terakhir dimainkan {{period}}",
"activity": "Aktivitas terbaru",
"library": "Perpustakaan",
"total_play_time": "Total waktu bermain",
"total_play_time": "Total waktu bermain: {{amount}}",
"no_recent_activity_title": "Hmm… kosong di sini",
"no_recent_activity_description": "Kamu belum main game baru-baru ini. Yuk, mulai main!",
"display_name": "Nama tampilan",

View File

@@ -220,7 +220,7 @@
"last_time_played": "Соңғы ойын {{period}}",
"activity": "Соңғы әрекет",
"library": "Кітапхана",
"total_play_time": "Барлығы ойнаған",
"total_play_time": "Барлығы ойнаған: {{amount}}",
"no_recent_activity_title": "Хммм... Мұнда ештеңе жоқ",
"no_recent_activity_description": "Сіз ұзақ уақыт бойы ештеңе ойнаған жоқсыз. Мұны өзгерту керек!",
"display_name": "Көрсету аты",

View File

@@ -251,7 +251,7 @@
"last_time_played": "Sist spilt {{period}}",
"activity": "Seneste aktivitet",
"library": "Bibliotek",
"total_play_time": "Samlet spilltid",
"total_play_time": "Samlet spilltid: {{amount}}",
"no_recent_activity_title": "Hmmm… ikke noe her",
"no_recent_activity_description": "Du har ikke spilt noen spill for på det seneste. Det er det på tide at endre på!",
"display_name": "Brukernavn",

View File

@@ -158,13 +158,11 @@
"no_download_option_info": "Sem informações disponíveis",
"backup_deletion_failed": "Falha ao apagar backup",
"max_number_of_artifacts_reached": "Número máximo de backups atingido para este jogo",
"achievements_not_sync": "Veja como exibir suas conquistas no perfil",
"achievements_not_sync": "Suas conquistas não estão sincronizadas",
"backup_from": "Backup de {{date}}",
"custom_backup_location_set": "Localização customizada selecionada",
"select_folder": "Selecione a pasta",
"manage_files_description": "Gerencie quais arquivos serão feitos backup",
"clear": "Limpar",
"no_directory_selected": "Nenhum diretório selecionado"
"manage_files_description": "Gerencie quais arquivos serão feitos backup"
},
"activation": {
"title": "Ativação",
@@ -197,11 +195,7 @@
"queued": "Na fila",
"no_downloads_title": "Nada por aqui…",
"no_downloads_description": "Você ainda não baixou nada pelo Hydra, mas nunca é tarde para começar.",
"checking_files": "Verificando arquivos…",
"seeding": "Semeando",
"stop_seeding": "Parar de semear",
"resume_seeding": "Semear",
"options": "Gerenciar"
"checking_files": "Verificando arquivos…"
},
"settings": {
"downloads_path": "Diretório dos downloads",
@@ -258,9 +252,7 @@
"user_unblocked": "Usuário desbloqueado",
"enable_achievement_notifications": "Quando uma conquista é desbloqueada",
"launch_minimized": "Iniciar o Hydra minimizado",
"disable_nsfw_alert": "Desativar alerta de conteúdo inapropriado",
"seed_after_download_complete": "Semear após a conclusão do download",
"show_hidden_achievement_description": "Mostrar descrição de conquistas ocultas antes de debloqueá-las"
"disable_nsfw_alert": "Desativar alerta de conteúdo inapropriado"
},
"notifications": {
"download_complete": "Download concluído",
@@ -284,15 +276,8 @@
"instructions": "Verifique a forma correta de instalar algum deles no seu distro Linux, garantindo assim a execução normal do jogo"
},
"catalogue": {
"search": "Filtrar…",
"developers": "Desenvolvedores",
"genres": "Gêneros",
"tags": "Marcadores",
"publishers": "Distribuidoras",
"download_sources": "Fontes de download",
"result_count": "{{resultCount}} resultados",
"filter_count": "{{filterCount}} disponíveis",
"clear_filters": "Limpar {{filterCount}} selecionados"
"next_page": "Próxima página",
"previous_page": "Página anterior"
},
"modal": {
"close": "Botão de fechar"
@@ -306,7 +291,7 @@
"last_time_played": "Última sessão {{period}}",
"activity": "Atividades recentes",
"library": "Biblioteca",
"total_play_time": "Tempo total de jogo",
"total_play_time": "Tempo total de jogo: {{amount}}",
"no_recent_activity_title": "Hmmm… nada por aqui",
"no_recent_activity_description": "Parece que você não jogou nada recentemente. Que tal começar agora?",
"display_name": "Nome de exibição",
@@ -369,43 +354,26 @@
"your_friend_code": "Seu código de amigo:",
"upload_banner": "Carregar banner",
"uploading_banner": "Carregando banner…",
"background_image_updated": "Imagem de fundo salva",
"stats": "Estatísticas",
"achievements": "conquistas",
"games": "Jogos",
"ranking_updated_weekly": "O ranking é atualizado semanalmente",
"playing": "Jogando {{game}}",
"achievements_unlocked": "Conquistas desbloqueadas",
"earned_points": "Pontos ganhos",
"show_achievements_on_profile": "Exiba suas conquistas no perfil",
"show_points_on_profile": "Exiba seus pontos ganhos no perfil"
"background_image_updated": "Imagem de fundo salva"
},
"achievement": {
"achievement_unlocked": "Conquista desbloqueada",
"your_achievements": "Suas Conquistas",
"user_achievements": "Conquistas de {{displayName}}",
"unlocked_at": "Desbloqueada em: {{date}}",
"unlocked_at": "Desbloqueado em:",
"subscription_needed": "Você precisa de uma assinatura Hydra Cloud para visualizar este conteúdo",
"new_achievements_unlocked": "{{achievementCount}} novas conquistas de {{gameCount}} jogos",
"achievement_progress": "{{unlockedCount}}/{{totalCount}} conquistas",
"achievements_unlocked_for_game": "Desbloqueadas {{achievementCount}} novas conquistas em {{gameTitle}}",
"hidden_achievement_tooltip": "Está é uma conquista oculta",
"achievement_earn_points": "Ganhe {{points}} pontos com essa conquista",
"earned_points": "Pontos ganhos:",
"available_points": "Pontos disponíveis:",
"how_to_earn_achievements_points": "Como desbloquear pontos nas conquistas?"
"achievements_unlocked_for_game": "Desbloqueadas {{achievementCount}} novas conquistas em {{gameTitle}}"
},
"hydra_cloud": {
"tour": {
"subscription_tour_title": "Assinatura Hydra Cloud",
"hydra_cloud": "Hydra Cloud",
"subscribe_now": "Inscreva-se agora",
"cloud_achievements": "Salvamento de conquistas em nuvem",
"animated_profile_picture": "Fotos de perfil animadas",
"premium_support": "Suporte Premium",
"show_and_compare_achievements": "Exiba e compare suas conquistas com outros usuários",
"animated_profile_banner": "Banner animado no perfil",
"cloud_saving": "Saves de jogos em nuvem",
"hydra_cloud_feature_found": "Você descobriu uma funcionalidade Hydra Cloud!",
"learn_more": "Saiba mais"
"cloud_saving": "Saves de jogos em nuvem"
}
}

View File

@@ -287,7 +287,7 @@
"last_time_played": "Última sessão {{period}}",
"activity": "Atividade recente",
"library": "Biblioteca",
"total_play_time": "Tempo total de jogo",
"total_play_time": "Tempo total de jogo: {{amount}}",
"no_recent_activity_title": "Hmmm… não há nada por aqui",
"no_recent_activity_description": "Parece que não jogaste nada recentemente. Que tal começar agora?",
"display_name": "Nome de apresentação",
@@ -356,11 +356,11 @@
"achievement_unlocked": "Conquista desbloqueada",
"your_achievements": "As tuas Conquistas",
"user_achievements": "Conquistas de {{displayName}}",
"unlocked_at": "Desbloqueada em: {{date}}",
"unlocked_at": "Desbloqueada em:",
"subscription_needed": "Precisas de uma subscrição Hydra Cloud para visualizar este conteúdo",
"new_achievements_unlocked": "{{achievementCount}} novas conquistas de {{gameCount}} jogos"
},
"hydra_cloud": {
"tour": {
"subscription_tour_title": "Subscrição Hydra Cloud",
"subscribe_now": "Subscreve agora",
"cloud_achievements": "Gravação de conquistas na nuvem",

View File

@@ -4,13 +4,12 @@
"successfully_signed_in": "Успешный вход"
},
"home": {
"featured": "Рекомендации",
"featured": "Рекомендованное",
"surprise_me": "Удиви меня",
"no_results": "Ничего не найдено",
"hot": "Сейчас в топе",
"start_typing": "Начинаю вводить текст для поиска...",
"weekly": "📅 Лучшие игры недели",
"achievements": "🏆 Игры, в которых нужно победить"
"weekly": "📅 Лучшие игры недели"
},
"sidebar": {
"catalogue": "Каталог",
@@ -20,7 +19,7 @@
"downloading_metadata": "{{title}} (Загрузка метаданных…)",
"paused": "{{title}} (Приостановлено)",
"downloading": "{{title}} ({{percentage}} - Загрузка…)",
"filter": "Поиск",
"filter": "Фильтр библиотеки",
"home": "Главная",
"queued": "{{title}} (В очереди)",
"game_has_no_executable": "Файл запуска игры не выбран",
@@ -46,21 +45,14 @@
"checking_files": "Проверка файлов {{title}}… ({{percentage}} завершено)"
},
"catalogue": {
"search": "Фильтр…",
"developers": "Разработчики",
"genres": "Жанры",
"tags": "Маркеры",
"publishers": "Издательства",
"download_sources": "Источники загрузки",
"result_count": "{{resultCount}} результатов",
"filter_count": "{{filterCount}} доступных",
"clear_filters": "Очистить {{filterCount}} выбранных"
"next_page": "Следующая страница",
"previous_page": "Предыдущая страница"
},
"game_details": {
"open_download_options": "Открыть источники",
"download_options_zero": "Нет источников",
"download_options_one": "{{count}} источник",
"download_options_other": "{{count}} источников",
"open_download_options": "Открыть варианты загрузки",
"download_options_zero": "Нет вариантов загрузки",
"download_options_one": "{{count}} вариант загрузки",
"download_options_other": "{{count}} вариантов загрузки",
"updated_at": "Обновлено {{updated_at}}",
"install": "Установить",
"resume": "Возобновить",
@@ -71,7 +63,7 @@
"eta": "Окончание {{eta}}",
"calculating_eta": "Подсчёт оставшегося времени…",
"downloading_metadata": "Загрузка метаданных…",
"filter": "Поиск репаков",
"filter": "Фильтр репаков",
"requirements": "Системные требования",
"minimum": "Минимальные",
"recommended": "Рекомендуемые",
@@ -85,7 +77,7 @@
"accuracy": "точность {{accuracy}}%",
"add_to_library": "Добавить в библиотеку",
"remove_from_library": "Удалить из библиотеки",
"no_downloads": "Нет доступных источников",
"no_downloads": "Нет доступных загрузок",
"play_time": "Сыграно {{amount}}",
"last_time_played": "Последний запуск {{period}}",
"not_played_yet": "Вы ещё не играли в {{title}}",
@@ -99,7 +91,7 @@
"select_folder_hint": "Чтобы изменить папку загрузок по умолчанию, откройте <0>Настройки</0>",
"download_now": "Загрузить сейчас",
"no_shop_details": "Не удалось получить описание",
"download_options": "Источники",
"download_options": "Вариантов загрузки",
"download_path": "Путь для загрузок",
"previous_screenshot": "Предыдущий скриншот",
"next_screenshot": "Следующий скриншот",
@@ -112,7 +104,6 @@
"open_folder": "Открыть папку",
"open_download_location": "Просмотреть папку загрузок",
"create_shortcut": "Создать ярлык на рабочем столе",
"clear": "Очистить",
"remove_files": "Удалить файлы",
"remove_from_library_title": "Вы уверены?",
"remove_from_library_description": "{{game}} будет удалена из вашей библиотеки.",
@@ -122,60 +113,22 @@
"downloads_secion_title": "Загрузки",
"downloads_section_description": "Проверить наличие обновлений или других версий игры",
"danger_zone_section_title": "Опасная зона",
"danger_zone_section_description": "Вы можете удалить эту игру из вашей библиотеки или файлы скачанные из Hydra",
"danger_zone_section_description": "Удалить эту игру из вашей библиотеки или файлы скачанные Hydra",
"download_in_progress": "Идёт загрузка",
"download_paused": "Загрузка приостановлена",
"last_downloaded_option": "Последний вариант загрузки",
"create_shortcut_success": "Ярлык создан",
"create_shortcut_error": "Не удалось создать ярлык",
"allow_nsfw_content": "Продолжить",
"allow_nsfw_content": "Продолжать",
"download": "Скачать",
"download_count": "Загрузки",
"download_error": "Этот вариант загрузки недоступен",
"executable_path_in_use": "Исполняемый файл уже используется \"{{game}}\"",
"nsfw_content_description": "{{title}} содержит контент, который может не подходить для всех возрастов. \nВы уверены, что хотите продолжить?",
"nsfw_content_title": "Эта игра содержит неприемлемый контент",
"refuse_nsfw_content": "Назад",
"stats": "Статистика",
"player_count": "Активные игроки",
"warning": "Внимание:",
"hydra_needs_to_remain_open": "Для этой загрузки Hydra должна оставаться открытой до завершения. Если Hydra закроется до завершения, вы потеряете прогресс.",
"achievements": "Достижения",
"achievements_count": "Достижения {{unlockedCount}}/{{achievementsCount}}",
"cloud_save": "Облачное сохранение",
"cloud_save_description": "Сохраняйте ваш прогресс в облаке и продолжайте играть на любом устройстве",
"backups": "Резервные копии",
"install_backup": "Установить",
"delete_backup": "Удалить",
"create_backup": "Создать новую резервную копию",
"last_backup_date": "Последняя резервная копия от {{date}}",
"no_backup_preview": "Сохранения для этого заголовка не найдены",
"restoring_backup": "Восстановление резервной копии ({{progress}} завершено)…",
"uploading_backup": "Загрузка резервной копии…",
"no_backups": "Вы еще не создали резервных копий для этой игры",
"backup_uploaded": "Резервная копия загружена",
"backup_deleted": "Резервная копия удалена",
"backup_restored": "Резервная копия восстановлена",
"see_all_achievements": "Просмотреть все достижения",
"sign_in_to_see_achievements": "Войдите, чтобы увидеть достижения",
"mapping_method_automatic": "Автоматическая",
"mapping_method_manual": "Ручная",
"mapping_method_label": "Метод сопоставления",
"files_automatically_mapped": "Файлы автоматически сопоставлены",
"no_backups_created": "Для этой игры не создано резервных копий",
"manage_files": "Управление файлами",
"loading_save_preview": "Поиск сохранений…",
"wine_prefix": "Префикс Wine",
"wine_prefix_description": "Префикс Wine, используемый для запуска этой игры",
"no_download_option_info": "Информация недоступна",
"backup_deletion_failed": "Не удалось удалить резервную копию",
"max_number_of_artifacts_reached": "Достигнуто максимальное количество резервных копий для этой игры",
"achievements_not_sync": "Ваши достижения не синхронизированы",
"manage_files_description": "Управляйте файлами, которые будут сохраняться и восстанавливаться",
"select_folder": "Выбрать папку",
"backup_from": "Резервная копия от {{date}}",
"custom_backup_location_set": "Установлено настраиваемое местоположение резервной копии",
"no_directory_selected": "Не выбран каталог"
"refuse_nsfw_content": "Возвращаться",
"stats": "Статистика"
},
"activation": {
"title": "Активировать Hydra",
@@ -194,7 +147,7 @@
"completed": "Завершено",
"removed": "Не скачано",
"cancel": "Отмена",
"filter": "Поиск загруженных игр",
"filter": "Фильтр загруженных игр",
"remove": "Удалить",
"downloading_metadata": "Загрузка метаданных…",
"deleting": "Удаление установщика…",
@@ -208,24 +161,17 @@
"queued": "В очереди",
"no_downloads_title": "Здесь так пусто...",
"no_downloads_description": "Вы ещё ничего не скачали через Hydra, но никогда не поздно начать.",
"checking_files": "Проверка файлов…",
"seeding": "Раздача",
"stop_seeding": "Остановить раздачу",
"resume_seeding": "Продолжить раздачу",
"options": "Управлять"
"checking_files": "Проверка файлов…"
},
"settings": {
"downloads_path": "Путь загрузок",
"change": "Изменить",
"notifications": "Уведомления",
"enable_download_notifications": "По завершении загрузки",
"enable_achievement_notifications": "Когда достижение разблокировано",
"enable_repack_list_notifications": "При добавлении нового репака",
"real_debrid_api_token_label": "Real-Debrid API-токен",
"quit_app_instead_hiding": "Закрывать приложение вместо сворачивания в трей",
"launch_with_system": "Запускать Hydra вместе с системой",
"launch_minimized": "Запустить Hydra в свернутом виде",
"disable_nsfw_alert": "Отключить предупреждение о непристойном контенте",
"general": "Основные",
"behavior": "Поведение",
"download_sources": "Источники загрузки",
@@ -250,7 +196,7 @@
"add_download_source_description": "Вставьте ссылку на .json-файл",
"download_source_up_to_date": "Обновлён",
"download_source_errored": "Ошибка",
"sync_download_sources": "Обновить источники",
"sync_download_sources": "Синхронизировать источники",
"removed_download_source": "Источник загрузок удален",
"added_download_source": "Источник загрузок добавлен",
"download_sources_synced": "Все источники загрузок синхронизированы",
@@ -260,18 +206,16 @@
"found_download_option_other": "Найдено {{countFormatted}} вариантов загрузки",
"import": "Импортировать",
"blocked_users": "Заблокированные пользователи",
"friends_only": "Только для друзей",
"friends_only": "Только друзья",
"must_be_valid_url": "Источник должен быть действительным URL-адресом.",
"privacy": "Конфиденциальность",
"private": "Частный",
"profile_visibility": "Видимость профиля",
"profile_visibility_description": "Выберите, кто может видеть ваш профиль и библиотеку",
"public": "Публичный",
"public": "Общественный",
"required_field": "Это поле обязательно к заполнению",
"source_already_exists": "Этот источник уже добавлен",
"user_unblocked": "Пользователь разблокирован",
"seed_after_download_complete": "Раздавать после завершения загрузки",
"show_hidden_achievement_description": "Показывать описание скрытых достижений перед их получением"
"user_unblocked": "Пользователь разблокирован"
},
"notifications": {
"download_complete": "Загрузка завершена",
@@ -279,17 +223,15 @@
"repack_list_updated": "Список репаков обновлен",
"repack_count_one": "{{count}} репак добавлен",
"repack_count_other": "{{count}} репаков добавлено",
"new_update_available": "Доступна новая версия {{version}}",
"restart_to_install_update": "Перезапустите Hydra для установки обновления",
"notification_achievement_unlocked_title": "Достижение разблокировано для {{game}}",
"notification_achievement_unlocked_body": "были разблокированы {{achievement}} и другие {{count}}"
"new_update_available": "Доступна версия {{version}}",
"restart_to_install_update": "Перезапустите Hydra для установки обновления"
},
"system_tray": {
"open": "Открыть Hydra",
"quit": "Выйти"
},
"game_card": {
"no_downloads": "Нет доступных источников"
"no_downloads": "Нет доступных загрузок"
},
"binary_not_found_modal": {
"title": "Программы не установлены",
@@ -308,7 +250,7 @@
"last_time_played": "Последняя игра {{period}}",
"activity": "Недавняя активность",
"library": "Библиотека",
"total_play_time": "Всего сыграно",
"total_play_time": "Всего сыграно: {{amount}}",
"no_recent_activity_title": "Хммм... Тут ничего нет",
"no_recent_activity_description": "Вы давно ни во что не играли. Пора это изменить!",
"display_name": "Отображаемое имя",
@@ -367,46 +309,6 @@
"report_reason_spam": "Спам",
"report_reason_violence": "Насилие",
"required_field": "Это поле обязательно к заполнению",
"undo_friendship_modal_text": "Это отменит вашу дружбу с {{displayName}}.",
"your_friend_code": "Код вашего друга:",
"upload_banner": "Загрузить баннер",
"uploading_banner": "Загрузка баннера...",
"background_image_updated": "Фоновое изображение обновлено",
"stats": "Статистика",
"games": "Игры",
"top_percentile": "Топ {{percentile}}%",
"ranking_updated_weekly": "Рейтинг обновляется еженедельно",
"playing": "Играет в {{game}}",
"achievements_unlocked": "Достижения разблокированы",
"show_achievements_on_profile": "Покажите свои достижения в профиле",
"show_points_on_profile": "Показывать заработанные очки в своем профиле"
},
"achievement": {
"achievement_unlocked": "Достижение разблокировано",
"user_achievements": "Достижения {{displayName}}",
"your_achievements": "Ваши достижения",
"unlocked_at": "Разблокировано: {{date}}",
"subscription_needed": "Для просмотра этого содержимого необходима подписка на Hydra Cloud",
"new_achievements_unlocked": "Разблокировано {{achievementCount}} новых достижений из {{gameCount}} игр",
"achievement_progress": "{{unlockedCount}}/{{totalCount}} достижений",
"achievements_unlocked_for_game": "Разблокировано {{achievementCount}} новых достижений для {{gameTitle}}",
"hidden_achievement_tooltip": "Это скрытое достижение",
"achievement_earn_points": "Заработайте {{points}} очков с этим достижением",
"earned_points": "Заработано очков:",
"available_points": "Доступные очки:",
"how_to_earn_achievements_points": "Как заработать очки достижений?"
},
"hydra_cloud": {
"subscription_tour_title": "Подписка Hydra Cloud",
"subscribe_now": "Подпишитесь прямо сейчас",
"cloud_saving": "Сохранение в облаке",
"cloud_achievements": "Сохраняйте свои достижения в облаке",
"animated_profile_picture": "Анимированные фотографии профиля",
"premium_support": "Премиальная поддержка",
"show_and_compare_achievements": "Показывайте и сравнивайте свои достижения с достижениями других пользователей",
"animated_profile_banner": "Анимированный баннер профиля",
"hydra_cloud": "Hydra Cloud",
"hydra_cloud_feature_found": "Вы только что открыли для себя функцию Hydra Cloud!",
"learn_more": "Подробнее"
"undo_friendship_modal_text": "Это отменит вашу дружбу с {{displayName}}."
}
}

View File

@@ -231,7 +231,7 @@
"sign_out_modal_text": "Ваша бібліотека пов'язана з поточним обліковим записом. При виході з системи ваша бібліотека буде недоступною, і прогрес не буде збережено. Продовжити вихід?",
"sign_out_modal_title": "Ви впевнені?",
"successfully_signed_out": "Успішний вихід з акаунту",
"total_play_time": "Всього зіграно",
"total_play_time": "Всього зіграно: {{amount}}",
"try_again": "Будь ласка, попробуйте ще раз"
}
}

View File

@@ -290,7 +290,7 @@
"last_time_played": "上次游玩时间 {{period}}",
"activity": "近期活动",
"library": "库",
"total_play_time": "总游戏时长",
"total_play_time": "总游戏时长: {{amount}}",
"no_recent_activity_title": "Emmm… 这里暂时啥都没有",
"no_recent_activity_description": "你最近没玩过任何游戏。是时候做出改变了!",
"display_name": "昵称",
@@ -359,11 +359,11 @@
"achievement_unlocked": "成就已解锁",
"user_achievements": "{{displayName}}的成就",
"your_achievements": "你的成就",
"unlocked_at": "解锁于: {{date}}",
"unlocked_at": "解锁于:",
"subscription_needed": "需要订阅 Hydra Cloud 才能看到此内容",
"new_achievements_unlocked": "从 {{gameCount}} 游戏中解锁 {{achievementCount}} 新成就"
},
"hydra_cloud": {
"tour": {
"subscription_tour_title": "Hydra 云订阅",
"subscribe_now": "现在订购",
"cloud_saving": "云存档",

View File

@@ -1,8 +1,10 @@
import { DataSource } from "typeorm";
import {
DownloadQueue,
DownloadSource,
Game,
GameShopCache,
Repack,
UserPreferences,
UserAuth,
GameAchievement,
@@ -15,10 +17,12 @@ export const dataSource = new DataSource({
type: "better-sqlite3",
entities: [
Game,
Repack,
UserAuth,
UserPreferences,
UserSubscription,
GameShopCache,
DownloadSource,
DownloadQueue,
GameAchievement,
],

View File

@@ -0,0 +1,41 @@
import {
Entity,
PrimaryGeneratedColumn,
Column,
CreateDateColumn,
UpdateDateColumn,
OneToMany,
} from "typeorm";
import type { Repack } from "./repack.entity";
import { DownloadSourceStatus } from "@shared";
@Entity("download_source")
export class DownloadSource {
@PrimaryGeneratedColumn()
id: number;
@Column("text", { nullable: true, unique: true })
url: string;
@Column("text")
name: string;
@Column("text", { nullable: true })
etag: string | null;
@Column("int", { default: 0 })
downloadCount: number;
@Column("text", { default: DownloadSourceStatus.UpToDate })
status: DownloadSourceStatus;
@OneToMany("Repack", "downloadSource", { cascade: true })
repacks: Repack[];
@CreateDateColumn()
createdAt: Date;
@UpdateDateColumn()
updatedAt: Date;
}

View File

@@ -5,7 +5,9 @@ import {
CreateDateColumn,
UpdateDateColumn,
OneToOne,
JoinColumn,
} from "typeorm";
import { Repack } from "./repack.entity";
import type { GameShop, GameStatus } from "@types";
import { Downloader } from "@shared";
@@ -70,15 +72,19 @@ export class Game {
@Column("text", { nullable: true })
uri: string | null;
/**
* @deprecated
*/
@OneToOne("Repack", "game", { nullable: true })
@JoinColumn()
repack: Repack;
@OneToOne("DownloadQueue", "game")
downloadQueue: DownloadQueue;
@Column("boolean", { default: false })
isDeleted: boolean;
@Column("boolean", { default: false })
shouldSeed: boolean;
@CreateDateColumn()
createdAt: Date;

View File

@@ -1,8 +1,10 @@
export * from "./game.entity";
export * from "./repack.entity";
export * from "./user-auth.entity";
export * from "./user-preferences.entity";
export * from "./user-subscription.entity";
export * from "./game-shop-cache.entity";
export * from "./game.entity";
export * from "./game-achievements.entity";
export * from "./download-source.entity";
export * from "./download-queue.entity";

View File

@@ -0,0 +1,45 @@
import {
Entity,
PrimaryGeneratedColumn,
Column,
CreateDateColumn,
UpdateDateColumn,
ManyToOne,
} from "typeorm";
import { DownloadSource } from "./download-source.entity";
@Entity("repack")
export class Repack {
@PrimaryGeneratedColumn()
id: number;
@Column("text", { unique: true })
title: string;
/**
* @deprecated Use uris instead
*/
@Column("text", { unique: true })
magnet: string;
@Column("text")
repacker: string;
@Column("text")
fileSize: string;
@Column("datetime")
uploadDate: Date | string;
@ManyToOne(() => DownloadSource, { nullable: true, onDelete: "CASCADE" })
downloadSource: DownloadSource;
@Column("text", { default: "[]" })
uris: string;
@CreateDateColumn()
createdAt: Date;
@UpdateDateColumn()
updatedAt: Date;
}

View File

@@ -41,12 +41,6 @@ export class UserPreferences {
@Column("boolean", { default: false })
disableNsfwAlert: boolean;
@Column("boolean", { default: true })
seedAfterDownloadComplete: boolean;
@Column("boolean", { default: false })
showHiddenAchievementsDescription: boolean;
@CreateDateColumn()
createdAt: Date;

View File

@@ -1,8 +1,12 @@
import { registerEvent } from "../register-event";
import { DownloadManager, HydraApi, gamesPlaytime } from "@main/services";
import {
DownloadManager,
HydraApi,
PythonInstance,
gamesPlaytime,
} from "@main/services";
import { dataSource } from "@main/data-source";
import { DownloadQueue, Game, UserAuth, UserSubscription } from "@main/entity";
import { PythonRPC } from "@main/services/python-rpc";
const signOut = async (_event: Electron.IpcMainInvokeEvent) => {
const databaseOperations = dataSource
@@ -28,7 +32,7 @@ const signOut = async (_event: Electron.IpcMainInvokeEvent) => {
DownloadManager.cancelDownload();
/* Disconnects libtorrent */
PythonRPC.kill();
PythonInstance.killTorrent();
HydraApi.handleSignOut();

View File

@@ -1,6 +1,9 @@
import type { GameShop } from "@types";
import { registerEvent } from "../register-event";
import { HydraApi } from "@main/services";
import { CatalogueCategory } from "@shared";
import { CatalogueCategory, steamUrlBuilder } from "@shared";
import { steamGamesWorker } from "@main/workers";
const getCatalogue = async (
_event: Electron.IpcMainInvokeEvent,
@@ -11,11 +14,26 @@ const getCatalogue = async (
skip: "0",
});
return HydraApi.get(
const response = await HydraApi.get<{ objectId: string; shop: GameShop }[]>(
`/catalogue/${category}?${params.toString()}`,
{},
{ needsAuth: false }
);
return Promise.all(
response.map(async (game) => {
const steamGame = await steamGamesWorker.run(Number(game.objectId), {
name: "getById",
});
return {
title: steamGame.name,
shop: game.shop,
cover: steamUrlBuilder.library(game.objectId),
objectId: game.objectId,
};
})
);
};
registerEvent("getCatalogue", getCatalogue);

View File

@@ -1,10 +0,0 @@
import { HydraApi } from "@main/services";
import { registerEvent } from "../register-event";
const getDevelopers = async (_event: Electron.IpcMainInvokeEvent) => {
return HydraApi.get<string[]>(`/catalogue/developers`, null, {
needsAuth: false,
});
};
registerEvent("getDevelopers", getDevelopers);

View File

@@ -0,0 +1,29 @@
import type { CatalogueEntry } from "@types";
import { registerEvent } from "../register-event";
import { HydraApi } from "@main/services";
import { steamUrlBuilder } from "@shared";
const getGames = async (
_event: Electron.IpcMainInvokeEvent,
take = 12,
skip = 0
): Promise<CatalogueEntry[]> => {
const searchParams = new URLSearchParams({
take: take.toString(),
skip: skip.toString(),
});
const games = await HydraApi.get<CatalogueEntry[]>(
`/games/catalogue?${searchParams.toString()}`,
undefined,
{ needsAuth: false }
);
return games.map((game) => ({
...game,
cover: steamUrlBuilder.library(game.objectId),
}));
};
registerEvent("getGames", getGames);

View File

@@ -1,21 +1,23 @@
import type { GameShop, HowLongToBeatCategory } from "@types";
import type { HowLongToBeatCategory } from "@types";
import { getHowLongToBeatGame, searchHowLongToBeat } from "@main/services";
import { registerEvent } from "../register-event";
import { HydraApi } from "@main/services";
import { formatName } from "@shared";
const getHowLongToBeat = async (
_event: Electron.IpcMainInvokeEvent,
objectId: string,
shop: GameShop
title: string
): Promise<HowLongToBeatCategory[] | null> => {
const params = new URLSearchParams({
objectId,
shop,
const response = await searchHowLongToBeat(title);
const game = response.data.find((game) => {
return formatName(game.game_name) === formatName(title);
});
return HydraApi.get(`/games/how-long-to-beat?${params.toString()}`, null, {
needsAuth: false,
});
if (!game) return null;
const howLongToBeat = await getHowLongToBeatGame(String(game.game_id));
return howLongToBeat;
};
registerEvent("getHowLongToBeat", getHowLongToBeat);

View File

@@ -1,10 +0,0 @@
import { HydraApi } from "@main/services";
import { registerEvent } from "../register-event";
const getPublishers = async (_event: Electron.IpcMainInvokeEvent) => {
return HydraApi.get<string[]>(`/catalogue/publishers`, null, {
needsAuth: false,
});
};
registerEvent("getPublishers", getPublishers);

View File

@@ -1,18 +1,23 @@
import type { CatalogueSearchPayload } from "@types";
import { registerEvent } from "../register-event";
import { convertSteamGameToCatalogueEntry } from "../helpers/search-games";
import type { CatalogueEntry } from "@types";
import { HydraApi } from "@main/services";
const searchGames = async (
const searchGamesEvent = async (
_event: Electron.IpcMainInvokeEvent,
payload: CatalogueSearchPayload,
take: number,
skip: number
) => {
return HydraApi.post(
"/catalogue/search",
{ ...payload, take, skip },
{ needsAuth: false }
);
query: string
): Promise<CatalogueEntry[]> => {
const games = await HydraApi.get<
{ objectId: string; title: string; shop: string }[]
>("/games/search", { title: query, take: 12, skip: 0 }, { needsAuth: false });
return games.map((game) => {
return convertSteamGameToCatalogueEntry({
id: Number(game.objectId),
name: game.title,
clientIcon: null,
});
});
};
registerEvent("searchGames", searchGames);
registerEvent("searchGames", searchGamesEvent);

View File

@@ -1,7 +1,6 @@
import { HydraApi } from "@main/services";
import { registerEvent } from "../register-event";
import type { GameArtifact, GameShop } from "@types";
import { SubscriptionRequiredError } from "@shared";
const getGameArtifacts = async (
_event: Electron.IpcMainInvokeEvent,
@@ -14,16 +13,8 @@ const getGameArtifacts = async (
});
return HydraApi.get<GameArtifact[]>(
`/profile/games/artifacts?${params.toString()}`,
{},
{ needsSubscription: true }
).catch((err) => {
if (err instanceof SubscriptionRequiredError) {
return [];
}
throw err;
});
`/profile/games/artifacts?${params.toString()}`
);
};
registerEvent("getGameArtifacts", getGameArtifacts);

View File

@@ -89,7 +89,7 @@ const uploadSaveGame = async (
"Content-Type": "application/tar",
},
onUploadProgress: (progressEvent) => {
logger.log(progressEvent);
console.log(progressEvent);
},
});

View File

@@ -0,0 +1,9 @@
import { registerEvent } from "../register-event";
import { knexClient } from "@main/knex-client";
const deleteDownloadSource = async (
_event: Electron.IpcMainInvokeEvent,
id: number
) => knexClient("download_source").where({ id }).delete();
registerEvent("deleteDownloadSource", deleteDownloadSource);

View File

@@ -0,0 +1,7 @@
import { registerEvent } from "../register-event";
import { knexClient } from "@main/knex-client";
const getDownloadSources = async (_event: Electron.IpcMainInvokeEvent) =>
knexClient.select("*").from("download_source");
registerEvent("getDownloadSources", getDownloadSources);

View File

@@ -1,17 +0,0 @@
import { HydraApi } from "@main/services";
import { registerEvent } from "../register-event";
const putDownloadSource = async (
_event: Electron.IpcMainInvokeEvent,
objectIds: string[]
) => {
return HydraApi.put<{ fingerprint: string }>(
"/download-sources",
{
objectIds,
},
{ needsAuth: false }
);
};
registerEvent("putDownloadSource", putDownloadSource);

View File

@@ -0,0 +1,31 @@
import type { GameShop, CatalogueEntry, SteamGame } from "@types";
import { steamGamesWorker } from "@main/workers";
import { steamUrlBuilder } from "@shared";
export interface SearchGamesArgs {
query?: string;
take?: number;
skip?: number;
}
export const convertSteamGameToCatalogueEntry = (
game: SteamGame
): CatalogueEntry => ({
objectId: String(game.id),
title: game.name,
shop: "steam" as GameShop,
cover: steamUrlBuilder.library(String(game.id)),
});
export const getSteamGameById = async (
objectId: string
): Promise<CatalogueEntry | null> => {
const steamGame = await steamGamesWorker.run(Number(objectId), {
name: "getById",
});
if (!steamGame) return null;
return convertSteamGameToCatalogueEntry(steamGame);
};

View File

@@ -1,15 +1,14 @@
import { appVersion, defaultDownloadsPath, isStaging } from "@main/constants";
import { appVersion, defaultDownloadsPath } from "@main/constants";
import { ipcMain } from "electron";
import "./catalogue/get-catalogue";
import "./catalogue/get-game-shop-details";
import "./catalogue/get-games";
import "./catalogue/get-how-long-to-beat";
import "./catalogue/get-random-game";
import "./catalogue/search-games";
import "./catalogue/get-game-stats";
import "./catalogue/get-trending-games";
import "./catalogue/get-publishers";
import "./catalogue/get-developers";
import "./hardware/get-disk-free-space";
import "./library/add-game-to-library";
import "./library/create-game-shortcut";
@@ -33,15 +32,14 @@ import "./torrenting/cancel-game-download";
import "./torrenting/pause-game-download";
import "./torrenting/resume-game-download";
import "./torrenting/start-game-download";
import "./torrenting/pause-game-seed";
import "./torrenting/resume-game-seed";
import "./user-preferences/get-user-preferences";
import "./user-preferences/update-user-preferences";
import "./user-preferences/auto-launch";
import "./autoupdater/check-for-updates";
import "./autoupdater/restart-and-install-update";
import "./user-preferences/authenticate-real-debrid";
import "./download-sources/put-download-source";
import "./download-sources/delete-download-source";
import "./download-sources/get-download-sources";
import "./auth/sign-out";
import "./auth/open-auth-window";
import "./auth/get-session-hash";
@@ -74,6 +72,5 @@ import "./misc/show-item-in-folder";
ipcMain.handle("ping", () => "pong");
ipcMain.handle("getVersion", () => appVersion);
ipcMain.handle("isStaging", () => isStaging);
ipcMain.handle("isPortableVersion", () => isPortableVersion());
ipcMain.handle("getDefaultDownloadsPath", () => defaultDownloadsPath);

View File

@@ -1,10 +1,8 @@
import { gameRepository } from "@main/repository";
import { registerEvent } from "../register-event";
import { logger } from "@main/services";
import { PythonInstance, logger } from "@main/services";
import sudo from "sudo-prompt";
import { app } from "electron";
import { PythonRPC } from "@main/services/python-rpc";
import { ProcessPayload } from "@main/services/download/types";
const getKillCommand = (pid: number) => {
if (process.platform == "win32") {
@@ -18,10 +16,7 @@ const closeGame = async (
_event: Electron.IpcMainInvokeEvent,
gameId: number
) => {
const processes =
(await PythonRPC.rpc.get<ProcessPayload[] | null>("/process-list")).data ||
[];
const processes = await PythonInstance.getProcessList();
const game = await gameRepository.findOne({
where: { id: gameId, isDeleted: false },
});
@@ -29,11 +24,7 @@ const closeGame = async (
if (!game) return;
const gameProcess = processes.find((runningProcess) => {
if (process.platform === "linux") {
return runningProcess.name === game.executablePath?.split("/").at(-1);
} else {
return runningProcess.exe === game.executablePath;
}
return runningProcess.exe === game.executablePath;
});
if (gameProcess) {

View File

@@ -5,9 +5,9 @@ import { registerEvent } from "../register-event";
const selectGameWinePrefix = async (
_event: Electron.IpcMainInvokeEvent,
id: number,
winePrefixPath: string | null
winePrefixPath: string
) => {
return gameRepository.update({ id }, { winePrefixPath: winePrefixPath });
return gameRepository.update({ id }, { winePrefixPath });
};
registerEvent("selectGameWinePrefix", selectGameWinePrefix);

View File

@@ -6,18 +6,14 @@ import { parseExecutablePath } from "../helpers/parse-executable-path";
const updateExecutablePath = async (
_event: Electron.IpcMainInvokeEvent,
id: number,
executablePath: string | null
executablePath: string
) => {
const parsedPath = executablePath
? parseExecutablePath(executablePath)
: null;
return gameRepository.update(
{
id,
},
{
executablePath: parsedPath,
executablePath: parseExecutablePath(executablePath),
}
);
};

View File

@@ -1,16 +1,11 @@
import { registerEvent } from "../register-event";
import { PythonRPC } from "@main/services/python-rpc";
import { PythonInstance } from "@main/services";
const processProfileImage = async (
_event: Electron.IpcMainInvokeEvent,
path: string
) => {
return PythonRPC.rpc
.post<{
imagePath: string;
mimeType: string;
}>("/profile-image", { image_path: path })
.then((response) => response.data);
return PythonInstance.processProfileImage(path);
};
registerEvent("processProfileImage", processProfileImage);

View File

@@ -1,17 +0,0 @@
import { registerEvent } from "../register-event";
import { DownloadManager } from "@main/services";
import { gameRepository } from "@main/repository";
const pauseGameSeed = async (
_event: Electron.IpcMainInvokeEvent,
gameId: number
) => {
await gameRepository.update(gameId, {
status: "complete",
shouldSeed: false,
});
await DownloadManager.pauseSeeding(gameId);
};
registerEvent("pauseGameSeed", pauseGameSeed);

View File

@@ -1,29 +0,0 @@
import { registerEvent } from "../register-event";
import { gameRepository } from "../../repository";
import { DownloadManager } from "@main/services";
import { Downloader } from "@shared";
const resumeGameSeed = async (
_event: Electron.IpcMainInvokeEvent,
gameId: number
) => {
const game = await gameRepository.findOne({
where: {
id: gameId,
isDeleted: false,
downloader: Downloader.Torrent,
progress: 1,
},
});
if (!game) return;
await gameRepository.update(gameId, {
status: "seeding",
shouldSeed: true,
});
await DownloadManager.resumeSeeding(game);
};
registerEvent("resumeGameSeed", resumeGameSeed);

View File

@@ -1,6 +1,7 @@
import { registerEvent } from "../register-event";
import parseTorrent from "parse-torrent";
import type { StartGameDownloadPayload } from "@types";
import { DownloadManager, HydraApi } from "@main/services";
import { DownloadManager, HydraApi, logger } from "@main/services";
import { Not } from "typeorm";
import { steamGamesWorker } from "@main/workers";
@@ -8,6 +9,7 @@ import { createGame } from "@main/services/library-sync";
import { steamUrlBuilder } from "@shared";
import { dataSource } from "@main/data-source";
import { DownloadQueue, Game } from "@main/entity";
import { HydraAnalytics } from "@main/services/hydra-analytics";
const startGameDownload = async (
_event: Electron.IpcMainInvokeEvent,
@@ -76,23 +78,35 @@ const startGameDownload = async (
},
});
createGame(updatedGame!).catch(() => {});
HydraApi.post(
"/games/download",
{
objectId: updatedGame!.objectID,
shop: updatedGame!.shop,
},
{ needsAuth: false }
).catch((err) => {
logger.error("Failed to create game download", err);
});
if (uri.startsWith("magnet:")) {
try {
const { infoHash } = await parseTorrent(payload.uri);
if (infoHash) {
HydraAnalytics.postDownload(infoHash).catch(() => {});
}
} catch (err) {
logger.error("Failed to parse torrent", err);
}
}
await DownloadManager.cancelDownload(updatedGame!.id);
await DownloadManager.startDownload(updatedGame!);
await downloadQueueRepository.delete({ game: { id: updatedGame!.id } });
await downloadQueueRepository.insert({ game: { id: updatedGame!.id } });
await Promise.all([
createGame(updatedGame!).catch(() => {}),
HydraApi.post(
"/games/download",
{
objectId: updatedGame!.objectID,
shop: updatedGame!.shop,
},
{ needsAuth: false }
).catch(() => {}),
]);
});
};

View File

@@ -1,4 +1,4 @@
import { RealDebridClient } from "@main/services/download/real-debrid";
import { RealDebridClient } from "@main/services/real-debrid";
import { registerEvent } from "../register-event";
const authenticateRealDebrid = async (

View File

@@ -13,9 +13,6 @@ const getComparedUnlockedAchievements = async (
where: { id: 1 },
});
const showHiddenAchievementsDescription =
userPreferences?.showHiddenAchievementsDescription || false;
return HydraApi.get<ComparedAchievements>(
`/users/${userId}/games/achievements/compare`,
{
@@ -24,35 +21,15 @@ const getComparedUnlockedAchievements = async (
language: userPreferences?.language || "en",
}
).then((achievements) => {
const sortedAchievements = achievements.achievements
.sort((a, b) => {
if (a.targetStat.unlocked && !b.targetStat.unlocked) return -1;
if (!a.targetStat.unlocked && b.targetStat.unlocked) return 1;
if (a.targetStat.unlocked && b.targetStat.unlocked) {
return b.targetStat.unlockTime! - a.targetStat.unlockTime!;
}
const sortedAchievements = achievements.achievements.sort((a, b) => {
if (a.targetStat.unlocked && !b.targetStat.unlocked) return -1;
if (!a.targetStat.unlocked && b.targetStat.unlocked) return 1;
if (a.targetStat.unlocked && b.targetStat.unlocked) {
return b.targetStat.unlockTime! - a.targetStat.unlockTime!;
}
return Number(a.hidden) - Number(b.hidden);
})
.map((achievement) => {
if (!achievement.hidden) return achievement;
if (!achievement.ownerStat) {
return {
...achievement,
description: "",
};
}
if (!showHiddenAchievementsDescription && achievement.hidden) {
return {
...achievement,
description: "",
};
}
return achievement;
});
return Number(a.hidden) - Number(b.hidden);
});
return {
...achievements,

View File

@@ -1,9 +1,6 @@
import type { GameShop, UnlockedAchievement, UserAchievement } from "@types";
import { registerEvent } from "../register-event";
import {
gameAchievementRepository,
userPreferencesRepository,
} from "@main/repository";
import { gameAchievementRepository } from "@main/repository";
import { getGameAchievementData } from "@main/services/achievements/get-game-achievement-data";
export const getUnlockedAchievements = async (
@@ -15,17 +12,10 @@ export const getUnlockedAchievements = async (
where: { objectId, shop },
});
const userPreferences = await userPreferencesRepository.findOne({
where: { id: 1 },
});
const showHiddenAchievementsDescription =
userPreferences?.showHiddenAchievementsDescription || false;
const achievementsData = await getGameAchievementData(
objectId,
shop,
useCachedData ? cachedAchievements : null
useCachedData
);
const unlockedAchievements = JSON.parse(
@@ -60,10 +50,6 @@ export const getUnlockedAchievements = async (
unlocked: false,
unlockTime: null,
icongray: icongray,
description:
!achievementData.hidden || showHiddenAchievementsDescription
? achievementData.description
: undefined,
} as UserAchievement;
})
.sort((a, b) => {

View File

@@ -11,7 +11,7 @@ const getSteamGame = async (objectId: string) => {
});
return {
title: steamGame.name as string,
title: steamGame.name,
iconUrl: steamUrlBuilder.icon(objectId, steamGame.clientIcon),
};
} catch (err) {
@@ -67,25 +67,8 @@ const getUser = async (
}
}
const friends = await Promise.all(
profile.friends.map(async (friend) => {
if (!friend.currentGame) return friend;
const currentGame = await getSteamGame(friend.currentGame.objectId);
return {
...friend,
currentGame: {
...friend.currentGame,
...currentGame,
},
};
})
);
return {
...profile,
friends,
libraryGames,
recentGames,
};

View File

@@ -5,14 +5,12 @@ import path from "node:path";
import url from "node:url";
import fs from "node:fs";
import { electronApp, optimizer } from "@electron-toolkit/utils";
import { logger, WindowManager } from "@main/services";
import { logger, PythonInstance, WindowManager } from "@main/services";
import { dataSource } from "@main/data-source";
import resources from "@locales";
import { userPreferencesRepository } from "@main/repository";
import { knexClient, migrationConfig } from "./knex-client";
import { databaseDirectory } from "./constants";
import { PythonRPC } from "./services/python-rpc";
import { Aria2 } from "./services/aria2";
const { autoUpdater } = updater;
@@ -148,8 +146,7 @@ app.on("window-all-closed", () => {
app.on("before-quit", () => {
/* Disconnects libtorrent */
PythonRPC.kill();
Aria2.kill();
PythonInstance.kill();
});
app.on("activate", () => {

View File

@@ -13,10 +13,6 @@ import { AddBackgroundImageUrl } from "./migrations/20241016100249_add_backgroun
import { AddWinePrefixToGame } from "./migrations/20241019081648_add_wine_prefix_to_game";
import { AddStartMinimizedColumn } from "./migrations/20241030171454_add_start_minimized_column";
import { AddDisableNsfwAlertColumn } from "./migrations/20241106053733_add_disable_nsfw_alert_column";
import { AddShouldSeedColumn } from "./migrations/20241108200154_add_should_seed_colum";
import { AddSeedAfterDownloadColumn } from "./migrations/20241108201806_add_seed_after_download";
import { AddHiddenAchievementDescriptionColumn } from "./migrations/20241216140633_add_hidden_achievement_description_column ";
export type HydraMigration = Knex.Migration & { name: string };
class MigrationSource implements Knex.MigrationSource<HydraMigration> {
@@ -34,9 +30,6 @@ class MigrationSource implements Knex.MigrationSource<HydraMigration> {
AddWinePrefixToGame,
AddStartMinimizedColumn,
AddDisableNsfwAlertColumn,
AddShouldSeedColumn,
AddSeedAfterDownloadColumn,
AddHiddenAchievementDescriptionColumn,
]);
}
getMigrationName(migration: HydraMigration): string {

View File

@@ -1,22 +1,21 @@
import { DownloadManager, Ludusavi, startMainLoop } from "./services";
import {
DownloadManager,
Ludusavi,
PythonInstance,
startMainLoop,
} from "./services";
import {
downloadQueueRepository,
gameRepository,
userPreferencesRepository,
} from "./repository";
import { UserPreferences } from "./entity";
import { RealDebridClient } from "./services/download/real-debrid";
import { RealDebridClient } from "./services/real-debrid";
import { HydraApi } from "./services/hydra-api";
import { uploadGamesBatch } from "./services/library-sync";
import { Aria2 } from "./services/aria2";
import { Downloader } from "@shared";
import { IsNull, Not } from "typeorm";
const loadState = async (userPreferences: UserPreferences | null) => {
import("./events");
Aria2.spawn();
if (userPreferences?.realDebridApiToken) {
RealDebridClient.authorize(userPreferences?.realDebridApiToken);
}
@@ -36,16 +35,11 @@ const loadState = async (userPreferences: UserPreferences | null) => {
},
});
const seedList = await gameRepository.find({
where: {
shouldSeed: true,
downloader: Downloader.Torrent,
progress: 1,
uri: Not(IsNull()),
},
});
await DownloadManager.startRPC(nextQueueItem?.game, seedList);
if (nextQueueItem?.game.status === "active") {
DownloadManager.startDownload(nextQueueItem.game);
} else {
PythonInstance.spawn();
}
startMainLoop();
};

View File

@@ -1,17 +0,0 @@
import type { HydraMigration } from "@main/knex-client";
import type { Knex } from "knex";
export const AddShouldSeedColumn: HydraMigration = {
name: "AddShouldSeedColumn",
up: (knex: Knex) => {
return knex.schema.alterTable("game", (table) => {
return table.boolean("shouldSeed").notNullable().defaultTo(true);
});
},
down: async (knex: Knex) => {
return knex.schema.alterTable("game", (table) => {
return table.dropColumn("shouldSeed");
});
},
};

View File

@@ -1,20 +0,0 @@
import type { HydraMigration } from "@main/knex-client";
import type { Knex } from "knex";
export const AddSeedAfterDownloadColumn: HydraMigration = {
name: "AddSeedAfterDownloadColumn",
up: (knex: Knex) => {
return knex.schema.alterTable("user_preferences", (table) => {
return table
.boolean("seedAfterDownloadComplete")
.notNullable()
.defaultTo(true);
});
},
down: async (knex: Knex) => {
return knex.schema.alterTable("user_preferences", (table) => {
return table.dropColumn("seedAfterDownloadComplete");
});
},
};

View File

@@ -1,20 +0,0 @@
import type { HydraMigration } from "@main/knex-client";
import type { Knex } from "knex";
export const AddHiddenAchievementDescriptionColumn: HydraMigration = {
name: "AddHiddenAchievementDescriptionColumn",
up: (knex: Knex) => {
return knex.schema.alterTable("user_preferences", (table) => {
return table
.boolean("showHiddenAchievementsDescription")
.notNullable()
.defaultTo(0);
});
},
down: async (knex: Knex) => {
return knex.schema.alterTable("user_preferences", (table) => {
return table.dropColumn("showHiddenAchievementsDescription");
});
},
};

View File

@@ -1,8 +1,10 @@
import { dataSource } from "./data-source";
import {
DownloadQueue,
DownloadSource,
Game,
GameShopCache,
Repack,
UserPreferences,
UserAuth,
GameAchievement,
@@ -11,11 +13,16 @@ import {
export const gameRepository = dataSource.getRepository(Game);
export const repackRepository = dataSource.getRepository(Repack);
export const userPreferencesRepository =
dataSource.getRepository(UserPreferences);
export const gameShopCacheRepository = dataSource.getRepository(GameShopCache);
export const downloadSourceRepository =
dataSource.getRepository(DownloadSource);
export const downloadQueueRepository = dataSource.getRepository(DownloadQueue);
export const userAuthRepository = dataSource.getRepository(UserAuth);

View File

@@ -0,0 +1,40 @@
import path from "node:path";
import fs from "node:fs";
import { getSteamGameClientIcon, logger } from "@main/services";
import { chunk } from "lodash-es";
import { seedsPath } from "@main/constants";
import type { SteamGame } from "@types";
const steamGamesPath = path.join(seedsPath, "steam-games.json");
const steamGames = JSON.parse(
fs.readFileSync(steamGamesPath, "utf-8")
) as SteamGame[];
const chunks = chunk(steamGames, 1500);
for (const chunk of chunks) {
await Promise.all(
chunk.map(async (steamGame) => {
if (steamGame.clientIcon) return;
const index = steamGames.findIndex((game) => game.id === steamGame.id);
try {
const clientIcon = await getSteamGameClientIcon(String(steamGame.id));
steamGames[index].clientIcon = clientIcon;
logger.log("info", `Set ${steamGame.name} client icon`);
} catch (err) {
steamGames[index].clientIcon = null;
logger.log("info", `Could not set icon for ${steamGame.name}`);
}
})
);
fs.writeFileSync(steamGamesPath, JSON.stringify(steamGames));
logger.log("info", "Updated steam games");
}

View File

@@ -236,28 +236,24 @@ export class AchievementWatcherManager {
};
public static preSearchAchievements = async () => {
try {
const newAchievementsCount =
process.platform === "win32"
? await this.preSearchAchievementsWindows()
: await this.preSearchAchievementsWithWine();
const newAchievementsCount =
process.platform === "win32"
? await this.preSearchAchievementsWindows()
: await this.preSearchAchievementsWithWine();
const totalNewGamesWithAchievements = newAchievementsCount.filter(
(achievements) => achievements
).length;
const totalNewAchievements = newAchievementsCount.reduce(
(acc, val) => acc + val,
0
const totalNewGamesWithAchievements = newAchievementsCount.filter(
(achievements) => achievements
).length;
const totalNewAchievements = newAchievementsCount.reduce(
(acc, val) => acc + val,
0
);
if (totalNewAchievements > 0) {
publishCombinedNewAchievementNotification(
totalNewAchievements,
totalNewGamesWithAchievements
);
if (totalNewAchievements > 0) {
publishCombinedNewAchievementNotification(
totalNewAchievements,
totalNewGamesWithAchievements
);
}
} catch (err) {
achievementsLogger.error("Error on preSearchAchievements", err);
}
this.hasFinishedMergingWithRemote = true;

View File

@@ -6,15 +6,20 @@ import { HydraApi } from "../hydra-api";
import type { AchievementData, GameShop } from "@types";
import { UserNotLoggedInError } from "@shared";
import { logger } from "../logger";
import { GameAchievement } from "@main/entity";
export const getGameAchievementData = async (
objectId: string,
shop: GameShop,
cachedAchievements: GameAchievement | null
useCachedData: boolean
) => {
if (cachedAchievements && cachedAchievements.achievements) {
return JSON.parse(cachedAchievements.achievements) as AchievementData[];
if (useCachedData) {
const cachedAchievements = await gameAchievementRepository.findOne({
where: { objectId, shop },
});
if (cachedAchievements && cachedAchievements.achievements) {
return JSON.parse(cachedAchievements.achievements) as AchievementData[];
}
}
const userPreferences = await userPreferencesRepository.findOne({

View File

@@ -7,9 +7,8 @@ import { WindowManager } from "../window-manager";
import { HydraApi } from "../hydra-api";
import { getUnlockedAchievements } from "@main/events/user/get-unlocked-achievements";
import { Game } from "@main/entity";
import { publishNewAchievementNotification } from "../notifications";
import { SubscriptionRequiredError } from "@shared";
import { achievementsLogger } from "../logger";
import { publishNewAchievementNotification } from "../notifications";
const saveAchievementsOnLocal = async (
objectId: string,
@@ -121,14 +120,10 @@ export const mergeAchievements = async (
}
if (game.remoteId) {
await HydraApi.put(
"/profile/games/achievements",
{
id: game.remoteId,
achievements: mergedLocalAchievements,
},
{ needsSubscription: !newAchievements.length }
)
await HydraApi.put("/profile/games/achievements", {
id: game.remoteId,
achievements: mergedLocalAchievements,
})
.then((response) => {
return saveAchievementsOnLocal(
response.objectId,
@@ -138,13 +133,7 @@ export const mergeAchievements = async (
);
})
.catch((err) => {
if (err! instanceof SubscriptionRequiredError) {
achievementsLogger.log(
"Achievements not synchronized on API due to lack of subscription",
game.objectID,
game.title
);
}
achievementsLogger.error(err);
return saveAchievementsOnLocal(
game.objectID,

View File

@@ -9,134 +9,144 @@ export const parseAchievementFile = (
): UnlockedAchievement[] => {
if (!existsSync(filePath)) return [];
try {
if (type == Cracker.codex) {
const parsed = iniParse(filePath);
return processDefault(parsed);
}
if (type == Cracker.rune) {
const parsed = iniParse(filePath);
return processDefault(parsed);
}
if (type === Cracker.onlineFix) {
const parsed = iniParse(filePath);
return processOnlineFix(parsed);
}
if (type === Cracker.goldberg) {
const parsed = jsonParse(filePath);
return processGoldberg(parsed);
}
if (type == Cracker.userstats) {
const parsed = iniParse(filePath);
return processUserStats(parsed);
}
if (type == Cracker.rld) {
const parsed = iniParse(filePath);
return processRld(parsed);
}
if (type === Cracker.skidrow) {
const parsed = iniParse(filePath);
return processSkidrow(parsed);
}
if (type === Cracker._3dm) {
const parsed = iniParse(filePath);
return process3DM(parsed);
}
if (type === Cracker.flt) {
const achievements = readdirSync(filePath);
return achievements.map((achievement) => {
return {
name: achievement,
unlockTime: Date.now(),
};
});
}
if (type === Cracker.creamAPI) {
const parsed = iniParse(filePath);
return processCreamAPI(parsed);
}
if (type === Cracker.empress) {
const parsed = jsonParse(filePath);
return processGoldberg(parsed);
}
if (type === Cracker.razor1911) {
return processRazor1911(filePath);
}
achievementsLogger.log(
`Unprocessed ${type} achievements found on ${filePath}`
);
return [];
} catch (err) {
achievementsLogger.error(`Error parsing ${type} - ${filePath}`, err);
return [];
if (type == Cracker.codex) {
const parsed = iniParse(filePath);
return processDefault(parsed);
}
if (type == Cracker.rune) {
const parsed = iniParse(filePath);
return processDefault(parsed);
}
if (type === Cracker.onlineFix) {
const parsed = iniParse(filePath);
return processOnlineFix(parsed);
}
if (type === Cracker.goldberg) {
const parsed = jsonParse(filePath);
return processGoldberg(parsed);
}
if (type == Cracker.userstats) {
const parsed = iniParse(filePath);
return processUserStats(parsed);
}
if (type == Cracker.rld) {
const parsed = iniParse(filePath);
return processRld(parsed);
}
if (type === Cracker.skidrow) {
const parsed = iniParse(filePath);
return processSkidrow(parsed);
}
if (type === Cracker._3dm) {
const parsed = iniParse(filePath);
return process3DM(parsed);
}
if (type === Cracker.flt) {
const achievements = readdirSync(filePath);
return achievements.map((achievement) => {
return {
name: achievement,
unlockTime: Date.now(),
};
});
}
if (type === Cracker.creamAPI) {
const parsed = iniParse(filePath);
return processCreamAPI(parsed);
}
if (type === Cracker.empress) {
const parsed = jsonParse(filePath);
return processGoldberg(parsed);
}
if (type === Cracker.razor1911) {
return processRazor1911(filePath);
}
achievementsLogger.log(
`Unprocessed ${type} achievements found on ${filePath}`
);
return [];
};
const iniParse = (filePath: string) => {
const fileContent = readFileSync(filePath, "utf-8");
try {
const fileContent = readFileSync(filePath, "utf-8");
const lines =
fileContent.charCodeAt(0) === 0xfeff
? fileContent.slice(1).split(/[\r\n]+/)
: fileContent.split(/[\r\n]+/);
const lines =
fileContent.charCodeAt(0) === 0xfeff
? fileContent.slice(1).split(/[\r\n]+/)
: fileContent.split(/[\r\n]+/);
let objectName = "";
const object: Record<string, Record<string, string | number>> = {};
let objectName = "";
const object: Record<string, Record<string, string | number>> = {};
for (const line of lines) {
if (line.startsWith("###") || !line.length) continue;
for (const line of lines) {
if (line.startsWith("###") || !line.length) continue;
if (line.startsWith("[") && line.endsWith("]")) {
objectName = line.slice(1, -1);
object[objectName] = {};
} else {
const [name, ...value] = line.split("=");
object[objectName][name.trim()] = value.join("=").trim();
if (line.startsWith("[") && line.endsWith("]")) {
objectName = line.slice(1, -1);
object[objectName] = {};
} else {
const [name, ...value] = line.split("=");
object[objectName][name.trim()] = value.join("=").trim();
}
}
}
return object;
return object;
} catch (err) {
achievementsLogger.error(`Error parsing ${filePath}`, err);
return {};
}
};
const jsonParse = (filePath: string) => {
return JSON.parse(readFileSync(filePath, "utf-8"));
try {
return JSON.parse(readFileSync(filePath, "utf-8"));
} catch (err) {
achievementsLogger.error(`Error parsing ${filePath}`, err);
return {};
}
};
const processRazor1911 = (filePath: string): UnlockedAchievement[] => {
const fileContent = readFileSync(filePath, "utf-8");
try {
const fileContent = readFileSync(filePath, "utf-8");
const lines =
fileContent.charCodeAt(0) === 0xfeff
? fileContent.slice(1).split(/[\r\n]+/)
: fileContent.split(/[\r\n]+/);
const lines =
fileContent.charCodeAt(0) === 0xfeff
? fileContent.slice(1).split(/[\r\n]+/)
: fileContent.split(/[\r\n]+/);
const achievements: UnlockedAchievement[] = [];
for (const line of lines) {
if (!line.length) continue;
const achievements: UnlockedAchievement[] = [];
for (const line of lines) {
if (!line.length) continue;
const [name, unlocked, unlockTime] = line.split(" ");
if (unlocked === "1") {
achievements.push({
name,
unlockTime: Number(unlockTime) * 1000,
});
const [name, unlocked, unlockTime] = line.split(" ");
if (unlocked === "1") {
achievements.push({
name,
unlockTime: Number(unlockTime) * 1000,
});
}
}
}
return achievements;
return achievements;
} catch (err) {
achievementsLogger.error(`Error processing ${filePath}`, err);
return [];
}
};
const processOnlineFix = (unlockedAchievements: any): UnlockedAchievement[] => {

View File

@@ -1,30 +0,0 @@
import path from "node:path";
import cp from "node:child_process";
import { app } from "electron";
export const startAria2 = () => {};
export class Aria2 {
private static process: cp.ChildProcess | null = null;
public static spawn() {
const binaryPath = app.isPackaged
? path.join(process.resourcesPath, "aria2", "aria2c")
: path.join(__dirname, "..", "..", "aria2", "aria2c");
this.process = cp.spawn(
binaryPath,
[
"--enable-rpc",
"--rpc-listen-all",
"--file-allocation=none",
"--allow-overwrite=true",
],
{ stdio: "inherit", windowsHide: true }
);
}
public static kill() {
this.process?.kill();
}
}

View File

@@ -1,116 +1,39 @@
import { Game } from "@main/entity";
import { Downloader } from "@shared";
import { PythonInstance } from "./python-instance";
import { WindowManager } from "../window-manager";
import {
downloadQueueRepository,
gameRepository,
userPreferencesRepository,
} from "@main/repository";
import { downloadQueueRepository, gameRepository } from "@main/repository";
import { publishDownloadCompleteNotification } from "../notifications";
import { RealDebridDownloader } from "./real-debrid-downloader";
import type { DownloadProgress } from "@types";
import { GofileApi, QiwiApi } from "../hosters";
import { PythonRPC } from "../python-rpc";
import {
LibtorrentPayload,
LibtorrentStatus,
PauseDownloadPayload,
} from "./types";
import { calculateETA, getDirSize } from "./helpers";
import { QueryDeepPartialEntity } from "typeorm/query-builder/QueryPartialEntity";
import { RealDebridClient } from "./real-debrid";
import path from "path";
import { logger } from "../logger";
import { GenericHttpDownloader } from "./generic-http-downloader";
export class DownloadManager {
private static currentDownloader: Downloader | null = null;
private static downloadingGameId: number | null = null;
public static async startRPC(game?: Game, initialSeeding?: Game[]) {
PythonRPC.spawn(
game?.status === "active"
? await this.getDownloadPayload(game).catch(() => undefined)
: undefined,
initialSeeding?.map((game) => ({
game_id: game.id,
url: game.uri!,
save_path: game.downloadPath!,
}))
);
this.downloadingGameId = game?.id ?? null;
}
private static async getDownloadStatus() {
const response = await PythonRPC.rpc.get<LibtorrentPayload | null>(
"/status"
);
if (response.data === null || !this.downloadingGameId) return null;
const gameId = this.downloadingGameId;
try {
const {
progress,
numPeers,
numSeeds,
downloadSpeed,
bytesDownloaded,
fileSize,
folderName,
status,
} = response.data;
const isDownloadingMetadata =
status === LibtorrentStatus.DownloadingMetadata;
const isCheckingFiles = status === LibtorrentStatus.CheckingFiles;
if (!isDownloadingMetadata && !isCheckingFiles) {
const update: QueryDeepPartialEntity<Game> = {
bytesDownloaded,
fileSize,
progress,
status: "active",
};
await gameRepository.update(
{ id: gameId },
{
...update,
folderName,
}
);
}
return {
numPeers,
numSeeds,
downloadSpeed,
timeRemaining: calculateETA(fileSize, bytesDownloaded, downloadSpeed),
isDownloadingMetadata,
isCheckingFiles,
progress,
gameId,
} as DownloadProgress;
} catch (err) {
return null;
}
}
public static async watchDownloads() {
const status = await this.getDownloadStatus();
let status: DownloadProgress | null = null;
if (this.currentDownloader === Downloader.Torrent) {
status = await PythonInstance.getStatus();
} else if (this.currentDownloader === Downloader.RealDebrid) {
status = await RealDebridDownloader.getStatus();
} else {
status = await GenericHttpDownloader.getStatus();
}
if (status) {
const { gameId, progress } = status;
const game = await gameRepository.findOne({
where: { id: gameId, isDeleted: false },
});
const userPreferences = await userPreferencesRepository.findOneBy({
id: 1,
});
if (WindowManager.mainWindow && game) {
WindowManager.mainWindow.setProgressBar(progress === 1 ? -1 : progress);
WindowManager.mainWindow.webContents.send(
"on-download-progress",
JSON.parse(
@@ -121,27 +44,12 @@ export class DownloadManager {
)
);
}
if (progress === 1 && game) {
publishDownloadCompleteNotification(game);
if (
userPreferences?.seedAfterDownloadComplete &&
game.downloader === Downloader.Torrent
) {
gameRepository.update(
{ id: gameId },
{ status: "seeding", shouldSeed: true }
);
} else {
gameRepository.update(
{ id: gameId },
{ status: "complete", shouldSeed: false }
);
this.cancelDownload(gameId);
}
await downloadQueueRepository.delete({ game });
const [nextQueueItem] = await downloadQueueRepository.find({
order: {
id: "DESC",
@@ -150,61 +58,25 @@ export class DownloadManager {
game: true,
},
});
if (nextQueueItem) {
this.resumeDownload(nextQueueItem.game);
} else {
this.downloadingGameId = -1;
}
}
}
}
public static async getSeedStatus() {
const seedStatus = await PythonRPC.rpc
.get<LibtorrentPayload[] | []>("/seed-status")
.then((res) => res.data);
if (!seedStatus.length) return;
logger.log(seedStatus);
seedStatus.forEach(async (status) => {
const game = await gameRepository.findOne({
where: { id: status.gameId },
});
if (!game) return;
const totalSize = await getDirSize(
path.join(game.downloadPath!, status.folderName)
);
if (totalSize < status.fileSize) {
await this.cancelDownload(game.id);
await gameRepository.update(game.id, {
status: "paused",
shouldSeed: false,
progress: totalSize / status.fileSize,
});
WindowManager.mainWindow?.webContents.send("on-hard-delete");
}
});
WindowManager.mainWindow?.webContents.send("on-seeding-status", seedStatus);
}
static async pauseDownload() {
await PythonRPC.rpc
.post("/action", {
action: "pause",
game_id: this.downloadingGameId,
} as PauseDownloadPayload)
.catch(() => {});
if (this.currentDownloader === Downloader.Torrent) {
await PythonInstance.pauseDownload();
} else if (this.currentDownloader === Downloader.RealDebrid) {
await RealDebridDownloader.pauseDownload();
} else {
await GenericHttpDownloader.pauseDownload();
}
WindowManager.mainWindow?.setProgressBar(-1);
this.currentDownloader = null;
this.downloadingGameId = null;
}
@@ -213,35 +85,20 @@ export class DownloadManager {
}
static async cancelDownload(gameId = this.downloadingGameId!) {
await PythonRPC.rpc.post("/action", {
action: "cancel",
game_id: gameId,
});
if (this.currentDownloader === Downloader.Torrent) {
PythonInstance.cancelDownload(gameId);
} else if (this.currentDownloader === Downloader.RealDebrid) {
RealDebridDownloader.cancelDownload(gameId);
} else {
GenericHttpDownloader.cancelDownload(gameId);
}
WindowManager.mainWindow?.setProgressBar(-1);
if (gameId === this.downloadingGameId) {
this.downloadingGameId = null;
}
this.currentDownloader = null;
this.downloadingGameId = null;
}
static async resumeSeeding(game: Game) {
await PythonRPC.rpc.post("/action", {
action: "resume_seeding",
game_id: game.id,
url: game.uri,
save_path: game.downloadPath,
});
}
static async pauseSeeding(gameId: number) {
await PythonRPC.rpc.post("/action", {
action: "pause_seeding",
game_id: gameId,
});
}
private static async getDownloadPayload(game: Game) {
static async startDownload(game: Game) {
switch (game.downloader) {
case Downloader.Gofile: {
const id = game!.uri!.split("/").pop();
@@ -249,59 +106,34 @@ export class DownloadManager {
const token = await GofileApi.authorize();
const downloadLink = await GofileApi.getDownloadLink(id!);
return {
action: "start",
game_id: game.id,
url: downloadLink,
save_path: game.downloadPath!,
header: `Cookie: accountToken=${token}`,
};
GenericHttpDownloader.startDownload(game, downloadLink, {
Cookie: `accountToken=${token}`,
});
break;
}
case Downloader.PixelDrain: {
const id = game!.uri!.split("/").pop();
return {
action: "start",
game_id: game.id,
url: `https://pixeldrain.com/api/file/${id}?download`,
save_path: game.downloadPath!,
};
await GenericHttpDownloader.startDownload(
game,
`https://pixeldrain.com/api/file/${id}?download`
);
break;
}
case Downloader.Qiwi: {
const downloadUrl = await QiwiApi.getDownloadUrl(game.uri!);
return {
action: "start",
game_id: game.id,
url: downloadUrl,
save_path: game.downloadPath!,
};
await GenericHttpDownloader.startDownload(game, downloadUrl);
break;
}
case Downloader.Torrent:
return {
action: "start",
game_id: game.id,
url: game.uri!,
save_path: game.downloadPath!,
};
case Downloader.RealDebrid: {
const downloadUrl = await RealDebridClient.getDownloadUrl(game.uri!);
return {
action: "start",
game_id: game.id,
url: downloadUrl!,
save_path: game.downloadPath!,
};
}
PythonInstance.startDownload(game);
break;
case Downloader.RealDebrid:
RealDebridDownloader.startDownload(game);
}
}
static async startDownload(game: Game) {
const payload = await this.getDownloadPayload(game);
await PythonRPC.rpc.post("/action", payload);
this.currentDownloader = game.downloader;
this.downloadingGameId = game.id;
}
}

View File

@@ -0,0 +1,109 @@
import { Game } from "@main/entity";
import { gameRepository } from "@main/repository";
import { calculateETA } from "./helpers";
import { DownloadProgress } from "@types";
import { HttpDownload } from "./http-download";
export class GenericHttpDownloader {
public static downloads = new Map<number, HttpDownload>();
public static downloadingGame: Game | null = null;
public static async getStatus() {
if (this.downloadingGame) {
const download = this.downloads.get(this.downloadingGame.id)!;
const status = download.getStatus();
if (status) {
const progress =
Number(status.completedLength) / Number(status.totalLength);
await gameRepository.update(
{ id: this.downloadingGame!.id },
{
bytesDownloaded: Number(status.completedLength),
fileSize: Number(status.totalLength),
progress,
status: "active",
folderName: status.folderName,
}
);
const result = {
numPeers: 0,
numSeeds: 0,
downloadSpeed: status.downloadSpeed,
timeRemaining: calculateETA(
status.totalLength,
status.completedLength,
status.downloadSpeed
),
isDownloadingMetadata: false,
isCheckingFiles: false,
progress,
gameId: this.downloadingGame!.id,
} as DownloadProgress;
if (progress === 1) {
this.downloads.delete(this.downloadingGame.id);
this.downloadingGame = null;
}
return result;
}
}
return null;
}
static async pauseDownload() {
if (this.downloadingGame) {
const httpDownload = this.downloads.get(this.downloadingGame!.id!);
if (httpDownload) {
await httpDownload.pauseDownload();
}
this.downloadingGame = null;
}
}
static async startDownload(
game: Game,
downloadUrl: string,
headers?: Record<string, string>
) {
this.downloadingGame = game;
if (this.downloads.has(game.id)) {
await this.resumeDownload(game.id!);
return;
}
const httpDownload = new HttpDownload(
game.downloadPath!,
downloadUrl,
headers
);
httpDownload.startDownload();
this.downloads.set(game.id!, httpDownload);
}
static async cancelDownload(gameId: number) {
const httpDownload = this.downloads.get(gameId);
if (httpDownload) {
await httpDownload.cancelDownload();
this.downloads.delete(gameId);
}
}
static async resumeDownload(gameId: number) {
const httpDownload = this.downloads.get(gameId);
if (httpDownload) {
await httpDownload.resumeDownload();
}
}
}

Some files were not shown because too many files have changed in this diff Show More