fluffysnaff / fluffytw

fluffytw: Free and open-source library for DDNet bots
GNU General Public License v3.0
28 stars 4 forks source link
cheating cpp ddnet ddracenetwork game-hacking linux teeworlds teeworlds-hack windows

fluffytw

fluffytw is a base for Teeworlds hacking.

Installation

Before you start, make sure to clone the DDNet repository.

# do this inside DDNet main directory
cd src/game/client
git submodule add https://github.com/fluffysnaff/fluffytw.git

Add this to CMakeLists.txt:

add_subdirectory(src/game/client/fluffytw)

It should be placed before:

set(CLIENT_SRC ${ENGINE_CLIENT} ${PLATFORM_CLIENT} ${GAME_CLIENT} ${GAME_EDITOR} ${GAME_GENERATED_CLIENT})

Initialization

Inside gameclient.cpp add this:

#include <memory.h>
#include "fluffytw/f_helper.h"
std::unique_ptr<FHelper> fHelper;

Now add this code to void CGameClient::OnConsoleInit():

void CGameClient::OnConsoleInit()
{
    // ...
    fHelper = std::make_unique<FHelper>(this);
    // ...
}

Usage

  1. Visuals
    Inside players.cpp include:

    #include "game/client/fluffytw/f_helper.h"

    Then in RenderPlayer() add:

    // ...
    fHelper->m_pConfig_->espCfg.enabled = g_Config.m_ClEspEnable; // This is an example
    fHelper->m_pVisuals->Run(ClientID, Angle, Position); // Make sure to call this
  2. Helper
    Add this in CColision class:

    // inside collision.h
    public:
        // ...
        CTile *GetTiles() const { return m_pTiles; }
  3. Bots
    Inside controls.cpp include:

    #include "game/client/fluffytw/f_helper.h"

    Then in SnapInput(); add:

    // ...
    fHelper->m_pConfig->aimbotCfg.enabled = false; // Set what variables you need using fConfig
    fHelper->m_pBots->Run();
    // ...

    It should be placed after:

    if(!m_aInputDirectionLeft[g_Config.m_ClDummy] && m_aInputDirectionRight[g_Config.m_ClDummy])
        m_aInputData[g_Config.m_ClDummy].m_Direction = 1;

Possible problems

  1. If something isn't working, make sure that configs are setup right and everything is executing.
  2. Aimbot isn't working - Debug it. For example set m_CanAim always to true and see if it works.

Showcase

  1. Hitpoint scan
  2. Hook prediction & Without hook prediction

Star History

Star History Chart