# HG changeset patch # User sheepluva # Date 1463305027 -7200 # Node ID fe339879cf7594c4d1c063ce6263300422603a5e # Parent 93621207563bd0d600d5612e897b8e608ad040f7# Parent 7642955690bccd79ae3da5b6b2b706cc79a5256e merge Wuzzy's frontend tweaks diff -r 7642955690bc -r fe339879cf75 .travis.yml --- a/.travis.yml Fri May 06 20:12:27 2016 +0200 +++ b/.travis.yml Sun May 15 11:37:07 2016 +0200 @@ -1,5 +1,5 @@ language: c -sudo: false +sudo: true os: - linux - osx diff -r 7642955690bc -r fe339879cf75 hedgewars/avwrapper/avwrapper.c --- a/hedgewars/avwrapper/avwrapper.c Fri May 06 20:12:27 2016 +0200 +++ b/hedgewars/avwrapper/avwrapper.c Sun May 15 11:37:07 2016 +0200 @@ -447,11 +447,11 @@ if (!(x & 1) && !(y & 1)) { int r = (buf[x * 4 + 0] + buf[(x + 1) * 4 + 0] + - buf[x * 4 + 0 + stride] + buf[(x + 1) * 4 + 0 + stride]) / 4; + buf[x * 4 + 0 - stride] + buf[(x + 1) * 4 + 0 - stride]) / 4; int g = (buf[x * 4 + 1] + buf[(x + 1) * 4 + 1] + - buf[x * 4 + 1 + stride] + buf[(x + 1) * 4 + 1 + stride]) / 4; + buf[x * 4 + 1 - stride] + buf[(x + 1) * 4 + 1 - stride]) / 4; int b = (buf[x * 4 + 2] + buf[(x + 1) * 4 + 2] + - buf[x * 4 + 2 + stride] + buf[(x + 1) * 4 + 2 + stride]) / 4; + buf[x * 4 + 2 - stride] + buf[(x + 1) * 4 + 2 - stride]) / 4; int cr = (int)(-0.14713f * r - 0.28886f * g + 0.436f * b); int cb = (int)( 0.615f * r - 0.51499f * g - 0.10001f * b); diff -r 7642955690bc -r fe339879cf75 hedgewars/uGears.pas --- a/hedgewars/uGears.pas Fri May 06 20:12:27 2016 +0200 +++ b/hedgewars/uGears.pas Sun May 15 11:37:07 2016 +0200 @@ -876,7 +876,7 @@ if PlacingHogs then ar[i]^.Unplaced:= true else - FindPlace(ar[i]^.Gear, false, leftX, playWidth, true); + FindPlace(ar[i]^.Gear, false, leftX, rightX, true); if ar[i]^.Gear <> nil then begin ar[i]^.Gear^.dX.isNegative:= hwRound(ar[i]^.Gear^.X) > leftX + playWidth div 2; diff -r 7642955690bc -r fe339879cf75 hedgewars/uGearsRender.pas --- a/hedgewars/uGearsRender.pas Fri May 06 20:12:27 2016 +0200 +++ b/hedgewars/uGearsRender.pas Sun May 15 11:37:07 2016 +0200 @@ -1270,7 +1270,7 @@ end; gtDynamite: begin DrawSprite(sprDynamite, x - 16, y - 25, Gear^.Tag and 1, Gear^.Tag shr 1); - if (random(3) = 0) then + if (random(3) = 0) and ((Gear^.State and gstDrowning) = 0) then begin vg:= AddVisualGear(hwRound(Gear^.X)+12-(Gear^.Tag shr 1), hwRound(Gear^.Y)-16, vgtStraightShot); if vg <> nil then