Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: Pazdikan/dbd-xp-farm
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 2.3.0
Choose a base ref
...
head repository: Pazdikan/dbd-xp-farm
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
Loading
Binary file added .github/overlay.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added .github/webserver.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
screenshot.png
last_game_xp.png
last_game_bp.png
dbdAfk/
config.ini
log.txt


# Byte-compiled / optimized / DLL files
__pycache__/
132 changes: 132 additions & 0 deletions GUIDE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,132 @@

# DBD XP Farm Installation Guide

Welcome to the DBD-XP-Farm installation guide! Follow these steps carefully to set up the application and avoid common pitfalls. ✨

---

## Prerequisites

Before proceeding, ensure the following:

1. **Python Version**: Make sure you are using python version 3.12.* The script will not work on any other version. After installing 3.12 please make sure, it's added to system enviroment variables. Restart your terminal or Windows, and run the python --version command again.

```bash
python --version
```

2. **Graphics Card Requirements**: Make sure your GPU supports CUDA. [Click here to download CUDA](https://developer.nvidia.com/cuda-downloads).

- This is the only thing you have to install by yourself.

3. **System Requirements**: Ensure your PC can run Dead by Daylight smoothly without the script. This is important because the script uses screen reading (takes lots of screenshots) to determine what's happening in game.

- Note: The screenshots do not take up your storage, they exist temporarly in RAM.

---

## Installation Steps

### Option 1: Download ZIP File (Recommended)

> [!NOTE]
> Why is this recommended instead of git? Well the versioned releases are ~~always~~ *usually* working. Sometimes I may push some unfinished or untested code into the main branch, making the script broken.
> [!IMPORTANT]
> You will have to download new versions manually.
1. **Download the Repository as a ZIP File**:
- Go to the GitHub repository and click on the **Code** button.
- Select **Download ZIP**.

2. **Extract the ZIP File**:
- Extract the contents of the ZIP file to a folder of your choice.

3. **Run the Setup Script**:
- Navigate to the extracted folder.
- Run `setup.bat` to install the required dependencies.

4. **Reinstall NVIDIA Driver**:
After running the setup script, **reinstall your NVIDIA driver** and reboot your PC.

### Option 2: Using Git

> [!TIP]
> When installed via git, you can run git pull command to automatically update your script.
1. **Clone the Repository**:

```bash
git clone https://github.com/your-repo/dbd-xp-farm.git
cd dbd-xp-farm
```

2. **Install Requirements**:
Run the following command to install the required Python packages:

```bash
pip install -r requirements.txt
```

3. **Reinstall NVIDIA Driver**:
After installing the requirements, **reinstall your NVIDIA driver** and reboot your PC.

- This step is crucial to avoid any compatibility issues. 🚜⚙️


---

## In-Game and Windows Settings

1. Make sure you are using a 1920x1080p resoluton, if you are on a higher resolution display, you can change it in Windows display settings.

2. Make sure you are using 100% resolution scale, no upscalling and 100% GUI scale for both menu and in-game.

---

## Launch Options (Optional)

If you encounter issues with software like ReShade, do the following:

- Add `-dx12` to your Steam or Epic launch options.
- Reinstall your NVIDIA driver again and reboot your PC.

This ensures your CPU doesn’t run into problems where it unnecessarily re-caches shaders and objects, which can cause performance drops. 🚑

### How to Add Launch Options:

- **Steam**:
1. Right-click Dead by Daylight in your library.
2. Go to **Properties** > **General**.
3. Under **Launch Options**, add `-dx12`.
- **Epic Games Launcher**:
1. Go to **Settings**.
2. Scroll down to **Dead by Daylight** under **Manage Games**.
3. Check **Additional Command Line Arguments** and add `-dx12`.

---

## Notes on Performance

🔧 This script lightly relies on your system’s resources:

- It uses CUDA for computations and screen reading to perform actions.
- Make sure your CPU and GPU are capable of handling both the game and the script simultaneously.

If your hardware struggles to run Dead by Daylight smoothly without this script, **do not proceed** until you upgrade your system. 🚫🚀

---

## Troubleshooting

🛠️ **Common Issues & Fixes**:

1. **CUDA Errors**: Reinstall CUDA using the [official download link](https://developer.nvidia.com/cuda-downloads).
2. **Driver Issues**: Always reinstall your NVIDIA driver and reboot your PC after installing the script dependencies.
3. **ReShade Conflicts**: Use the `-dx12` launch option and reinstall your driver to resolve shader-related problems.

---

Happy farming! 🎮🌱 If you encounter further issues, open an issue on the GitHub repository for support.

---
13 changes: 13 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004

Copyright (C) 2004 Sam Hocevar <sam@hocevar.net>

Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.

DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION

0. You just DO WHAT THE FUCK YOU WANT TO.
87 changes: 39 additions & 48 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,68 +1,59 @@
# AFK Script for Dead by Daylight
# Easy Anti Cheat detection

This script is designed to automatically farm XP and a few bloodpoints while avoiding detection:
> [!CAUTION]
> Recently another python project (auto skillcheck hitter), which I've been inspired by, has been receiving reports about EAC bans. This is most likely due to how keypresses are sent to the system.
- **Anti-AFK Proof**: Ensures consistent actions to prevent AFK kicks.
- **Banner-Proof**: Handles cases where survivors disconnect during loading screens.
- **Killer Behaviors**: Implements various killer strategies to maximize bloodpoints gain.
- **XP Gain**: Achieves up to 4000 XP per hour (excluding queue times).
- **Configurable Settings**: Includes settings for customization (more to come).
- **Testing Results**: Tested for 5 hours, yielding ~11,000 XP (queue times took half of that).
**I'm keeping this repository public for educational purposes only.**

**DO NOT USE THIS SCRIPT EVEN IN CUSTOM GAMES!**

# Old feature description:

## Key Features
-**Anti-AFK System**: Smart movement patterns to prevent disconnection
- 🛡️ **Anti-Banner Protection**: Handles disconnections and loading screen issues
- 🎮 **Killer-Specific Actions**: Optimized behaviors for bloodpoint farming
- 🌐 **Web Control Panel**: Remote management interface
- 📊 **In-Game Overlay**: Real-time stats and logging display
- 📈 **Very Powerful**: Up to 2500xp per hour (6000xp during double xp event)

## Statistics
## How It Works
The script keeps your killer moving and doing their thing to look like a real player. Each killer has their own actions they'll use - this helps rack up those sweet bloodpoints while keeping everything looking normal. Of course, the script is also farming XP by just being in a game (1 second = 1 xp, cap at 10 minutes)

(still gathering)
### Supported Killers
| Killer | Actions |
|--------|----------|
| TRAPPER | Placing and picking up traps |
| BLIGHT | Rushing |
| DOCTOR | Static blast and therapy shock |

| | Per game | Per hour (in-game) |
|-------------------------|----------|--------------------|
| XP (ex. 1st game bonus) | 505 avg | 3536 avg |
| Bloodpoints as OTHER | | |
| Bloodpoints as TRAPPER | 2321 avg | 16247 avg |
## Setup Guide

Please follow [the installation guide](GUIDE.md).

## Behaviors
### Configuration
Access the web interface at `http://localhost:5000` to customize script settings.

All killers follow a basic movement pattern by moving back and forth. This helps bypass the anti-AFK system introduced by BHVR, which disconnects you from the game if no movement is detected. You can still interact with survivors (e.g., hit them), but without any movement, after the game ends you'll be treated like you disconnected (no xp, and matchmaking ban).
You can also access the web interface from a different machine, at `http://your-pc-local-ip:5000`

## Interface Screenshots

| Killer | Actions |
|---------|--------------------------------|
| TRAPPER | - Placing and picking up traps |
### Control Panel
<img src=".github/webserver.png" alt="Web Control Panel" width="400px">

### In-Game Display
<img src=".github/overlay.png" alt="In-Game Overlay" width="100%">

## Setup
# Thanks

> [!WARNING]
> This script is designed for 1920x1080 display. If you are using a higher resolution display please set it to 1920x1080 in windows' display settings.
### Rensora

1. Download and unpack this repository
2. Install python 3.11+
3. Install python requirements (setup.bat, first time only):
```
pip install -r requirements.txt
```
4. Run the script (start.bat):
```
python run.py
```
For
- Reporting bugs and suggestions
- Writting the [installation guide](GUIDE.md)

### @Manuteaa

## Settings
For
- Making the [dbd_autoSkillCheck](https://github.com/Manuteaa/dbd_autoSkillCheck) project. Because of it I decided to rewrite this script.

You can configure the script's behavior in the `src/config.py` file.

| Variable | Description | Values |
|-------------|----------------------------------------------------------|----------------|
| killer | Select the killer you're using (with custom behavior) | OTHER, TRAPPER |
| xp_limit | Script will exit after gaining this much XP | 0 to disable |
| games_limit | Script will exit after playing this many games | 0 to disable |


## Bans

There's no widespread evidence of players getting banned for AFK farming. Survivors often benefit from it as well (through healing, totems, etc.).

However, **I am not responsible for any bans** that may occur.
4 changes: 0 additions & 4 deletions TODO.txt
Original file line number Diff line number Diff line change
@@ -1,4 +0,0 @@
- gui app (overlayed above game windows?)
- if entire app cant be overlayed, overlay only logs and stats

- add to readme: cuda and pytorch installation
8 changes: 8 additions & 0 deletions default_config.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
[general]
killer = OTHER
overlay = 1
killer_detection = 1

[limits]
xp_limit = 0
games_limit = 0
9 changes: 7 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
easyocr==1.7.1
Flask==3.1.0
mss==9.0.1
Pillow==10.4.0
Pillow==11.1.0
PyAutoGUI==0.9.54
rich==13.8.1
PyDirectInput==1.0.4
PyQt5==5.15.11
PyQt5_sip==12.16.1
pywin32==308
rich==13.9.4
29 changes: 28 additions & 1 deletion setup.bat
Original file line number Diff line number Diff line change
@@ -1 +1,28 @@
pip install -r requirements.txt
@echo off
if not exist dbdAfk (
echo "Creating dbdAfk virtual environment for python..."
python -m venv dbdAfk
)

echo "Checking for NVIDIA CUDA installation..."
where nvcc > nul 2>&1
if %errorlevel% neq 0 (
echo "WARNING: NVIDIA CUDA not found! Please install CUDA Toolkit (this is for detecting text from game (like buttons))."
echo "You can download it from: https://developer.nvidia.com/cuda-downloads?target_os=Windows&target_arch=x86_64"
echo ""
echo "If you did install CUDA, restart your computer and run this script again."
echo "If it still doesn't work after restart, try google lol and do not open an issue please."
pause
exit
)

echo "Activating dbdAfk virtual environment..."
call dbdAfk\Scripts\activate

echo "Installing requirements... This will take a moment depending on your internet speed."

pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu124
pip install -r requirements.txt

echo "Setup complete. Run 'start.bat' to start the bot."
pause
Binary file added src/assets/banner.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/button_continue.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/button_ok.PNG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/button_play.PNG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/button_play_killer.PNG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/button_queue.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/button_ready.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
29 changes: 0 additions & 29 deletions src/config.py

This file was deleted.

Loading