equal
deleted
inserted
replaced
261 p: PLongwordArray; |
261 p: PLongwordArray; |
262 begin |
262 begin |
263 TryDo(Surface <> nil, 'Assert (LandSurface <> nil) failed', true); |
263 TryDo(Surface <> nil, 'Assert (LandSurface <> nil) failed', true); |
264 |
264 |
265 if SDL_MustLock(Surface) then |
265 if SDL_MustLock(Surface) then |
266 SDLTry(SDL_LockSurface(Surface) >= 0, true); |
266 SDLTry(SDL_LockSurface(Surface) >= 0, 'SDL_LockSurface', true); |
267 |
267 |
268 p:= Surface^.pixels; |
268 p:= Surface^.pixels; |
269 for y:= 0 to LAND_HEIGHT - 1 do |
269 for y:= 0 to LAND_HEIGHT - 1 do |
270 begin |
270 begin |
271 for x:= 0 to LAND_WIDTH - 1 do |
271 for x:= 0 to LAND_WIDTH - 1 do |
449 disableLandBack:= true; |
449 disableLandBack:= true; |
450 |
450 |
451 cpX:= (LAND_WIDTH - tmpsurf^.w) div 2; |
451 cpX:= (LAND_WIDTH - tmpsurf^.w) div 2; |
452 cpY:= LAND_HEIGHT - tmpsurf^.h; |
452 cpY:= LAND_HEIGHT - tmpsurf^.h; |
453 if SDL_MustLock(tmpsurf) then |
453 if SDL_MustLock(tmpsurf) then |
454 SDLTry(SDL_LockSurface(tmpsurf) >= 0, true); |
454 SDLTry(SDL_LockSurface(tmpsurf) >= 0, 'SDL_LockSurface', true); |
455 |
455 |
456 p:= tmpsurf^.pixels; |
456 p:= tmpsurf^.pixels; |
457 for y:= 0 to Pred(tmpsurf^.h) do |
457 for y:= 0 to Pred(tmpsurf^.h) do |
458 begin |
458 begin |
459 for x:= 0 to Pred(tmpsurf^.w) do |
459 for x:= 0 to Pred(tmpsurf^.w) do |