Av8ports testing

From PikkaWiki
Jump to: navigation, search

Test GRF 1 (Farm Airstrip as industry)

Farmplant.png

Farmairtile.png

GRF download

NFO

// Automatically generated by GRFCODEC. Do not modify!
// (Info version 7)
// Format: spritenum pcxfile xpos ypos compression ysize xsize xrel yrel
    0 * 4	 5A 00 00 00

    // nforenum suppression
    // @@WARNING DISABLE 170
    // @@WARNING DISABLE 172
    // @@WARNING DISABLE 100
    // @@WARNING DISABLE 132
    // @@WARNING DISABLE 86

    1 * 34	 08 06 44 44 "AP" "Test Airport 1" 00 "By PikkaBird" 00

// ====================================================================================================================
// Tiles (industry tiles for now, but format should stay the same):
// I made the hangar with a seperate ID, since eventually clicking
// on the hangar tile should open the hangar window, and clicking on
// a non-hangar tile will open the airport information window (the
// standard station info window to begin with, although if we go the
// whole hog and introduce, eg, public airports, there will be more
// information required for airports than for other station types).

    2 * 8	 00 10 01 02 00
                 08 21 00

// hangar tile (tile ID 00)
    3 * 4	 01 10 02 01
    4 SPRITES\aviator\av8ports\tiles\farm.pcx 0 0 09 63 64 -31 -32
    5 SPRITES\aviator\av8ports\tiles\farm.pcx 64 0 09 63 64 -31 -32

    6 * 17	 02 10 A1 00 00 80 00 80 01 80 00 80 00 00 10 10 10
    7 * 7	 03 10 01 00 00 A1 00

    8 * 7	 00 10 01 01 00
    13 01 // hangar 01

// non-hangar tile (tile ID 01)
    9 * 4	 01 10 07 01
   10 SPRITES\aviator\av8ports\tiles\farm.pcx 0 0 09 1 1 -1 -1 // dummy non-ground sprite
   11 SPRITES\aviator\av8ports\tiles\farm.pcx 128 0 09 47 64 -31 -16
   12 SPRITES\aviator\av8ports\tiles\farm.pcx 192 0 09 47 64 -31 -16
   13 SPRITES\aviator\av8ports\tiles\farm.pcx 256 0 09 31 64 -31 0
   14 SPRITES\aviator\av8ports\tiles\farm.pcx 320 0 09 31 64 -31 0
   15 SPRITES\aviator\av8ports\tiles\farm.pcx 384 0 09 47 64 -31 -16
   16 SPRITES\aviator\av8ports\tiles\farm.pcx 448 0 09 47 64 -31 -16

   17 * 17	 02 10 A1 00 01 80 00 80 00 80 00 80 00 00 10 10 10
   18 * 17	 02 10 A2 00 02 80 00 80 00 80 00 80 00 00 10 10 10
   19 * 17	 02 10 A3 00 03 80 00 80 00 80 00 80 00 00 10 10 10
   20 * 17	 02 10 A4 00 04 80 00 80 00 80 00 80 00 00 10 10 10
   21 * 17	 02 10 A5 00 05 80 00 80 00 80 00 80 00 00 10 10 10
   22 * 17	 02 10 A6 00 06 80 00 80 00 80 00 80 00 00 10 10 10

   23 * 30	 02 10 A1 81 43 10 FF 05
   A1 00 02 02
   A2 00 10 10
   A3 00 11 11
   A4 00 12 12
   A5 00 13 13
   A6 00

   24 * 7	 03 10 01 01 00 A1 00

// ====================================================================================================================
// Airport (airport ID 00)

   25 * 20	 04 0D 9F 01 01 DC "Farm Airstrip" 00
   26 * 103	 04 0D 9F 01 02 DC "A private field for light aircraft.  One 3-length unsealed runway.  One loading bay, one hangar." 00

//   26 * 14	 04 0D 9F 01 10 DC 80 " Field" 00
//   27 * 22	 04 0D 9F 01 11 DC 80 " Airstrip" 00


   27 * 28	 00 0D \b9 01 00
  08 \w1940 09 FF FF     // years
  0F 00                  // small airport
  10 03                  // catchment
  11 01 00               // noise
  12 01 DC               // name
  13 02 DC               // description
  14 03                  // max rwy length
  15 01                  // helicopters can use
//  16 02                  // cost
//  17 01                  // cost overbuild
//  20 10 DC               // airport name
//  21 11 DC               // airport name

// layout - action 00 property 0A
//                                                   v1              v2             v3
   28 * 49	 00 0D 01 01 00 0A 01 \d37 00                        00 01 FE 01 00
                                                      01 00 FE 00 00 01 01 FE 01 00
                                                      02 00 FE 01 00 02 01 FE 01 00
                                                                   03 01 FE 01 00
                                                                   04 01 FE 01 00 00 80

// nodes - entry points are 0B (NE), 0D (NW), 07 (SW), 09 (SE)


   29 * 156	 00 0D 02 01 00 0B
   12
   \w24 \w8 \w0 05 01      // 00 hangar exit
   \w40 \w8 \w0 05 10      // 01 bay
// runway
   \w24 \w24 \w0 00 00     // 02 liftoff point
   \w40 \w24 \w0 00 00     // 03 rollout end
   \w56 \w24 \w0 00 00     // 04 runway junction
   \w63 \w24 \w0 00 00     // 05 takeoff turn
// circuit                                                             65496 = -40, 65480 = -56
   \w65496 \w24 \w150 00 00  // 06 turn crosswind
   \w65480 \w8 \w150 07 00   // 07 crosswind leg (entry point)
   \w65480 \w65496 \w150 00 00 // 08 turn downwind
   \w65496 \w65480 \w150 05 00 // 09 downwind leg (entry point)
   \w120 \w65480 \w150 00 00 // 0A turn base
   \w136 \w65496 \w150 03 00 // 0B base leg (entry point)
   \w136 \w8 \w150 00 00   // 0C turn final
   \w120 \w24 \w150 01 00  // 0D final (entry point)

   \w40 \w24 \w80 01 00     // 0E helicopter hover point
   \w80 \w24 \w48 01 00     // 0F fenceline decision point
   \w56 \w24 \w0  01 00     // 10 touchdown point
   \w24 \w8 \w0 05 00       // 11 hangar entry

   18 0b 0d 07 09           // entry points

// =====================
   30 * 4	 01 0D 01 01
   31 SPRITES\aviator\av8ports\tiles\farm.pcx 0 80 09 96 96 -0 -0 // menu graphic
   32 * 17	 02 0D FF 00 00 80 00 80 00 80 00 80 00 00 10 10 10

// STATEMACHINE STATES in 7C 01
// 01 = bay occupied
// 02 = runway occupied
// 10 = aircraft taking off
// 20 = aircraft approaching
// 40 = aircraft taxiing in
// 80 = aircraft waiting to take off


// GO AROUND ===
   33 * 14	 02 0D 50 81 18 00 F0 01
14 81 00 00 // set aircraft state to 14 flying circuit
06 80       // head for node 06

//FENCELINE 0F ===
//!!Error (203): Offset 10: No persistent registers exist for this feature.
   34 * 21	 02 0D 00 81 7C 01 60 DF 00 \b1 10 1A 00 \b1  // mark aircraft approaching clear
01 50 00 00 00 50 00                                     // then ^^

   35 * 15	 02 0D 0F 81 7C 01 00 42 01
10 80 00 00   //  ^^ if runway is clear, continue to touchdown
00 00         // else ^^

// HELI HOVER POINT 0E ===
   36 * 14	 02 0D 02 81 18 00 F0 01
19 81 00 00 // set aircraft state to 19 landing
01 82       // hover

   37 * 14	 02 0D 00 81 18 00 F0 01
19 81 00 00 // set aircraft state to 19 landing
01 80       // head for bay 01

//!!Error (203): Offset 10: No persistent registers exist for this feature.
   38 * 21	 02 0D 01 81 7C 01 60 DE 01 \b1 10 1A 00 \b1  // mark bay occupied and aircraft approaching clear
01 00 00 00 00 00 00                                     // then ^^

   39 * 15	 02 0D 00 81 7C 01 00 01 01
01 00 00 00   // ^^ if bay is clear
02 00         // ^^ else

   40 * 14	 02 0D 00 81 18 00 F0 01 // iteration check for occupation check
00 00 00 00
01 00       // skip check on subsequent iteration

   41 * 14	 02 0D 10 81 18 00 F0 01
0F 81 00 00 // set aircraft state to ? 0F climbing
06 80       // head for turn crosswind 06

   42 * 14	 02 0D 0E 81 18 00 0F 01
00 00 00 02   // plan is hangar or load?
10 00         // else ^^

// FINAL 0D ===
   43 * 14	 02 0D 10 81 18 00 F0 01
15 81 00 00 // set aircraft state to 15 decending
0F 80       // head for node 0F

   44 * 14	 02 0D B0 81 18 00 F0 01
18 81 00 00 // set aircraft state to 18 heli preparing to land
0E 80       // head for node 0E

   45 * 14	 02 0D 00 82 81 00 FF 01 B0 00 00 00 10 00       // aircraft or helicopter?

//!!Error (203): Offset 10: No persistent registers exist for this feature.
   46 * 21	 02 0D 00 81 7C 01 60 DF 20 \b1 10 1A 00 \b1  // mark aircraft approaching
01 00 00 00 00 00 00                                     // then ^^

   47 * 19	 02 0D 0D 81 7C 01 00 72 02
00 00 00 00   //  ^^ if runway is clear and there's no aircraft on final
00 00 10 12   //  ^^ if an aircraft is taking off and there's no aircraft on final
50 00         // else go around 50

   48 * 14	 02 0D 0D 81 18 00 F0 01 // iteration check for occupation check
0D 00 00 00
00 00       // skip check on subsequent iteration

// various checks go here; for now, any aircraft can land.


// BASE LEG 0B ===
   49 * 14	 02 0D 0B 81 18 00 F0 01
14 81 00 00 // set aircraft state to 14 flying circuit
0C 80       // head for node 0C

// DOWNWIND LEG 09 ===
   50 * 14	 02 0D 09 81 18 00 F0 01
14 81 00 00 // set aircraft state to 14 flying circuit
0A 80       // head for node 0A

// CROSSWIND LEG 07 ===
   51 * 14	 02 0D 07 81 18 00 F0 01
14 81 00 00 // set aircraft state to 14 flying circuit
08 80       // head for node 08

// TURN CROSSWIND 06 ===
   52 * 14	 02 0D 10 81 18 00 F0 01
12 81 00 00 // set aircraft state to 12 cruising
00 8F       // fly away

   53 * 14	 02 0D 00 81 18 00 F0 01
14 81 00 00 // set aircraft state to 14 flying circuit
07 80       // head for node 07

   54 * 14	 02 0D 06 81 18 00 0F 01
00 00 00 02   // plan is hangar or load?
10 00         // else ^^

// TAKEOFF TURN 05 ===
   55 * 14	 02 0D 00 81 18 00 F0 01
07 81 00 00 // set aircraft state to 0D takeoff
02 80       // head for liftoff point 02

//!!Error (203): Offset 10: No persistent registers exist for this feature.
   56 * 21	 02 0D 00 81 7C 01 60 ED 12 \b1 10 1A 00 \b1  // mark runway occupied and aircraft taking off
01 00 00 00 00 00 00                                     // then ^^

   57 * 15	 02 0D 05 81 7C 01 00 40 01
01 82 40 40   // turn to heading 01 and wait if aircraft taxiing in
00 00         // else ^^

// RUNWAY JUNCTION 04 ===

   58 * 14	 02 0D 00 81 18 00 F0 01
1A 81 00 00 // set aircraft state to 1A helitakeoff
0E 80       // head for hover point 0E

//!!Error (203): Offset 10: No persistent registers exist for this feature.
   59 * 21	 02 0D 10 81 7C 01 60 FD 00 \b1 10 1A 00 \b1  // mark runway clear
01 00 00 00 00 00 00                                     // then ^^

   60 * 15	 02 0D B0 81 7C 01 00 40 01 // helicopter: is aircraft waiting to taxi in?
00 00 40 40
10 00

   61 * 14	 02 0D 10 81 18 00 F0 01
07 81 00 00 // set aircraft state to 07 taxiing
05 80       // head for takeoff turn node 05

   62 * 14	 02 0D 00 82 81 00 FF 01 B0 00 00 00 10 00       // aircraft or helicopter?

//!!Error (203): Offset 10: No persistent registers exist for this feature.
   63 * 21	 02 0D 10 81 7C 01 60 FE 00 \b1 10 1A 00 \b1  // mark bay clear
01 00 00 00 00 00 00                                     // then ^^

   64 * 14	 02 0D 00 81 18 00 F0 01
07 81 00 00 // set aircraft state to 07 taxiing
01 80       // head for bay node 01

//!!Error (203): Offset 10: No persistent registers exist for this feature.
   65 * 21	 02 0D 00 81 7C 01 60 BC 01 \b1 10 1A 00 \b1  // mark bay occupied, runway clear, taxiing in clear
01 00 00 00 00 00 00                                     // then ^^

   66 * 14	 02 0D 04 81 18 00 0F 01
00 00 00 02   // plan is hangar or load?
10 00         // else ^^

// ROLLOUT END 03 ===
   67 * 14	 02 0D 00 81 18 00 F0 01
07 81 00 00 // set aircraft state to 07 taxiing
04 80       // head for rwy junction node 04

//!!Error (203): Offset 10: No persistent registers exist for this feature.
   68 * 21	 02 0D 01 81 7C 01 60 BE 41 \b1 10 1A 00 \b1  // mark bay occupied and taxiing in
01 00 00 00 00 00 00                                     // then ^^

   69 * 14	 02 0D 00 81 18 00 F0 01
07 81 00 00 // set aircraft state to 07 taxiing
07 82       // turn heading 7 and wait

//!!Error (203): Offset 10: No persistent registers exist for this feature.
   70 * 21	 02 0D 02 81 7C 01 60 BF 40 \b1 10 1A 00 \b1  // mark taxiing in
01 00 00 00 00 00 00                                     // then ^^

   71 * 15	 02 0D 03 81 7C 01 00 01 01
01 00 00 00   // ^^ if bay is clear
02 00         // ^^ else

// LIFTOFF POINT 02 ===
   72 * 14	 02 0D 00 81 18 00 F0 01
0F 81 00 00 // set aircraft state to 0F climbing
06 80       // head for turn crosswind 06

//!!Error (203): Offset 10: No persistent registers exist for this feature.
   73 * 21	 02 0D 02 81 7C 01 60 DD 00 \b1 10 1A 00 \b1  // mark runway clear and aircraft taking off clear
01 00 00 00 00 00 00                                     // then ^^

// BAY NODE 01 ===
   74 * 14	 02 0D 10 81 18 00 F0 01
07 81 00 00 // set aircraft state to 07 taxiing
11 80       // head for hangar node 11

   75 * 14	 02 0D 00 81 18 00 F0 01
07 81 00 00 // set aircraft state to 07 taxiing
04 80       // head for rwy junction node 04

//!!Error (203): Offset 10: No persistent registers exist for this feature.
   76 * 21	 02 0D 01 81 7C 01 60 FD 02 \b1 10 1A 00 \b1  // mark runway occupied
01 00 00 00 00 00 00                                     // then ^^

   77 * 19	 02 0D 00 81 7C 01 00 62 02
01 00 00 00   //  ^^ if runway is clear and there's no aircraft on final
01 00 40 60   //  ^^ if an aircraft is waiting to taxi in
01 83         // else turn to heading 03 and wait

   78 * 14	 02 0D 00 81 18 00 F0 01 // iteration check for occupation check
00 00 00 00
01 00       // skip check on subsequent iteration

   79 * 18	 02 0D 01 81 18 00 0F 02
10 00 01 02   // plan is hangar?
05 88 00 00   // plan is load? turn to heading 05 and start loading
00 00         // else ^^

// HANGAR EXIT NODE 00 ===
   80 * 14	 02 0D 00 81 18 00 F0 01
07 81 00 00 // set aircraft state to 07 taxiing
01 80       // head for bay node 01

//!!Error (203): Offset 10: No persistent registers exist for this feature.
   81 * 21	 02 0D 10 81 7C 01 60 FE 01 \b1 10 1A 00 \b1  // mark bay occupied
01 00 00 00 00 00 00                                     // then ^^

   82 * 15	 02 0D 00 81 7C 01 00 41 01
01 84 01 41   // enter/remain in hangar if bay is occupied or aircraft is waiting to taxi in
10 00         // else ^^

   83 * 14	 02 0D 00 81 18 00 F0 01 // iteration check for occupation check
00 00 00 00
10 00       // skip check on subsequent iteration

   84 * 14	 02 0D 00 81 18 00 0F 01
01 84 01 02   // plan is hangar?  enter hangar #1.
00 00         // else ^^

// HANGAR NODE 11 ===
//!!Error (203): Offset 10: No persistent registers exist for this feature.
   85 * 21	 02 0D 11 81 7C 01 60 FE 00 \b1 10 1A 00 \b1  // mark bay clear
01 01 84 00 00 01 84                                     // then enter hangar #1

// TOUCHDOWN POINT 10 ===
   86 * 14	 02 0D 10 81 18 00 F0 01
16 81 00 00 // set aircraft state to 16 braking on the runway
03 80       // head for rollout end node 03

//!!Error (203): Offset 10: No persistent registers exist for this feature.
   87 * 21	 02 0D 10 81 7C 01 60 DD 02 \b1 10 1A 00 \b1  // mark runway occupied and aircraft approaching clear
01 10 00 00 00 10 00                                     // then ^^

   88 * 82	 02 0D AA 81 10 00 FF 12 // which node is triggered?
00 00 00 00 // 00 hangar exit
01 00 01 01 // 01 bay
02 00 02 02 // 02 liftoff point
03 00 03 03 // 03 rollout end
04 00 04 04 // 04 runway junction
05 00 05 05 // 05 takeoff turn
06 00 06 06 // 06 turn crosswind
07 00 07 07 // 07 crosswind leg (entry point)
09 80 08 08 // 08 turn downwind
09 00 09 09 // 09 downwind leg (entry point)
0B 80 0A 0A // 0A turn base
0B 00 0B 0B // 0B base leg (entry point)             
0D 80 0C 0C // 0C turn final
0D 00 0D 0D // 0D final (entry point)
0E 00 0E 0E // 0E helicopter hover point
0F 00 0F 0F // 0F fenceline decision point
10 00 10 10 // 10 touchdown point
11 00 11 11 // 11 hangar entry
00 8F       // leave the state machine and fly to next destination

//!!Error (164): Offset 11: 4E 01 is not a valid callback for this feature.
   89 * 17	 02 0D AA 85 0C 00 FF FF 01 AA 00 4e 01 4e 01 FF 00 // statemachine callback
   90 * 7	 03 0D 01 00 00 AA 00

Personal tools