chiark / gitweb /
Remove magic numbers from cell type contexts
[ypp-sc-tools.main.git] / pctb / example
1
2
3
4 Version number (3 ascii digits) followed
5 by LF (i.e. 0x0A).  Current version is\
6  005
7
8   0000   30 30 35 0a                                        005.
9
10 # of shops/stalls (in ascii)  + LF
11   0000               31 0a                                      1.           
12
13 list of shop names in ascii (without the
14 possessive part and by specifying the \
15 shop type in an abbreviated way which is
16 mentioned below).  The shop names are
17 separated \ by line feeds (0x0A).  To
18 specify the shop type append the "^"
19 character and then \ one of the
20 following characters depending upon the
21 shop type:
22    Apothecary = A
23    Distillery = D
24    Furnisher = F
25    Iron Monger = I
26    Shipyard = S
27    Tailor = T
28    Weavery = W
29
30   0000                     4f 6c  64 20 49 72 6f 6e 73 69         Ol d Ironsi
31   0010   64 65 73 0a                                        des.              
32
33 # of buy offers (in binary)
34   0010               05 00                                 
35
36 commodIndex offerCount                                       buy 0/5
37   0010                     0a 00  01 00                      Grog x 1
38 [shopIndex val amt]                   
39   0010                                  01 00 1d 00 75 00    OI 29 qty 75
40
41 commodIndex offerCount                                       buy 1/5
42   0020   0b 00 01 00                                         Fine x 1
43 [shopIndex val amt]... (all in binar\ y)
44   0020               01 00 33 00  e9 03                      OI 51 qty 0x3e9
45
46 commodIndex offerCount                                       buy 2/5
47   0020                                  0c 00 01 00          Small shot x 1
48 [shopIndex val amt]
49   0020                                              01 00    OI
50   0030   0f 00 e9 03                                         15 qty 0x3e9
51
52 commodIndex offerCount                                       buy 3/5
53   0030               0d 00 01 00                             Medium shot x 1
54 [shopIndex val amt]
55   0030                            01 00 1c 00 e9 03          OI 28 qty 0x3e9
56
57 commodIndex offerCount                                       buy 4/5
58   0030                                              0e 00    Large shot
59   0040   01 00                                                          x 1
60 [shopIndex val amt]
61   0040         01 00 26 00 e9 03                             OI 38 0x3e9
62
63
64 # of sell offers (in binary)
65   0040                            04 00
66
67 commodIndex offerCount                                       sell 0/4
68   0040                                  09 00 01 00          Swill x 1
69 [shopIndex val amt]
70   0040                                              01 00    OI 
71   0050   17 00 e8 03                                         23 0x3e8
72 commodIndex offerCount                                       sell 1/4
73   0050               0a 00 01 00                             Grog x 1
74 [shopIndex val amt]
75   0050                            01 00 1e 00 73 03          OI 30 qty 0x373
76 commodIndex offerCount                                       sell 2/4
77   0050                                              0c 00    Small shot
78   0060   01 00                                               x 1
79 [shopIndex val amt]
80   0060         01 00 10 00 07 00                             OI 16 qty 7
81 commodIndex offerCount                                       sell 3/4
82   0060                            0d 00 01 00                Medium shot x 1
83 [shopIndex val amt]
84   0060                                        01 00 1e 00    OI 30
85   0070   02 00                                               qty 2