aorecomp

Anarchy Online classic in the browser

git clone https://aorecomp.ubeagle.com/code/aorecomp.git


docs/client-behavior.md (10510B)


Original-client behavior and server responsibilities

These findings concern the release 11.0 binaries identified in reverse-engineering.md. Wire layouts and native procedure references are in protocol.md. Runtime observations come from retained original-client experiments, not a live inventory of the local server.

Launching the original client

The launcher obtains a dimension list from the host/path in DimensionServer.url, appending /dimensions.txt. A dimension record with version 11.0 and local endpoints was sufficient to reach login and Play without applying an official update. No executable-byte patch was needed for that experiment. This does not establish a complete patch-service format.

The launcher supplies the game executable's working directory, environment, and connection arguments. Clientr.exe accepts positional arguments:

Clientr.exe USERNAME PASSWORD CHARACTER_ID [NUMERIC_IPV4 PORT COOKIE1 COOKIE2]

There are either three or seven arguments. The verified localhost launch used 2130706433 for the IPv4 value and set ANARCHY_CD=cd_image and ANARCHY_SETUP=Setupf, with the client directory as the working directory. The extracted game ran without the disc remaining mounted. The preference FullScreen 0 selects windowed mode.

The same environment is required by stock 14.9.1. Its br.dll!AnarchyPath_t::GetSetupPath (0x10001180) first checks ANARCHY_SETUP, then ANARCHY/common/Setupfiles, then C:/Anarchy/setup. When no setup path is available, the string scan at 0x1000121a reads a null pointer. This matched an observed direct-launch crash before entering the world. An anarchy.cfg file containing these assignments does not substitute for the environment normally supplied by the launcher.

The character ID also belongs to the selected server's saved data. Pointing at a different server port does not transfer that character or create it.

The Python launch helper performs a short login exchange to obtain a character ID before launching the native executable. Its socket closes before the game starts. It is not a proxy or an ongoing game dependency. The original launcher can perform the same login-to-world handoff; the helper is an experimental shortcut. Consult its source for the local server's current login behavior.

Entering the world and becoming visible

The world connection sends a character cookie. Connecting already triggers the client's internal logged-in event; system opcode 0x10 signals a character error. Replying with 0x10 as an acknowledgement sent the client back to the launcher and produced a GUI cleanup crash in an early experiment.

Original playfield, SimpleCharFullUpdate, and FullCharacter messages were sufficient to load Omni Training and permit walking. FullCharacter activation sends an unblock request and CharInPlay. Its acknowledgement uses the player identity with no subclass body.

Remote-player SCFU activation hides a character whose InPlay stat 194 is zero. Sending SCFU followed by CharInPlay made another player visible. This explains why a correctly instantiated remote character can still be absent from the rendered scene. The transport recipient and the N3 entity identity are distinct: a message about player A delivered to player B addresses B in the outer frame and A in the N3 prefix.

Movement

The original client simulates local walking and turning and emits CharDCMove messages containing an action, position, quaternion, and two additional floats. Captured packets include individual zlib-compressed bodies. Relaying those updates to another original client reproduces visible peer movement.

This establishes a client prediction/update path. It does not establish how the historical server validated movement, corrected position, checked collision, or simulated NPCs. The two trailing movement floats and vehicle path/control semantics need further work before reconstructing authoritative movement.

The retained walking capture records position changes from (52.625,14.722409,56.875) to (55.962704,14.0,63.920597), including turn and stop commands. Coordinates are evidence of that experiment, not universal spawn requirements.

The shipped keyboard map.GIF is a useful original control reference. In a recorded autonomous movement check, numpad 0 started sustained forward walking; a W tap stopped it and emitted the final position. The camera followed movement, and collision stopped the player at the training fence. These controls allow movement checks without relying on a held-key API or a user keypress.

Tutorial and login tips

Stock 14.9.1 reads these through IndependentPrefs_t::GetPrefInt, rather than character stats or a server setting:

For account localtest and character 1, these are stored in Prefs/localtest/Char1/Char.cfg and Prefs/localtest/Login.cfg inside the client directory. Edit them while the client is closed; the client writes its own preferences when it exits. A new character ID has its own preferences.

Appearance is explicit state

A packed race/breed/sex value alone did not supply a complete player appearance. SCFU activation unconditionally applies HeadMesh to stat 64. Omitting the optional field leaves it zero and removes the head. An explicit original Solitus male head mesh, 40682, restored local and remote heads.

Likewise, the original Solitus body's default hands texture is actually solid green. Supplying original skin texture 8773 through the named TextureDataList restored skin. A hands-only list removed other body materials; the tested complete list included arms, feet, hands, legs, and body. Appearance problems can therefore reflect missing network state rather than corrupt game assets.

NPCs use a separate SCFU branch selected by flag bit 0. MonsterData stat 359 selects a monster appearance. A Leet using original MonsterData 17655 rendered and could be selected without a FullCharacter message. This proves an NPC creation/rendering path, not combat, AI, loot, or historical spawn selection.

Lighting and time

The original GameTime_t constructor defines a 27-hour day and a clock speed of 15 game seconds per real second. Full daylight is between hours 10 and 18; dawn is 5-10 and dusk is 18-23. A dark scene is consistent with nighttime, and does not by itself indicate broken terrain or materials.

Sending a GameTime update for midnight visibly darkened the scene; sending 13:30 restored daylight without reconnecting. Its original payload contains seconds within the day, day period, and day number. The examined Update function uses seconds and day number but does not use the supplied period.

Travel and departure

The original teleport message distinguishes a move within a playfield from playfield teardown. A zone-change teleport followed by system redirect 0x3c caused the client to connect again and send the existing character cookie, without a new login or character identity. Destination initialization then loaded the new playfield. Training, Borealis, and Old Athen rendered in the recorded experiments.

Sending n3ToClientQuitIIR_t to peers removed the addressed entity. Its activation excludes the local player. Departure and return were visible across two clients. Disconnect cleanup and zoning must therefore account for the same character identity having a replacement connection.

Map presence does not guarantee a safe arrival. A Grid scene loaded with error textures, and a nightclub arrival intersected geometry. Terrain/district coordinates are useful candidates, not proof of walkability.

Sitting, quitting, and cancellation

Captured character actions identify sit 86, stand 87, cancel 108, and logout 120. Acknowledging sitting allowed the expected posture change. Quit to Windows starts a 30-second client progress bar. Closing the world connection after that interval completed normal quitting in the recorded experiment.

Standing prevented the delayed connection close, but the client progress bar remained. Echoing action 108 and sending an empty StopLogoutIIR_t both failed to clear it. The original cancellation UI contract is unresolved; normal quit success does not resolve cancellation.

For 14.9.1, the separate CharacterAction 122 response reaches the camping timer's destructor and removes the bar in hardware WASM testing. See camping cancellation for the complete source path. This does not establish the 11.0 cancellation receiver.

What the historical server probably supplied

The evidence supports the following division, with important gaps:

Area Evidence and inference
Accounts and character state Login responses and FullCharacter carry lists/stats; historical validation and persistence are not recovered.
Entity existence and visibility SCFU, CharInPlay, and despawn control original-client entities. A real server needed to select recipients and entity lifetimes; its interest rules are unknown.
NPC populations Disc districts contain template codes/counts and points, while messages create live instances. Server-side selection and template resolution are plausible; exact algorithms and any separate server data are unknown.
NPC simulation The client accepts positioned NPCs and movement updates. Patrol pointers exist, but authored routes and historical simulation have not been recovered.
Appearance Head, named materials, and MonsterData are transmitted state. Exact historical outfit/skin selection remains unknown.
Clock and travel GameTime and teleport/redirect messages supply shared time and transitions. Historical scheduling and zone-server topology are not established.
Combat, loot, nanos, dialogue Rendering/selection does not recover their rules. No complete original server implementation or data set has been found.

Original client code reveals what it reads and does. It cannot, by itself, prove the complete decisions or private data of the 2001 server.