Replace the partial mechanics transcriptions with a separate, readable C11 reconstruction of the complete Win16 image while preserving the original raw Ghidra export as immutable evidence. Cover all ordinary and overlapping entry points, Borland runtime behavior, Win16 imports, segmented data, callbacks, resources, indirect control flow, physics, rendering, persistence, and startup/shutdown lifecycles. Add deterministic extraction and audit tooling plus address-linked ledgers for functions, imports, DGROUP ranges and objects, relocations, resources, and callbacks. The final gate records zero raw, partial, restored, unknown, blocked, or unclassified required units. Keep the semantic-fidelity boundary explicit: the portable C is not claimed to reproduce a byte-identical Borland NE build. Add strict focused harnesses for every reconstructed C unit, exact resource round-trip checks, and a 16-bit Borland Real48 reference probe. No Rust source or Cargo metadata is changed in this phase. Test Plan: - `bash original/tools/test_reconstructed_c.sh` -- passed - `bash original/tools/probe_real48_reference.sh` -- passed bit-for-bit - `python3 original/tools/audit_reconstruction.py --require-complete` -- passed - `git diff --cached --check` -- passed - `git diff HEAD -- '*.rs' Cargo.toml Cargo.lock` -- empty
18 lines
651 B
C
18 lines
651 B
C
#ifndef TDKPIN_SOUND_H
|
|
#define TDKPIN_SOUND_H
|
|
|
|
#include "tdkpin_segmented.h"
|
|
|
|
/* Exact initialized lengths for WAV resource numbers 2001..2022. */
|
|
extern const uint32_t g_sound_resource_byte_counts[22]; /* 1028:03ea..0441 */
|
|
|
|
void tdkpin_initialize_sounds(void); /* 1008:0f2e */
|
|
void tdkpin_play_sound_if_not_tilted(uint16_t sound_number); /* 1008:0002 */
|
|
uint16_t tdkpin_stop_sound_if_active(void); /* 1008:118f */
|
|
void tdkpin_unload_sounds(void); /* 1008:10e3 */
|
|
uint16_t tdkpin_play_sound(uint16_t sound_number); /* 1008:1131 */
|
|
BOOL16 SndPlaySound16(Win16FarPtr sound, UINT16 flags);
|
|
void tdkpin_global_unlock_and_free(Win16FarPtr block);
|
|
|
|
#endif
|