Loading

Paste #pzjtzla8o

  1. input nml:
  2.  
  3. spriteset(stationset1, "src/gfx/cc_grid.png") { tmpl_groundsprites(1, 1) }
  4.  
  5. spritegroup spritegroup1 {
  6.   little: [ stationset1 ];
  7. }
  8.  
  9. spriteset(stationset2, "src/gfx/cc_build.png") { tmpl_buildingsprites(1, 1) }
  10.  
  11. spritegroup spritegroup2 {
  12.   little: [ stationset2 ];
  13. }
  14.  
  15. spritelayout stationlayout2 {
  16.  ground {
  17.   sprite: spritegroup1(0)
  18.  }
  19.  building {
  20.   sprite: spritegroup2(0)
  21.  }
  22. }
  23.  
  24. switch (FEAT_STATION, SELF, switch3, [ ... ] {
  25.   ...
  26.   stationlayout2;
  27. }
  28.  
  29. item(FEAT_STATION, station4) {
  30.   property {
  31.     ... nothing about layouts here ...
  32.   }
  33.   graphics {
  34.     switch3;
  35.   }
  36. }
  37.  
  38.  
  39. output grf:
  40.  
  41. action0:
  42.   layout0: stationlayout2 using var10=0 for ground, var10=1 for building1
  43.  
  44. action3
  45. ->  varactions according to switch3
  46.     -> varaction(var0C)
  47.          14: return layout0
  48.          default:
  49.            -> varaction(var10)
  50.               0: return stationgroup1
  51.               1: return stationgroup2

Comments