Initial commit: bt411 -- standalone Windows BattleTech (Tesla 4.10 port)
Clean, self-contained extraction of the BattleTech-specific work from the
reverse-engineering workspace -- engine + game + content + build, with nothing
from Red Planet or the raw archive dumps. Builds green (Win32) and runs the
single-player drive->animate->target->fire->damage->destroy loop out of the box.
Layout:
engine/ MUNGA + MUNGA_L4 shared 2007 engine, carrying our BT render/loader
work (bgfload/L4D3D/L4VIDEO: BSL bit-slice decode, LOD/ground/shadow
models) + image codec; the minimal rp/ headers the audio HAL needs
game/ reconstructed BT logic + surviving-original BT source + fwd shims
+ WinMain launcher
content/ full runtime tree (BTL4.RES, VIDEO/, GAUGE/, AUDIO/, eggs, BTDPL.INI)
docs/ format specs + reconstruction ledgers
reference/ raw Ghidra pseudocode (recon source-of-truth) + decomp exporter
tools/ MP console emulator + map/resource scanners
One top-level CMake builds munga_engine lib + bt410_l4 game lib + btl4.exe.
All paths relativized (186 fwd shims + ~437 CMake abs paths -> repo-relative);
DXSDK is the one external, overridable via -DDXSDK. Verified: builds to a
byte-identical 2.27MB exe and runs combat (TARGET DESTROYED, 0 crashes) against
the bundled content.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,52 @@
|
||||
//===========================================================================//
|
||||
// File: gnrator.cpp //
|
||||
// Project: BattleTech Brick: Entity Manager //
|
||||
// Contents: Generator subsystem -- ALIAS / RECONCILIATION NOTE //
|
||||
//---------------------------------------------------------------------------//
|
||||
// Copyright (C) 1995, Virtual World Entertainment, Inc. All Rights reserved //
|
||||
// PROPRIETARY AND CONFIDENTIAL //
|
||||
//===========================================================================//
|
||||
//
|
||||
// THIS IS NOT A SECOND GENERATOR CLASS.
|
||||
// ------------------------------------------------------------------------
|
||||
// gnrator.cpp's Generator == powersub.cpp's Generator (HeatSink-derived
|
||||
// voltage generator, classID 0xBC1, vtable 0x50fd74, ctor @0x4b225c, dtor
|
||||
// @0x4b237c, GeneratorSimulation @0x4b1f7c, HandleMessage @0x4b21d0,
|
||||
// CreateStreamedSubsystem @0x4b23bc). The full reconstruction is in
|
||||
// powersub.cpp. See gnrator.hpp for the reconciliation evidence.
|
||||
//
|
||||
// The surviving fragment GNRATOR.TCP carries two method bodies. TestClass
|
||||
// matches powersub.cpp exactly. ResetToInitialState() is the ONE method the
|
||||
// powersub.cpp reconstruction did NOT recover -- it is reproduced verbatim
|
||||
// below (from the surviving source) so the next reconciler can fold it into
|
||||
// powersub.cpp's Generator. In the shipped binary this is the Generator
|
||||
// vtable's slot-10 (ResetToInitialState), distinct from the Generator
|
||||
// HandleMessage / GeneratorSimulation already in powersub.cpp.
|
||||
//
|
||||
// // --- verbatim from GNRATOR.TCP -------------------------------------
|
||||
// Logical Generator::TestClass(Mech &) // == powersub.cpp (line 844)
|
||||
// {
|
||||
// return True;
|
||||
// }
|
||||
//
|
||||
// void Generator::ResetToInitialState() // ADDITION to powersub.cpp
|
||||
// {
|
||||
// HeatableSubsystem::ResetToInitialState();
|
||||
// outputVoltage = 0.0f;
|
||||
// }
|
||||
// // -------------------------------------------------------------------
|
||||
//
|
||||
// Note the surviving ResetToInitialState chains HeatableSubsystem (not the
|
||||
// HeatSink intermediate) -- consistent with the inlined base chain seen in the
|
||||
// other HeatSink-family resets. No code is emitted from this translation unit;
|
||||
// it exists only to record the file mapping and the recovered method.
|
||||
//
|
||||
|
||||
#include <bt.hpp>
|
||||
#pragma hdrstop
|
||||
|
||||
#if !defined(GNRATOR_HPP)
|
||||
# include <gnrator.hpp>
|
||||
#endif
|
||||
|
||||
// Intentionally empty -- Generator is defined in powersub.cpp.
|
||||
Reference in New Issue
Block a user