Skip to content

Commit fb16b84

Browse files
authored
Merge pull request #41 from squirelworks/claude/project-thread-rw1tge-603
graal-6.03r7-G3D0511C: 0.0.1 rebuild of the 6.03r7 Linux client
2 parents 367b0c6 + b15119c commit fb16b84

11 files changed

Lines changed: 5657 additions & 0 deletions

File tree

‎graal-6.03r7-G3D0511C/README.md‎

Lines changed: 99 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,99 @@
1+
# Graal 6.03 rev 7 for Linux (`G3D0511C`)
2+
3+
The 6.03r7 client, rebuilt. The original read for this folder is the Linux
4+
x64 build of November 2012: one native C++ program, no launcher and no
5+
engine library. On the wire it keeps the gen-5 codec with its own token,
6+
no tamper check, no listserver and no licence file. This folder starts
7+
from `graal-5.00r7-G3D22067` and changes what the 6.x notes say differs.
8+
This is the 0.0.1 reproduction: hit or miss.
9+
10+
The Windows 6.03r7 is the same release with its own token (`G3D0311C`) and
11+
`win` in its login line. It is not this folder.
12+
13+
> **Not affiliated.** graal-delphi is an independent fan project. It is not
14+
> affiliated with, endorsed by, or connected to GraalOnline or
15+
> graalonline.com, Cyberjoueurs, or Stéphane Portha ("unixmad").
16+
17+
## Sources
18+
19+
From [graal_analysis](https://github.com/squirelworks/graal_analysis), not
20+
from decompiled code:
21+
22+
| Area | Notes |
23+
|---|---|
24+
| Token, login line, framing, ids both ways | `protocol/v6x-clients.md` |
25+
| Ids in table form | `version-profiles/5.00-6.03.toml` |
26+
| Login mode, server warp, play (Windows 6.03r7 in the lab) | `protocol/v5v6-lab-play.md` |
27+
| Everything carried over | `../graal-5.00r7-G3D22067/README.md`, `../graal-3.153-G3D28015/README.md` |
28+
29+
## What differs from the 5.00r7 rebuild
30+
31+
| | 5.00r7 | 6.03r7 Linux (this folder) |
32+
|---|---|---|
33+
| Game token | `G3D22067` | `G3D0511C` |
34+
| Login line tail | `win` and three machine fields | `linux` and four machine fields |
35+
| Login mode | level drawn, no characters | no tiles and no characters (chests and image NPCs only) |
36+
| Long frames | none | 0xFFFF bytes or more: length 0xFFFF, then a u32be length |
37+
| Early flush | not traced (60000 bytes) | at 0x1000 bytes |
38+
| Server ids handled | 100 | 92: drops 41, 75, 132, 133, 165, 169, 171, 175, 181, 184, 193; adds 109, 111, 198 |
39+
| OSTYPE prop | `win` | `linux` (assumed from the login line) |
40+
41+
The machine ids are, on the original, MD5 hashes of the `eth0` MAC and of
42+
the inode of `/etc`, an empty field, and the kernel release and version.
43+
The rebuild reads none of them and sends each as `""`.
44+
45+
## Units
46+
47+
As in 5.00r7, with the suffix `603`: `Protocol603`, `GraalClient`,
48+
`Adventure`, `Graal603.dpr`, `ListServer603`, `StartScreen603`, `RunMode`.
49+
50+
## Running it
51+
52+
Put `Graal603` in the root of a 6.03r7 install and start it with no
53+
arguments for the start screen. It finds the install's files from there,
54+
or from `graal-assets/6.03r7/` and `graal-assets/common/` next to it.
55+
56+
Start asks a Seihai listserver for the server list (`listserver.txt` next
57+
to the program, else `listserver.graal.in` on 14922), since the rebuild
58+
cannot show the Login server's scripted list. The picked server's name
59+
becomes the client's server name, as if the Login server had already
60+
warped there, so the level and the player are drawn.
61+
62+
```
63+
GRAAL_PW=... Graal603 --server HOST:PORT --account NAME # as Login
64+
GRAAL_PW=... Graal603 --server HOST:PORT --account NAME --server-name Classic
65+
Graal603 --level some.nw # offline
66+
```
67+
68+
With `--server` and no `--server-name` the server is `Login`: no tiles and
69+
no characters are drawn until the server sends a 178.
70+
71+
## Files it opens
72+
73+
From the program's folder (or `--data`), then `graal-assets/6.03r7/`, then
74+
`graal-assets/common/`:
75+
76+
- `pics1.png` (or `pics1.gif`) at the top or in `levels/tiles/`, where a
77+
5.x/6.x install keeps it; `arrays.dat` (a 5.x/6.x install has none, so
78+
the built-in tile types are used)
79+
- `levels/` for levels, ganis and images; `levels/heads/`, `levels/bodies/`,
80+
`levels/swords/`, `levels/shields/`, `levels/hats/`, `levels/images/`,
81+
`levels/tiles/` and `levels/images/downloads/` (where the install keeps
82+
`sprites.png`)
83+
- `levels/offlinetutorial_b-2.nw` (or `.graal`) for Training, else `start.nw`
84+
(a 5.x/6.x install has no offline tutorial, so Training plays `start.nw`)
85+
- `listserver.txt` (optional)
86+
87+
## Not yet, or not known
88+
89+
- The Login server's scripted GUI and GS2: 140 and 197 (scripts and the
90+
`GRESCR01` cache), 195 (gani scripts) and 190 are accepted and ignored.
91+
- 109 (probably a file redirect), 111 (`creationtime.dat`) and 198 are
92+
accepted and ignored; the rebuild writes no `creationtime.dat`.
93+
- 46 (ENTERLEVEL) on level entry, 162 (the ping answer), the base-file
94+
requests and the keep-alive 24 are not sent.
95+
- `GR-V1.05` levels and `GRPKG001` update packages.
96+
- The chat font (Tempus Sans ITC 24) and nickname colours by AP.
97+
- Whether 6.03r7 plays offline at all is not traced; Training keeps 3.153's.
98+
- No side-by-side run against the real 6.03r7; that is 0.0.2 work.
99+
- Everything still missing from the 5.00r7 rebuild.
Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
# Graal 6.03 rev 7 for Linux (G3D0511C)
2+
3+
The first rebuild of the Graal 6.03 rev 7 Linux client, in Delphi (Object
4+
Pascal). The original is a Linux program from 2012; this rebuild runs on
5+
Linux and Windows. It is an early version: most of the game (NPCs, items,
6+
weapons, scripts, the scripted login screens) is not there yet.
7+
8+
> **Not affiliated.** graal-delphi is an independent fan project. It is not
9+
> affiliated with, endorsed by, or connected to GraalOnline or
10+
> graalonline.com, Cyberjoueurs, or Stéphane Portha ("unixmad").
11+
12+
These zips hold no original Graal code, graphics, sounds or levels. The
13+
program carries small original default graphics and a starter level of its
14+
own, so it runs as it is. Put it in the root of a 6.03r7 install you own
15+
(or point it at one with `--data DIR`) and the install's tiles, ganis,
16+
heads and bodies take their place. The shared `graal-assets/` folder next
17+
to the program works too (`graal-assets/6.03r7/`, then
18+
`graal-assets/common/`).
19+
20+
## Downloads
21+
22+
| Zip | Runs on | Window |
23+
|---|---|---|
24+
| `…-linux.zip` | Linux x86-64 | X11 |
25+
| `…-windows.zip` | Windows, 32-bit | GDI |
26+
27+
Each zip has `Graal603` (the client), `Test603` (its test suite) and the
28+
build's README.
29+
30+
## What works
31+
32+
- The start screen: nick name, Training, Start. Start fetches the server
33+
list from `listserver.txt` next to the program, or else
34+
`listserver.graal.in` on port 14922. Then account, password and Connect.
35+
- Login with `G3D0511C`, the platform `linux` and four empty machine
36+
fields; the language in its own frame; no tamper check.
37+
- The Login server: a server reached by its address alone is called
38+
Login, and there neither the tiles nor any characters are drawn, until
39+
the server moves the client on with a server warp. A server picked from
40+
the list plays at once.
41+
- Server warps: the client logs in again to the named host and port, under
42+
the new name.
43+
- Long frames (64 KB and more) both ways.
44+
- The first props with `linux` as the system name; movement sent every
45+
tick in whole pixels.
46+
- The board, the player and other players drawn from the install's tiles
47+
and ganis; walking and collision; level links; gmaps and their edges.
48+
- A headless mode for stress runs, with JSON stats.
49+
50+
## Not yet
51+
52+
NPCs, baddies, items and weapons; scripts and their cache; the scripted
53+
server list and account screens; chat and its font; layered levels; update
54+
packages. See the build's README for the full list.
55+
56+
## Checks behind this release
57+
58+
The test suite (97 checks) runs with range and overflow checks and the heap
59+
tracer, and must end with no unfreed memory. CI also logs two of these
60+
clients into seihai-gserver, has the second see the first, and walks one
61+
through a level link.

0 commit comments

Comments
 (0)