27 Commits
Author SHA1 Message Date
SatyandClaude Opus 5.5 dfae6719b7 Naming pass: 65 functions, 103 statics, 63 fields named from Mac symbols and behaviour
Evidence and confidence per rename in re/notes/310_naming_pass.md.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-04 09:27:29 +02:00
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 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 bbf3de4926 Record skipped template instances and ChatChannel ctor
Template instance addresses added to stpl.h (TSList::UnlinkNode,
~TSHashTable deleting destructors, TSGrowableArray::SetCount,
~TSFixedArray) and WowClientDB::GetRecordByIndex. ChatChannel default
constructor 0x502960 ported (user-provided: sets +0x9C/+0xA0 to 1).
M2Shared.cpp: VERIFY re-stamp only.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-02 09:11:39 +02:00
SatyandClaude Opus 5.5 74f50d713b M2Shared: allocate x64 .anim and vertex overflow buffers near m_data
M2Array stores a signed 32-bit self-relative offset. On x64 a separate
heap block can lie more than 2 GB from m_data, so relocated low-priority
.anim sequence data wrapped and crashed in ProcessEventCallbacks.

Add OsAllocNear/OsFreeNear (Win64): reserve a block within 1.5 GB of an
anchor. x64 now uses it for .anim buffers (load, cancel, destructor) and
for the skin vertex overflow, which again follows the Win32 structure
(m_flags |= 8, freed in ~CM2Shared). Texture combo arrays keep growing
m_data. All new code is under WOWDECOMP_ARCH_64.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-02 08:35:26 +02:00
SatyandClaude Opus 5.5 0470ad7933 M2Shared: x64-safe combo/vertex arrays, ignore runtime header bits from files
- x64: texture combo, transform combo and converted vertex arrays are
  appended to a grown m_data buffer instead of separate heap blocks, so
  the self-relative 32-bit M2Array offsets always reach them; they are
  freed with m_data (destructor frees only on Win32)
- FinishLoading clears header bits 0x20/0x40 from the file; the client
  uses them to mark arrays it allocated, and later-expansion models set
  them, which made the destructor free a pointer into the file buffer

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-02 07:11:14 +02:00
SatyandClaude Opus 5.5 f24e731415 Port hit stand-ins: unit swim/flight/vehicle, footprints, shadow query, liquid sounds, weather, world states, game object types, friend list packet
Old list #26-#77 and new list #1-#25: unit movement/vehicle passengers,
missile trajectory, trade skills, corpse/spirit healer UI, map flight
bounds, footprints, low detail render, shadow query gather/render,
CMapArea liquid sounds, weather type/pos deltas, world state init/set,
transport/chair/animated game objects, contact list packet, macros,
tracked achievements, tutorials, dungeon difficulty.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-01 10:10:31 +02:00
SatyandClaude Opus 5.5 18c46cb87e Client bring-up: in-world camera, input, movement, unit rendering
Ports verified against 12340 that take the x64 client from character
login to a playable world:

- Camera: SetView/ResetView, motion, free-look facing, tracking, bobs,
  liquid bump, world collision; camera Lua scripts
- Input: world frame key/mouse layers, default action, mouselook,
  turn/pitch player, TurnOrAction/CameraOrSelectOrMove scripts
- Movement: legal facing range, turn/pitch/raw facing events, transport
  status, move spline copy, unit update info, smooth facing, anim end
- Units: component and extended display init, model fade/scale,
  entity sort table, RenderEntitys, split-body culling
- Interiors: WMO group bounds, BSP segment link query, face linking,
  interior lighting
- Collision: CMap::QueryFacets closure with frustum queries and NDCClip
- UI: game UI mouse filters, client control state, faction standing
  packet, many *_Scripts.cpp Lua tables; name generator dictionary fix

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-29 23:04:53 +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 4a571e727c World port: WMO water, fog, area updates, purge chain, detail doodads
- Barriers, shadow/portal queries, underwater selection, hit testing
- Interior water: PolyClipper, ClipGroupGeometry, liquid index fix
- Area updates, barrier updates, purge/free chain for areas, chunks,
  doodad and map object defs, detail doodad update list
- Water ripples, terrain pixel shader path, liquid shader toggles
- Detail doodads: creation per chunk, pools, batching, vertex/index
  fill, shader and fixed-function render state, RenderDetailDoodads
  (trailing occluder/debug draws still to port), CMapChunk::SelectLights
- DayNight moved to WoW/Source/WorldClient
- MapViewer: fog, WMO water, detail doodads; diagnostics removed

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-29 07:43:15 +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 6ee0c14d69 Verify remaining functions; SI2::ChaosModeUpdate; SE2::StopAllSounds arg
ChaosModeUpdate (0x4C74F0) reordered to the binary's switch case layout
and case 15 written as 8 statements; verified. SE2::StopAllSounds takes
the unused int every 12340 caller pushes. Approval stamps for the
functions unblocked by the IDB splits (Button/Checkbox IsA, Checkbox
dtor, CSimpleFrame::NotifyDelayedLoad, CGxDeviceD3d9Ex ctor,
CM2Cache dtor) and for the re-reviewed IsSequenceLoaded,
OsGuiMessageBox, TexturePickAlternateFilename, three FMOD ctors and
luaG_concaterror.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-27 15:51:40 +02:00
SatyandClaude Opus 5.5 34770ee7ab Frame: port Engine/Frame (waves 1-4), 1667 of 1669 functions
Core (CSimpleFrame + Lua, CSimpleTop/CFrameStrata/CSimpleRender/
CRenderBatch, CSimpleRegion/CBackdropGenerator/CScriptRegion), animation,
text (FontString/Font/Fontable), texture and model, buttons, EditBox,
MessageFrame/MessageScrollFrame, MovieFrame/ColorSelect/StatusBar,
Slider/ScrollFrame/HTML/HyperlinkedFrame, all Lua method tables and
RegisterScriptMethods. Layouts, vtables and sizes rebuilt from the
12340 ctors, vtables and allocator initializers; CScriptObject vtable
slots 5/6 fixed; CSimpleFontedFrame is a real secondary base. Lua error
paths return after luaL_error as in 12340 (209 sites; 5 fall through).
Binary quirks kept and documented in docs/.

Supporting additions: Event key/char/ime/focus/size event headers,
Scrn/Scrn.h (ScrnLayerCreate), DivxDecoder import declarations,
C2Vector/CRect helpers, CM2Light dtor, OsInputEnableSecureMode, stpl.h
instance addresses, FrameXML LoadXML_AnimGroup/Create_SimpleMovieFrame.
Engine->WoW includes where 12340 calls directly: CSimpleModelFFX,
StringToMouseButton, GetDeclinedWord, EmblemTextureUpdate.

Also drops stale VERIFY stamps found invalid by the harness recheck.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-27 15:32:18 +02:00
SatyandClaude Opus 5.5 e2038cdec5 Services: port Profile, TextBlock, Camera, particles and ribbons
Profile, TextBlock, Camera (+CameraInt.h), ParticleSystem2 (emitters,
track sampling, sort queue), RibbonEmitter, GfxSingletonManager managers
and the v1 CParticleEmitter destructor. All pass or approved with
explained diffs; 0 fails. Callee-cleanup helpers declared __stdcall,
float->int paths use CMath::fint_ (binary uses fistp). CLightning fields
named only; it is WoW/Common code. _Triage CAngle removed, Camera.h
repointed to CameraInt.h. CM2SceneRender Render calls cast for the new
signature. Services links freetype for the Gxu font headers.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-27 03:08:52 +02:00
SatyandClaude Opus 5.5 13054ed277 Model2: header-inline copies emitted in WoW and ~CM2Cache
CM2Model::SetWorldTransform(C44Matrix) 0x4D8630, GetBoundingBox 0x4F5E20,
GetBoundingSphere 0x4F5E80, GetAnimatedWorldTransform 0x6F1D20,
CM2Lighting::Reset 0x4E2730, CM2Lighting(const CAaSphere&) 0x790440 and
CM2Cache::~CM2Cache (0x81C870, reached through the atexit thunk 0x9DD200;
needs its IDB function defined). Removes a stray VERIFY stamp inside
CM2Lighting().

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-27 03:04:04 +02:00
SatyandClaude Opus 5.5 4921b0d194 Tools: add M2Viewer, a spinning-M2 render test
Tools/M2Viewer opens a window, creates the D3D9 Gx device, loads an M2 from
bin/Win/Data through M2Cache/CM2Scene and spins it; Win32 and x64. Unported
engine functions it links but never reaches map to aborting stand-ins.

Engine pieces it needed: CGxDeviceD3d::XformSetProjection, CGxDevice::
XformSetViewport, GxXformSetViewport, CParticleEmitter2::Init and the
ParticleSystemManager projection statics. M2Scene.h now declares
s_localLighting/s_blendModes (they could not link), and the duplicate
particle emitter classes left in _Triage are removed.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-27 00:57:44 +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 ee8a1c1bc6 ShaderEffect: port ShaderEffect, ShadowCache, manager and parser TUs
ShaderEffect.cpp (0x8728C0-0x873F50), ShadowCache.cpp (0x873F60-0x876370),
ShaderEffectManager.cpp (0x876370-0x876E30) and ShaderEffectParser.cpp
(0x876E30-0x8773F0).

Shared additions: GxRenderTargetSet, CGxDevice::DeviceGetRenderTarget,
C44Matrix::Identity, CWFrustum (m_sceneLink removed: 0xF4 stride),
M2LIGHTTYPE and the CM2Lighting::SetupGxLights declaration.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-27 00:16:27 +02:00
SatyandClaude Opus 5.5 720e730823 Engine no longer depends on WoW/Source
- MOUSEBUTTON/MOUSEMODE move to Engine/Source/Event/Types.h (WoW/Source/Console/Types.h
  removed; COLOR_T is in ConsoleBase/Types.h).
- CRange and CBoundingBox move to Tempest (CRange.h, CBoundingBox.h); World.h includes them.
- TEXTURECACHE moves to Gxu/GxuFontMiscClasses.h (its code is in the Gxu font range,
  0x6C8E70+); CACHEENTRY stays in WoW/Common/TextureCache.h.
- CGxDevice.h, CGxFont.h, M2Model.h, Event and Os drop their WoW includes.
Build clean on Win32/x64 (known Wow.exe link gaps only); verify unchanged.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-26 19:20:38 +02:00
SatyandClaude Opus 5.5 0ba24012af DB: 241 12340 client DB records, one header each in DB/Rec (GetFilename + Read, 482 definitions verified)
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-26 16:04:55 +02:00
SatyandClaude Opus 5.5 4898dcc94a Gx pass 7: pools, shader hash table, CGxDevice ctor/dtor
Port BufCreate, PoolCreate/PoolDestroy, DeviceCreatePools,
DeviceCreateStreamBufs, IShaderLoad, ShaderCreate, ShaderDestroy,
CGxShader::Load/dtor, CGxPool dtor, CGxDevice ctor/dtor and
OsGetProcessorFeatures. CGxBuf gets its own header/source.
CGxPool/CGxBuf/CGxAppRenderState/CGxPushedRenderState become structs
(RTTI .?AU). HASHKEY_STRI derives from HASHKEY_STR. m_shaderList is
TSHashTable<CGxShader, HASHKEY_STRI>[6]; list offsets via offsetof.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-25 00:14:22 +02:00
SatyandClaude Opus 5.5 a09c429bd3 Tempest pass 1: readable field names, class-named files, math classes
- Field names from the 12340 type library (x/y/z/w, a0..d3, minY/minX/maxY/maxX, b/t, c/r, n/d, origin/dir)
- Files renamed to match their class; CRay -> C3Ray; C3Segment, CRect, CiRect, C2iVector, C3iVector split out
- MouseEventData, CharacterInfo, M2Bounds moved out of Tempest headers
- 107 functions: C2/C3/C4Vector, C33/C34/C44Matrix, C4Quaternion, C4Plane, CAaBox, CAaSphere, C3Ray, CRect, CiRect, CImVector, NTempest
- 0x4C1C40 is cdecl (q, out): ported as static C44Matrix::FromQuaternion (guessed)

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-09-24 20:46:51 +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 ae952861ad Implement Storm classes
Storm template library (TSLink, TSList, TSExplicitList, arrays, TSHashTable,
hash keys) and W32 sync classes (SCritSect, SSyncObject, SEvent, SMutex,
SSemaphore, SThread::SetPriority), written from the binary. Adds storm.h
with the Storm API the templates call. Generated headers updated for the
new homes and the array element types recovered from the binary.

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