32 Commits
Author SHA1 Message Date
SatyandClaude Opus 5.5 82879a879d Port the last non-anti-cheat functions: ServerLink, PetAction, emitter params
- Grunt::ServerLink: all CMD_GRUNT_* handlers, send helpers, features/strings, command table 0xB24D70,
  s_localeIds 0xAD3004, Pending::Remove (dead server-side link, docs/0x008CE200.md); ServerLink.h stub removed
- PetAction type for CGPetInfo::m_actions / pet spell actions / cursor pet action, SetAutocast 0x5D32F0
- CParticleEmitter2 fields 0x98-0x11F moved into CParticleEmitter2::Params (ctor 0x979250)
- fixed16(float), C3Vector::FlushDenormals, CGxuLightQueue + static 0xC7C074, CAaSphere(), CMapLowDetail(),
  C2Vector()/C4Plane() out of line, SpellHistory dtor, CGDynamicObject_C GetScale/GetRawFacing
- DB record operator= (PetNameCache, CGPetition, DanceCache): fixes the shallow-copy double free in AddItem
- ClientSetTimer(delay, handler, param) with its five callers, IOMd5Unit::Create without container,
  CDataStore::GetByte / Get(int32_t&), WDataStore::GetHeaderSpace, TSHashTable::Head, TSList::IsEmpty
- CameraTurnPlayer calls CVehicleCamera_C::IsTransitioningFacing 0x5FAA10 (was IsHierarchyChasingFacing)
- OFFSET additions: TSHashTable::Unlink, TInstanceId dtor, DBCACHEHASH dtor (+ ItemNameCache_C dtor),
  CDataStoreCache ctor, BitUnpacker/RunningAverageCalculator deleting dtors, CGTooltip::GetObjectType

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-04 08:10:06 +02:00
SatyandClaude Opus 5.5 27de58d41e Dissolve _Triage into the source tree
- move triage code to the folders of its binary neighbours (AreaList,
  movement packet types, CClientObjCreate, CWOWClientStatus, SHA1,
  Clamp, EmergencyMem, MippedImg, WowMouse, ...)
- merge HMAC template, OnGxRestartClearWorld and TIMESTAMPSTRUCT into
  their natural headers
- delete superseded duplicates and unk-only placeholders
- tools: drop Triage library, fix Streaming stub signatures, remove
  stubs now provided by BlizzardCore, MapViewer s_liquidTypeId

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-03 18:09:53 +02:00
SatyandClaude Opus 5.5 312ab9ac65 Port batch 1 missing functions and add missing luaL_error returns found by semdiff
Batch 1: weather templates, client console commands, loading screen paths,
glue script events, AddOns/AccountData/Battlenet getters, simple camera and
camera vehicle offsets, Warden module path, BLL loader, FFX effects, Grunt
and GruntLogin matrix/file handlers, CGlueMgr char customize/faction change/
kick reason.

semdiff: 251 Lua script functions called luaL_error without the return 0 that
12340 has after every call site (each confirmed per call site in the binary).

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-03 05:48:17 +02:00
SatyandClaude Opus 5.5 b76f1b443a Port packs w3-w5: objects/vehicles, LCD stack, ComSat voice chat, map dtors, misc missing functions
- Object/vehicle/spell-visual/world/MapObj functions from pack w3
- Logitech LCD stack (CLCDBase..CLCDConnection, CLCDText/Bitmap/Page, CEzLcd, CEzLcdPage, CLCDUtils) and CGLCD
- ComSat client: voice start/stop, mute, sound group fade, tick, event dispatch; s_comsatCallbacks is a growable array
- ShipPath pause/offset, Transport state progress, vehicle bone anim/passenger removal, NetClient redirect
- Map class destructors (CMapArea/Chunk/DoodadDef/Entity/ObjDefGroup), CMapChunk +0xB4 is a TSLink
- Character rename/customize, ClientServices login/survey wrappers, glue Lua scripts, DayNight light overrides
- Template instance and deleting-dtor OFFSETs

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-03 03:16:42 +02:00
SatyandClaude Opus 5.5 6027112a59 Port stand-ins after run 85: UI script modules, AuctionHouse, Commentator
Ports the stand-ins hit since run 85 and the follow-up script batches:
RaidInfo, PartyFrame, BarberShop, ArenaTeamInfo, SkillInfo, InputControl,
petitions/guild registrar, ItemText, Tutorial, ContainerFrame, QuestLog,
ActionBar, ClassTrainer, UIMacros, GuildBank, AuctionHouse and Commentator.

Fixes found on the way: AuctionHouse sell items are a fixed inline array
(IsItemForSell read garbage), GetSellItem returns the container GUID,
Commentator instance key is read/written as u32/u16/u8 and skirmish
commands send a u32 flag, GetArenaMember returns uint64 in edx:eax.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-02 04:14:58 +02:00
SatyandClaude Opus 5.5 6a3666e4b6 Port run-83 hit stand-ins and fix phantom terrain walls blocking movement
- Fix CMap::GetChunkFacets: impassable test uses the chunk MapObjFlag
  (MAPOBJ_FLAG_IMPASSABLE at +0xC) like 12340, not MCNK header flag 0x40
  (vertex colours). Most chunks got 32000-high wall facets, so the player
  could jump but not walk.
- Ship paths: GetPosition, path time, accel/decel distance, roll/pitch.
- Transports: Transport::UpdateMovement, CollideWithTransport, owner matrix.
- Map objects: IsAllLoaded, footprints, TriData query chain (QueryTris,
  GetTrisTerrain/Chunk, GetTriSubchunk, QueryTrisMapObjDefs),
  QueryIntersectingModels.
- Water ripples, projected-texture shadow drawing (shadow.cpp).
- World states, LFG best random dungeon, quest POI, ComSat session lookup,
  blood record, virtual items, guild roster query.
- Logout path: tradeskill close, LCD, DBCache_ClearPending, chat/macro/
  saved-variable/account-data saving, tracked quests/achievements/
  tutorials, UnloadAddOns, SaveAddOnEnableState, ~CGWorldFrame,
  SmartScreenRectShutdown.
- Fixes: TriData batch heights stored as float* (was truncating uint32 on
  x64), TimeInRange is a ShipPath member, ComSat lookup takes the session
  type, roll/pitch names swapped in MapObjTransport::UpdateMovement,
  removed windows.h from Object/Passenger.h.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-01 15:33:24 +02:00
SatyandClaude Opus 5.5 9ddddebc34 Port minimap, item moves, cursor, character info, names, nameplates, combat text
- Fix RsSet render-target upload check (indoor rendering corruption)
- Minimap tracking/hover, world map refresh
- Bag/bar item moves, swaps, equip, item sounds, spell on cursor
- Character info stats, titles, model preview
- Unit/player names (PLAYERNAMEDESC render, name strings, raid icons)
- Nameplates: CGNamePlateFrame, CGSimpleHealthBar, unit glue, SmartScreenRect overlap solver
- Floating combat text: WORLDTEXTSTRING, render batch, PlayerName text slots
- Fix unescaped raid-icon texture path in PlayerNameInitialize

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-01 07:00:36 +02:00
SatyandClaude Opus 5.5 3b857f3eb0 Object port: object classes, object manager, input control, WOWGUID type
- CGObject_C base, CEffect, CObjectEffect/CObjectEffectManager effect states
- Unit, Player, Item/Container/Bag, Corpse, DynamicObject, GameObject and
  all GameObject type classes (vtables matched slot by slot), Movement,
  MovementShared, Missile, Vehicle/Passenger/Camera, combat log, caches
- Client object manager (0x4D3100-0x4D7880) incl. SMSG_UPDATE_OBJECT,
  SMSG_COMPRESSED_UPDATE_OBJECT, SMSG_DESTROY_OBJECT; type ctors/PostInit
- CGGameUI::CanPerformAction and the ready part of CGInputControl
- Layouts named from descriptor fields and code; CM2Model 0x134 matrix,
  CClientObjCreate tail, CGUnit_C/CGPlayer_C sizes 0x1008/0x1958
- WOWGUID struct replaces the IDB's WGUID low/high pair and guid uint64_t;
  SmartGUID derives from it; member functions returning a guid keep
  uint64_t (MSVC returns class types from members via hidden pointer);
  structs with 4-aligned guids in 12340 use pack(4)

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-29 12:27:05 +02:00
SatyandClaude Opus 5.5 f6d07ea346 World port: liquids, map load chain, terrain rendering in MapViewer
Liquid system ported from 12340 (LiquidSystem module, chunk/WMO liquid, wave
manager, geometry factories); CMap load chain (Load, LoadWdt, low-detail WDL,
lights, CreateMapObjDef, PurgeMaps); CMapChunk create/batch/vertex/index code;
CMapRenderChunk; frustum stack and scene cull helpers. MapViewer renders
terrain through a viewer-only shortcut (ViewerWorld.cpp). Engine fix: int
render-state setters write the full pointer-sized slot (x64 texture crash).

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-28 08:07:38 +02:00
SatyandClaude Opus 5.5 095603ff2b Client bring-up: login, realm list, world auth, character select
- Grunt login ported end to end (SRP6 challenge/proof, version checksum,
  realm list) and tested against a live server: authenticates, connects to
  the world server (auth session with proof-of-work, header crypt), receives
  the character list and shows character select
- Glue: realm list UI, character select (list, models, scripts), character
  create screen + name generator, delete/rename/decline, Enter World up to
  the loading screen; loading screen drawing and progress
- AccountData (times, update, upload/download), BannedAddOns, addon scan and
  addon info, client cache version, tutorial flags
- Shutdown path at login state: world/map/liquid/weather teardown, NetClient,
  ComSat, streaming stop; Logitech LCD no-device path in Ui/UILCD/Windows
- PCRE 5.0 vendored (core stock; chartables and the posix layer from 12340),
  ValidateName
- Fixes: TSGrowableArray::CalcChunkSize clamps to >= 8 (crash on char list),
  CWorldScene liquid renderer allocation, CMapFootprintTexture element ctor,
  pointer render states on x64, CFrustum/CWFrustum layout, M2 draw callback
  arguments, 37 class/struct forward-declaration mismatches
- IDB name sync (1217 names), verify aliases, harness large-element
  instantiation

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-28 02:39:56 +02:00
SatyandClaude Opus 5.5 2e418f9e08 Client bring-up: glue screen, EULA/TOS, shutdown chain, LCD, x64 fixes
- Stand-in client reaches the glue screens (intro movie, EULA/TOS accept,
  login screen) at 16:9; stand-ins are report-only on x64
- Ports on the startup/idle path: GlueScriptEvents/CharacterSelection/
  CharacterCreation/RealmList/AccountMsg/VideoOptions _Scripts, CGlueMgr
  (Initialize/Resume/Idle/Accept*/Shutdown), ClientServices, NetClient/
  WowConnection, DBCache + instances, WorldParam/World/Map/Liquid/Weather/
  shadow, InputControl, Scrn, ConsoleClient, SysMessage, LoadingScreen,
  SystemRegisterFunctions, CGameTime, Screen::GetAspectRatio
- Shutdown chain: BeginCloseGame, DestroyEngineCallback, DBCache save/
  destroy, SpellVisuals/Effect/World/Glue teardown
- Logitech LCD no-device path in Ui/UILCD/Windows (Windows-only dir);
  lgLcd is a stub library in ThirdParty/lgLcd
- CVar and console commands split into <Module>_CVar.cpp / _Console.cpp
- DivxDecoder.dll (Win32, original) and XvidDecoder.dll (x64, port with
  vendored xvidcore) both copied to the build folder
- Warden: Win32 faithful port, Win64 stub
- x64 fixes: lua_newstate gcusage/gctime init, pointer render states reset
  with nullptr, g_rndSeed defined
- 37 class/struct forward-declaration mismatches fixed (false stand-ins)

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-27 21:47:34 +02:00
SatyandClaude Opus 5.5 cb9f7f4ac7 Base/Event: cover HandleCompare and the remaining destructors
HandleCompare (0x47BF20): the ICF-folded 4-byte handle difference that the
M2 scene sorts, CSimpleTexture and CDetailDoodadInst call. ~TRefCnt now
names its scalar deleting destructor (0x480E40), ~CDataRecycler adds
0x95CE00, and TSHashObject gets its destructor (0x47C560, the HASHKEY_STR
instance). Event is 88/88, Base 122/123 (the s_callbackRegAllocator atexit
thunk stays compiler-generated).

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-27 01:13:36 +02:00
SatyandClaude Opus 5.5 2203210f2b Model2: port the Model2 TUs
M2Model.cpp, M2Shared.cpp, M2Scene.cpp, CM2SceneRender.cpp, M2Light.cpp,
M2Cache.cpp and the new M2Data.cpp/.h (0x81C000-0x834900). Only the
std::sort internals for CModelBatch stay unported.

AnimationData lookups in ResolveSequenceFallback/SequenceFallbackById use
g_animationDataDB directly: 12340 inlines its record loads into M2Model.cpp.

Shared additions: CParticleEmitter2 vtable order and the plane/sphere/spline
emitters, CRibbonMat, Services/Camera.h, Base/SIMD, Base/ObjectAlloc.h (the
engine-side ObjectAlloc interface), CFacet, CAaRect, CiRange, the C44Matrix
16-float constructor and CMath fequal/fnotequal/FloatToInt64.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-27 00:28:21 +02:00
SatyandClaude Opus 5.5 1c40e8a29b lua-5.1: match 12340 (taint, profiler, GC accounting, mem pool, bitlib)
All 509 functions of 12340's Lua block (0x84D390-0x863580) carry an
OFFSET and are verified (static evidence; see re/notes/303_lua.md).

- Compiled as C++ with extern "C" API, setjmp/longjmp errors.
- Taint on GC objects and TValues, taint globals, taint event callback,
  closure taint in the VM, gctag for new objects.
- Profiler: Profile per closure, luaD_precall_profile,
  luaV_execute_profile; GC size/time accounting per tag.
- luaconf: COMPAT_VARARG/MOD/GFIND off, 4-byte max alignment,
  MAX_SIZET 0x1000000; removed randomseed/print/dofile/loadfile/load,
  no binary chunks.
- UTF-8 string.lower/upper, Blizzard string.format, BOM skip,
  raw lua_setglobal, table.removemulti/wipe, externalabort.
- New: lbitlib.c, lmemPool.cpp/.h, FrameScript_InvalidPtrCheck
  (Win32/Win64), lua CMake target.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-25 23:41:32 +02:00
SatyandClaude Opus 5.5 5a2919f977 Texture T1: CTexture, create path, GxTex cache, atlas, BLP upload
Ports 37 Texture.cpp functions from TextureCreate to the filled D3D
texture (cache, solid textures, PumpBlpTextureAsync, TextureAllocGxTex/
FreeGxTex reuse buckets, atlas, TextureGetGxTex, TextureInitialize),
GxuUpdateSingleColorTexture, GxTexReusable(CGxTex*), CGxTexFlags==,
CBLPFile ctor/dtor. Fixes CStatus Add overload order (vtable slots).
GxTest --textures reads back D3D levels; all match 12340 (note 298).

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-25 19:59:26 +02:00
SatyandClaude Opus 5.5 21cef061ce Event pass 2: Storm RW lock, instance id table, scheduler
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-25 04:52:29 +02:00
SatyandClaude Opus 5.5 5f21409837 Event pass 1: message queue, timers, priority queue
Rebuild Event headers from the binary (EvtContext layout, EVENTID,
EVENT_DATA_*, cdecl handlers), IEvtQueue*, IEvtTimer*,
CSBasePriorityQueue, TExtraInstanceRecycler, TSList::Combine.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-25 04:00:37 +02:00
SatyandClaude Opus 5.5 f047b71145 Gx pass 3: Gx* wrappers, small CGxDevice members, portable Storm error constants
- Gx wrappers: GxXform*, GxBuf*, GxDraw, GxDrawLockedElements, GxSceneClear, GxTexDestroy/Copy/Reusable,
  GxQueryCreate/Destroy, max FPS, GxGetBlitFormat, GxHasContext, GxIsWindowVisible, GxMasterEnable
- CGxDevice: DeviceApi, CapsHasContext, CapsIsWindowVisible, MasterEnable, DeviceClearScreenShot, XformPush
- CGxTexParms, EGxXform, BlitFormat
- STORM_ERROR_SUCCESS/NOT_ENOUGH_MEMORY/INVALID_PARAMETER replace Win32 ERROR_* in general files;
  windows.h removed from them

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 22:45:13 +02:00
SatyandClaude Opus 5.5 953240f57c BlizzardCore Log, SComp review, Win32/Win64 platform folders
System/Log (16 functions) and Thread::WaitForever. Storm SComp review:
ImaAdpcmCompress size compares are signed as in 12340. AllocSTL_raw and
CCritSect members marked INLINED; SSyncObject ctor out of the header.

Platform layout: Windows API code lives in <dir>/Win32/ (whole file in
#if WOWDECOMP_ARCH_32) with full copies in <dir>/Win64/ (ARCH_64);
no _M_X64 blocks inside files. Former W32/ and *_Win32.cpp files moved,
their headers are generic now. Win32 API calls moved out of generic
File/Log/Thread/Unicode/SCmd files; Storm SErr/SLog/SReg/SMsg moved
whole. CODING_RULES section 7, PORTING_64BIT "Platform folders".

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 16:16:55 +02:00
SatyandClaude Opus 5.5 a8e251eb85 Base: Base, CmdLine, ConvertUTF, Coordinate, Sort
Port the remaining Base block A pieces: global/context init, the
command-line option table, UTF-8/16 conversion (sgetu8/sputu8), the
coordinate/aspect helpers and the context qsort. All functions verified
against the binary.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 05:46:00 +02:00
SatyandClaude Opus 5.5 195c975476 Base: CDataStore
Port CDataStore (0.5.3 layout and names, 11-slot 12340 vtable) into
Engine/Source/Base, remove its declaration from UIUtil/AddOns.h, and
document the three folded vtable stubs. All functions verified against
the binary.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 05:20:21 +02:00
SatyandClaude Opus 5.5 9c87d11233 Base: CDynamicString
Port CDynamicString (Mac 4.0.1 names; Grow and field names are best
guesses) and allow best-guess names in CODING_RULES.md. All functions
verified against the binary.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 05:01:59 +02:00
SatyandClaude Opus 5.5 04a7d5136a Base: CDataRecycler, RefCount.cpp; move header function bodies to .cpp
Port CDataRecycler following the 12340 binary (Link takes two arguments).
Move every non-template function body out of the Base headers into their
.cpp files, give TRefCnt its own RefCount.cpp, and record the rule in
CODING_RULES.md.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 04:46:38 +02:00
SatyandClaude Opus 5.5 fc73a3920f Base: CDataAllocator
Port the fixed-size block allocator (0.5.3 layout, Mac 3-argument Clear,
destructor as inlined Clear). All functions verified against the binary.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 04:29:34 +02:00
SatyandClaude Opus 5.5 147177c448 Base: CBitArray; Storm: operator delete[]
Port CBitArray (Mac 4.0.1 names and field names from asserts) and add the
client operator delete[] that 12340 inlines everywhere.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 04:23:35 +02:00
SatyandClaude Opus 5.5 8f14dd9d01 Base: RCString, CStringMemory, CStringManager, TRefCnt
Port the 12340 string interning table (Mac 4.0.1 design) and TRefCnt in
RefCount.h. All functions verified against the binary.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 04:17:30 +02:00
SatyandClaude Opus 5.5 cccfd26213 Move Storm to Engine/Source/Storm; SFile.cpp to BlizzardCore
Storm moves under Engine/Source with its inner layout unchanged. All
includes use Engine/Source/Storm/..., Storm's include guards follow the
new path, and the top-level CMakeLists adds Engine/Source/Storm.
SFile.cpp (SFile::CreateOverlapped/DestroyOverlapped) moves to
Engine/Source/BlizzardCore.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 03:33:51 +02:00
SatyandClaude Opus 5.5 2e5f2331a5 Implement Engine/Source/Base FileCache
BaseFileDestroy; PrefetchNode/UncachableNode (constructor and destructor
inline); statics s_activeFiles, s_uncachableFiles, s_critSect. Empty
BaseFileInitialize, IBaseFileWaitForLoad, SFile::CreateOverlapped and
SFile::DestroyOverlapped (folded, docs/0x005EEB70.md, docs/0x00632050.md).
SOVERLAPPED in SFile2-Core.h.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 03:33:50 +02:00
SatyandClaude Opus 5.5 37591d61e2 Implement Engine/Source/Base Handle
HandleClose, HandleCreate, HandleDuplicate; HandleDereference inline;
empty HandleInitialize/HandleDestroy (folded). CHandleObject in
Base/Handle.h with its real layout (vtable, m_refcount at +4), which moves
TEXTBLOCK::m_string and FONTHASHOBJ's fields by 4. HOBJECT in Base/Types.h.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 03:14:22 +02:00
SatyandClaude Opus 5.5 f282eed856 Implement Engine/Source/Base Prop and Os/W32/Tls
Prop: PropInitialize, PropDestroy, PropSelectContext,
PropGetSelectedContext, PropGet, PropSet, PropCreateContext, s_tlsIndex.
Tls: OsTlsAlloc, OsTlsFree, OsTlsGetValue, OsTlsSetValue. PROPERTY enum
and HPROPCONTEXT in Base/Types.h (moved from Event/EvtContext.h).

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 03:03:19 +02:00
SatyandClaude Opus 5.5 a19a5df43e Implement Engine/Source/Base Status
CStatus with its 12340 layout (vtable, entry list, highest severity):
GetGlobalStatusObj, Add (both), IsEmpty, GetErrorStr, GetErrorStrLen,
GetErrorStrAlloc, Prepend, ~CStatus; STATUSENTRY destructor and Clear
inline in Status.h. CTexture drops the gap that was the rest of CStatus.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 02:56:37 +02:00
Saty 5137298335 Initial commit 2026-09-23 18:24:00 +02:00