Developer Hub • Crazy Taxi Modding Framework v1.0

Build Your Own Crazy Taxi Mod
Submod Development Guide & Memory Reference

The definitive reverse engineering and plugin creation hub for Crazy Taxi 1 on PC (Steam, 2014 & 2016 releases). Build standalone C++ DLL plugins that integrate cleanly into the LFM in-game Mod Menu (Shift+F1) using shared Dear ImGui styling, understand how the real-time Direct3D 9 texture injection engine works under the hood, and inspect the complete, sorted memory offset database.

Plugin Architecture & C++ Guide

1. How to Build Custom Sub-Mods (Beginner-Friendly Guide)

The LFM Framework is engineered with an open modular architecture. You can create your own DLL plugin in C++ and place it in the mods/ directory. The framework detects it at runtime, registers it in the Shift+F1 menu, and renders your custom UI widgets using a shared Dear ImGui context.

Loading Flow & Shared Context

When Crazy Taxi.exe boots, dinput8.dll automatically scans the mods/ directory and loads each compatible dynamic link library. Framework_MOD.dll inspects all loaded modules: if a DLL exports GetSubModName(), it is registered automatically as an interactive Sub-Mod!

✅
Shared ImGui & Direct3D 9 Context: The framework passes its active ImGuiContext* and IDirect3DDevice9* pointer directly to your submod. Your mod renders buttons, sliders, and checkboxes with matching Sega Arcade pink/yellow styling.
✅
Zero Device Reset Conflicts: You never need to hook D3D9 EndScene or window procedures (WndProc) yourself. The host framework manages device resets, fullscreen transitions, and input interception cleanly.
System Loading Hierarchy
Crazy Taxi.exe
  └── dinput8.dll (DirectInput8 Proxy Loader)
        ├── mods/Framework_MOD/Framework_MOD.dll  (Host UI, D3D9 Hooks, Engine Guards)
        └── mods/MyCustomMod/MyCustomMod.dll      (Your Sub-Mod)
              ▲
              │ Shares ImGuiContext* & IDirect3DDevice9*
              ▼
        Framework Mod Menu (Shift+F1 Sidebar Tab)

Required Sub-Mod C ABI Exports

Function Signature Requirement Purpose & Operational Behavior
const char* GetSubModName() ✅ Required Identifies the DLL as a submod and sets the name displayed in the Shift+F1 sidebar menu.
const char* GetSubModAuthor() Optional Author name displayed in the submod header (default: "Community").
const char* GetSubModVersion() Optional Semantic version string (e.g. "1.0.0").
const char* GetSubModDescription() Optional Descriptive text rendered beneath the mod header in the UI.
bool IsSubModEnabled() ✅ Required Returns whether your mod's background hooks and logic are currently active.
void SetSubModEnabled(bool) ✅ Required Called when the user toggles the Enable/Disable switch in the menu.
void InitSubMod(void* ctx, IDirect3DDevice9* dev) ✅ Required Called once upon detection. Passes the host ImGuiContext* and Direct3D 9 device pointer.
void RenderSubModUI(void* ctx) ✅ Required Called every frame when your tab is active. Render your custom ImGui buttons, sliders, and checkboxes here!
View Complete Starter Sub-Mod Source Code (my_mod.cpp: Turbo Taxi & Tips)

This complete working submod adds a hotkey turbo boost on key T, an infinite fare tips option, and a 1-click vehicle orientation leveler.

my_mod.cpp
#include <windows.h>
#include <d3d9.h>
#include "imgui.h"

constexpr uintptr_t ADDR_GAME_FLAG   = 0x016A2CFC;
constexpr uintptr_t ADDR_PLAYER_X    = 0x01661574;
constexpr uintptr_t ADDR_PLAYER_Y    = 0x01661578;
constexpr uintptr_t ADDR_PLAYER_Z    = 0x0166157C;
constexpr uintptr_t ADDR_PLAYER_SPD  = 0x0166158C;
constexpr uintptr_t ADDR_TOTAL_MONEY = 0x016F10E0;

static bool  g_bEnabled     = true;
static float g_BoostPower   = 1.5f;
static bool  g_InfiniteTips = false;

static DWORD WINAPI ModWorkerThread(LPVOID)
{
    while (true)
    {
        Sleep(16);

        if (!g_bEnabled)
            continue;

        int* pGameFlag = (int*)ADDR_GAME_FLAG;
        if (!pGameFlag || *pGameFlag != 3)
            continue;

        if ((GetAsyncKeyState('T') & 0x8000) != 0)
        {
            float* pSpeed = (float*)ADDR_PLAYER_SPD;
            if (pSpeed && *pSpeed < 140.0f)
            {
                *pSpeed *= g_BoostPower;
            }
        }

        if (g_InfiniteTips)
        {
            int* pMoney = (int*)ADDR_TOTAL_MONEY;
            if (pMoney && *pMoney < 500000)
            {
                *pMoney = 500000;
            }
        }
    }
    return 0;
}

extern "C" __declspec(dllexport) const char* GetSubModName()
{
    return "Turbo Taxi & Tips";
}

extern "C" __declspec(dllexport) const char* GetSubModAuthor()
{
    return "Community Modder";
}

extern "C" __declspec(dllexport) const char* GetSubModVersion()
{
    return "1.0.0";
}

extern "C" __declspec(dllexport) const char* GetSubModDescription()
{
    return "Adds hotkey turbo boost and automated fare tip locking.";
}

extern "C" __declspec(dllexport) bool IsSubModEnabled()
{
    return g_bEnabled;
}

extern "C" __declspec(dllexport) void SetSubModEnabled(bool enabled)
{
    g_bEnabled = enabled;
}

extern "C" __declspec(dllexport) void InitSubMod(void* pImGuiContext, IDirect3DDevice9* pDevice)
{
    if (pImGuiContext)
    {
        ImGui::SetCurrentContext((ImGuiContext*)pImGuiContext);
    }
    CreateThread(NULL, 0, ModWorkerThread, NULL, 0, NULL);
}

extern "C" __declspec(dllexport) void RenderSubModUI(void* pImGuiContext)
{
    if (pImGuiContext && ImGui::GetCurrentContext() != pImGuiContext)
    {
        ImGui::SetCurrentContext((ImGuiContext*)pImGuiContext);
    }

    ImGui::TextColored(ImVec4(1.0f, 0.4f, 0.7f, 1.0f), "Turbo Taxi Settings");
    ImGui::Separator();
    ImGui::Spacing();

    ImGui::Checkbox("Enable Features", &g_bEnabled);
    ImGui::Spacing();

    if (g_bEnabled)
    {
        ImGui::Text("Hold 'T' while driving to activate Turbo Boost.");
        ImGui::SliderFloat("Boost Multiplier", &g_BoostPower, 1.05f, 2.50f, "%.2fx");
        ImGui::Spacing();

        ImGui::Checkbox("Lock Money to $5,000.00", &g_InfiniteTips);
        ImGui::Spacing();

        if (ImGui::Button("Instant Fix Taxi Orientation"))
        {
            int16_t* pPitch = (int16_t*)0x0166147A;
            int16_t* pRoll  = (int16_t*)0x0166147C;
            if (pPitch) *pPitch = 0;
            if (pRoll)  *pRoll  = 0;
        }
    }
}

BOOL APIENTRY DllMain(HMODULE hModule, DWORD ul_reason_for_call, LPVOID lpReserved)
{
    return TRUE;
}
View CMake Build Configuration (CMakeLists.txt & Build Commands)

Compile in 32-bit x86 using CMake and Visual Studio Developer Command Prompt:

cmake_minimum_required(VERSION 3.20)
project(TurboTaxiMod LANGUAGES CXX)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

include_directories(${CMAKE_CURRENT_SOURCE_DIR}/deps/imgui)

add_library(TurboTaxiMod SHARED
    my_mod.cpp
    deps/imgui/imgui.cpp
    deps/imgui/imgui_draw.cpp
    deps/imgui/imgui_tables.cpp
    deps/imgui/imgui_widgets.cpp
)

target_link_libraries(TurboTaxiMod PRIVATE d3d9)

# Build Commands (Win32 x86):
# call "C:\Program Files\Microsoft Visual Studio\18\Community\VC\Auxiliary\Build\vcvars32.bat"
# cmake -B build -A Win32
# cmake --build build --config Release
View Best Practices & Crash Prevention Guidelines
  • ✅ Do NOT hook D3D9 EndScene or Reset again: Framework_MOD.dll already manages EndScene and device resets. Hooking it a second time introduces race conditions and device lost crashes. Always render UI via RenderSubModUI.
  • ✅ Do NOT install a second WndProc hook: Framework_MOD.dll intercepts input for Dear ImGui. Installing another window procedure hook breaks menu toggling.
  • ✅ Always check in-game state: Verify *(int*)0x016A2CFC == 3 before writing coordinates. Memory structures are unallocated during menus and intro videos.
  • ✅ Use VirtualProtect for .rdata: If changing engine constants (e.g. Far-Z or Gravity), invoke VirtualProtect with PAGE_EXECUTE_READWRITE first.

Direct3D 9 Reverse Engineering

2. How Texture Manipulation Works Under the Hood

Understanding the native Sega Dreamcast emulation layer and DirectX 9 memory pipeline allows modders to inject custom assets seamlessly without frame drops.

Direct3D 9 Texture Injection Pipeline

Crazy Taxi does not store textures as loose files on disk. Instead, the engine maps all textures into an internal Master Texture Descriptor Array at 0x01B09938 containing 8,192 slots of 24 bytes each.

✅
Hot-Swapping pD3DTexture: At offset +0x00 lies pTexObj. Following this pointer to +0x0C yields the active IDirect3DTexture9* COM pointer. Swapping this pointer instantly injects high-resolution textures into GPU VRAM without stutter or re-loading stages!
✅
GBIX Hash Lookups: Sega maps VRAM to virtual addresses from 0x0CB40000 to 0x0F000000. The relative offset pData, 0x0CB40000 matches the texture's GBIX identifier, providing O(1) hash map retrieval.
Hook Points & Virtual VRAM
0x00492230 -> LoadModelTexture (Vehicles, characters in texDC0)
0x0048B7A0 -> LoadStageTexture (Stage geometry in texDC1/2/3)
0x00481200 -> SegaRenderer::SetTexture (DirectX 9 binding point)
0x005342B4 -> IAT: D3DXCreateTextureFromFileInMemoryEx (UI / JPK)

Master Table: 0x01B09938 + (slotId * 24)
pTexObj:      MasterEntry + 0x00
pD3DTexture:  *(IDirect3DTexture9**)(pTexObj + 0x0C)
View Technical Deep Dive: Master Texture Descriptor Array Layout (0x01B09938)

The master table has 8,192 (0x2000) entries. Each entry is 24 bytes (0x18):

+0x00: void*    pTexObj   // Pointer to Sega Texture Object Wrapper
+0x04: uint32_t flags     // Engine render status flags
+0x08: float    width     // Original texture width (IEEE 754)
+0x0C: float    height    // Original texture height (IEEE 754)
+0x10: uint32_t pData     // Virtual VRAM pointer (0x0CB40000 + relOffset)
+0x14: uint32_t reserved  // Status flags

Substructure pTexObj (+0x00):
+0x00: uint32_t             refCount
+0x0C: IDirect3DTexture9*   pD3DTexture  // Active hardware texture!
View How to Hook Native Functions in C++ (MinHook Trampolines & Memory Safety)

To intercept engine routines without conflicts, use MinHook inside your submod thread. Always restore hooks cleanly on module unload:

hook_example.cpp
#include <windows.h>
#include "MinHook.h"

// Typedef for SegaRenderer::SetTexture (0x00481200)
typedef int (__thiscall* fnSetTexture)(void* pRenderer, int stage, void* pTexObj);
static fnSetTexture pOriginalSetTexture = nullptr;

static int __fastcall Hooked_SetTexture(void* pRenderer, void* edx, int stage, void* pTexObj)
{
    // Custom mod logic: inspect or swap texture descriptors prior to rendering
    return pOriginalSetTexture(pRenderer, stage, pTexObj);
}

void InstallHooks()
{
    if (MH_Initialize() == MH_OK)
    {
        MH_CreateHook((LPVOID)0x00481200, (LPVOID)&Hooked_SetTexture, (LPVOID*)&pOriginalSetTexture);
        MH_EnableHook((LPVOID)0x00481200);
    }
}

void RemoveHooks()
{
    MH_DisableHook((LPVOID)0x00481200);
    MH_Uninitialize();
}
View Reading & Writing Engine State in C++ & Cheat Engine (Pointers & Offsets)

Example patterns for reading player position, vehicle velocity, and dereferencing multi-level pointer chains safely:

memory_access.cpp
// 1. Guard check: Only execute during active gameplay (State == 3)
int* pGameState = (int*)0x016A2CFC;
if (!pGameState || *pGameState != 3) return;

// 2. Read direct player position and speed
float posX = *(float*)0x01661574;
float posY = *(float*)0x01661578; // Important: -Y is Sky / Ascend, +Y is Ground / Descend
float posZ = *(float*)0x0166157C;
float speed = *(float*)0x0166158C; // Current speed in game units

// 3. Multi-level pointer resolution for Sega Direct3D 9 Device
uintptr_t* ppRenderer = (uintptr_t*)0x01B7AC00;
if (ppRenderer && *ppRenderer)
{
    IDirect3DDevice9* pDevice = *(IDirect3DDevice9**)(*ppRenderer + 0x18);
    if (pDevice)
    {
        // Safe access to native DirectX 9 device
    }
}

Reversed Memory Database

3. Complete Memory Offsets, Addresses & Pointers

Full, verified technical documentation from offset_list.json for Crazy Taxi.exe (Win32 x86, Base Address: 0x00400000). Click any category button below to filter, or use the live search input.

Identifier / Symbol Memory Address Data Type Operational Notes & Subsystem Description
Loading verified memory offsets from offset_list.json...
887 reverse-engineered entries across 20 engine subsystems

Developer Downloads

Open-Source Repositories & References

Download verified C++ source code archives, complete memory guides, and submod templates.

REAL-TIME TEXTURE ENGINE

Texture Mod Source Code (v0.88)

Complete C++ project for real-time Direct3D 9 texture injection, GDI progress dialog, MinHook detours, and LTMC binary caching algorithms.

Package: 7z Compressed Size: ~33.2 KB
Download TextureMod_SRC.7z
CORE FRAMEWORK & LOADER

Framework Mod Source Code (v1.0)

Full source code for dinput8.dll proxy loader, ImGui menu overlay, memory cheats, 360° freecam, and Direct3D 9 crash guards.

Package: 7z Compressed Size: ~64.3 KB
Download Framework Source (.7z)
OFFSETS DATABASE

Complete Offsets Reference (.json)

The comprehensive raw JSON database documenting all 26 Sega container tables, pointer chains, physics vectors, and memory offsets.

Format: JSON (.json) Size: ~660 KB
Download offset_list.json
SUBMOD SPECIFICATION

Submod Development Guide (.md)

The complete standalone developer markdown guide containing architecture diagrams, C ABI signatures, and CMake build configuration.

Format: Markdown (.md) Size: ~10.5 KB
Download Submod Guide (.md)

Developer Support & Technical Inquiries

Developing a custom C++ sub-mod or need help with Direct3D 9 hooking, memory offsets, or ImGui context sharing? Submit your questions or suggestions directly to the LFM team via the official AI Support Form.