# HG changeset patch # User sheepluva # Date 1506717195 -7200 # Node ID d6bd8b327a09f7c04b0a6182bb9cc90e28c7cb70 # Parent 00b539e6115d0df35c398dbdf01f038474090c32 don't use colorkey for land spray this fixes issue #220 diff -r 00b539e6115d -r d6bd8b327a09 hedgewars/uConsts.pas --- a/hedgewars/uConsts.pas Fri Sep 29 22:09:11 2017 +0200 +++ b/hedgewars/uConsts.pas Fri Sep 29 22:33:15 2017 +0200 @@ -90,10 +90,11 @@ rqDesyncVBlank= $00000800; // don't sync on vblank // image flags (for LoadImage()) + // TODO: discuss whether ifAlpha and ifColorKey are actually needed and if and where we want to support which colorkeys ifNone = $00000000; // nothing special ifAlpha = $00000001; // use alpha channel (unused right now?) ifCritical = $00000002; // image is critical for gameplay (exit game if unable to load) - ifColorKey = $00000004; // image uses transparent pixels (color keying) + ifColorKey = $00000004; // image uses transparent pixels (color keying) ifIgnoreCaps = $00000008; // ignore hardware capabilities when loading (i.e. image will not be drawn using OpenGL) // texture priority (allows OpenGL to keep frequently used textures in video memory more easily) diff -r 00b539e6115d -r d6bd8b327a09 hedgewars/uLandObjects.pas --- a/hedgewars/uLandObjects.pas Fri Sep 29 22:09:11 2017 +0200 +++ b/hedgewars/uLandObjects.pas Fri Sep 29 22:33:15 2017 +0200 @@ -762,7 +762,7 @@ with SprayObjects.objs[Pred(SprayObjects.Count)] do begin i:= Pos(',', s); - Surf:= LoadDataImage(ptCurrTheme, Trim(Copy(s, 1, Pred(i))), ifColorKey or ifIgnoreCaps); + Surf:= LoadDataImage(ptCurrTheme, Trim(Copy(s, 1, Pred(i))), ifAlpha or ifIgnoreCaps); Width:= Surf^.w; Height:= Surf^.h; Delete(s, 1, i);