hedgewars/uLandObjects.pas
changeset 1097 06b15817b8a0
parent 1085 0b82870073b5
child 1131 c5b8f2bfa487
equal deleted inserted replaced
1096:213286baaee4 1097:06b15817b8a0
    24 procedure AddObjects(InSurface, Surface: PSDL_Surface);
    24 procedure AddObjects(InSurface, Surface: PSDL_Surface);
    25 procedure LoadThemeConfig;
    25 procedure LoadThemeConfig;
    26 procedure BlitImageAndGenerateCollisionInfo(cpX, cpY: Longword; Image, Surface: PSDL_Surface);
    26 procedure BlitImageAndGenerateCollisionInfo(cpX, cpY: Longword; Image, Surface: PSDL_Surface);
    27 
    27 
    28 implementation
    28 implementation
    29 uses uLand, uStore, uConsts, uMisc, uConsole, uRandom, uVisualGears, uFloat, GL;
    29 uses uLand, uStore, uConsts, uMisc, uConsole, uRandom, uVisualGears, uFloat, GL, uSound;
    30 const MaxRects = 256;
    30 const MaxRects = 256;
    31       MAXOBJECTRECTS = 16;
    31       MAXOBJECTRECTS = 16;
    32       MAXTHEMEOBJECTS = 32;
    32       MAXTHEMEOBJECTS = 32;
    33 
    33 
    34 type PRectArray = ^TRectsArray;
    34 type PRectArray = ^TRectsArray;
   371 Readln(f, c2.r, c2.g, c2. b);
   371 Readln(f, c2.r, c2.g, c2. b);
   372 
   372 
   373 glClearColor(c1.r / 255, c1.g / 255, c1.b / 255, 0.99); // sky color
   373 glClearColor(c1.r / 255, c1.g / 255, c1.b / 255, 0.99); // sky color
   374 cExplosionBorderColor:= c2.value or $FF000000;
   374 cExplosionBorderColor:= c2.value or $FF000000;
   375 
   375 
       
   376 ReadLn(f, s);
       
   377 if MusicFN = '' then MusicFN:= s;
       
   378 
   376 Readln(f, ThemeObjects.Count);
   379 Readln(f, ThemeObjects.Count);
   377 for i:= 0 to Pred(ThemeObjects.Count) do
   380 for i:= 0 to Pred(ThemeObjects.Count) do
   378     begin
   381     begin
   379     Readln(f, s); // filename
   382     Readln(f, s); // filename
   380     with ThemeObjects.objs[i] do
   383     with ThemeObjects.objs[i] do