diff --git a/OpenRA.FileFormats/Map/Map.cs b/OpenRA.FileFormats/Map/Map.cs index c256789833..7628b57e17 100644 --- a/OpenRA.FileFormats/Map/Map.cs +++ b/OpenRA.FileFormats/Map/Map.cs @@ -117,7 +117,6 @@ namespace OpenRA.FileFormats public void Save(string filepath) { Dictionary root = new Dictionary(); - var d = new Dictionary(); foreach (var field in SimpleFields) { FieldInfo f = this.GetType().GetField(field); diff --git a/OpenRA.FileFormats/MiniYaml.cs b/OpenRA.FileFormats/MiniYaml.cs index 3abf5aa3df..dbd732d36b 100755 --- a/OpenRA.FileFormats/MiniYaml.cs +++ b/OpenRA.FileFormats/MiniYaml.cs @@ -47,7 +47,6 @@ namespace OpenRA.FileFormats public static MiniYaml FromList(Listlist) { - var d = new Dictionary(); return new MiniYaml( null, list.ToDictionary( x=>x.ToString(), x=>new MiniYaml(null))); } diff --git a/OpenRA.Game/Chrome.cs b/OpenRA.Game/Chrome.cs index a4c0b0a7a9..bd4d808dba 100644 --- a/OpenRA.Game/Chrome.cs +++ b/OpenRA.Game/Chrome.cs @@ -83,7 +83,6 @@ namespace OpenRA // mapchooser Sheet mapChooserSheet; Sprite mapChooserSprite; - int mapOffset = 0; public Chrome(Renderer r, Manifest m) { @@ -260,9 +259,7 @@ namespace OpenRA rgbaRenderer.Flush(); var y = r.Top + 50; - - int maxListItems = ((r.Bottom - 60 - y ) / 20); - + // Don't bother showing a subset of the data // This will be fixed properly when we move the map list to widgets foreach (var kv in Game.AvailableMaps) @@ -814,7 +811,6 @@ namespace OpenRA } } - // Return an int telling us the y coordinate at the bottom of the palette int DrawBuildPalette( World world, string queueName ) { diff --git a/OpenRA.Game/Game.cs b/OpenRA.Game/Game.cs index 6dfa10385a..7c59e10453 100644 --- a/OpenRA.Game/Game.cs +++ b/OpenRA.Game/Game.cs @@ -78,7 +78,6 @@ namespace OpenRA // Mod assemblies assumed to contain a single namespace foreach (var a in m.Assemblies) { - var failures = new List(); var fullpath = Path.GetFullPath(a); var asm = Assembly.LoadFile(fullpath); diff --git a/OpenRA.Game/Server/Server.cs b/OpenRA.Game/Server/Server.cs index b4bbbd7c7a..e223c2a570 100644 --- a/OpenRA.Game/Server/Server.cs +++ b/OpenRA.Game/Server/Server.cs @@ -492,8 +492,7 @@ namespace OpenRA.Server lobbyInfo.Clients.RemoveAll(c => c.Index == toDrop.PlayerIndex); - foreach( var c in conns ) - DispatchOrders( toDrop, toDrop.MostRecentFrame, new byte[] { 0xbf } ); + DispatchOrders( toDrop, toDrop.MostRecentFrame, new byte[] { 0xbf } ); if (conns.Count == 0) OnServerEmpty(); else SyncLobbyInfo(); diff --git a/OpenRA.Game/ShroudRenderer.cs b/OpenRA.Game/ShroudRenderer.cs index 5f3977e7a6..05a1772763 100644 --- a/OpenRA.Game/ShroudRenderer.cs +++ b/OpenRA.Game/ShroudRenderer.cs @@ -33,7 +33,6 @@ namespace OpenRA bool dirty = true; bool disabled = false; - Player owner; Map map; public Rectangle? bounds { get { return shroud.exploredBounds; } } @@ -41,7 +40,6 @@ namespace OpenRA public ShroudRenderer(Player owner, Map map) { this.shroud = owner.World.WorldActor.traits.Get(); - this.owner = owner; this.map = map; sprites = new Sprite[map.MapSize.X, map.MapSize.Y]; diff --git a/OpenRA.Game/Widgets/SpecialPowerBinWidget.cs b/OpenRA.Game/Widgets/SpecialPowerBinWidget.cs index d7cfa5c0e8..5ee57c4d3d 100644 --- a/OpenRA.Game/Widgets/SpecialPowerBinWidget.cs +++ b/OpenRA.Game/Widgets/SpecialPowerBinWidget.cs @@ -34,7 +34,6 @@ namespace OpenRA.Widgets Animation ready; Animation clock; readonly List>> buttons = new List>>(); - string chromeCollection; public override void Initialize() { @@ -87,9 +86,6 @@ namespace OpenRA.Widgets var numPowers = powers.Count(p => p.IsAvailable); if (numPowers == 0) return; - SupportPower tooltipItem = null; - int2 tooltipPos = int2.Zero; - WidgetUtils.DrawRGBA(WidgetUtils.GetChromeImage(world, "specialbin-top"),new float2(Bounds.X,Bounds.Y)); for (var i = 1; i < numPowers; i++) WidgetUtils.DrawRGBA(WidgetUtils.GetChromeImage(world,"specialbin-middle"), new float2(Bounds.X, Bounds.Y + i * 51)); @@ -112,9 +108,7 @@ namespace OpenRA.Widgets if (rect.Contains(Game.chrome.lastMousePos.ToPoint())) { - var pos = drawPos.ToInt2(); - var tooltipBounds = new Rectangle(pos.X-3,pos.Y-3,350,54); - + var pos = drawPos.ToInt2(); var tl = new int2(pos.X-3,pos.Y-3); var m = new int2(pos.X+64+3,pos.Y+48+3); var br = tl + new int2(64+3+20,60); diff --git a/OpenRA.Mods.RA/Activities/DeliverOre.cs b/OpenRA.Mods.RA/Activities/DeliverOre.cs index c75df825dd..6039b6a145 100755 --- a/OpenRA.Mods.RA/Activities/DeliverOre.cs +++ b/OpenRA.Mods.RA/Activities/DeliverOre.cs @@ -67,8 +67,6 @@ namespace OpenRA.Mods.RA.Activities public IActivity Tick( Actor self ) { - var mobile = self.traits.Get(); - if( NextActivity != null ) return NextActivity; diff --git a/OpenRA.Mods.RA/C4Demolition.cs b/OpenRA.Mods.RA/C4Demolition.cs index e2a7599e2b..0be8ab91ca 100644 --- a/OpenRA.Mods.RA/C4Demolition.cs +++ b/OpenRA.Mods.RA/C4Demolition.cs @@ -32,11 +32,7 @@ namespace OpenRA.Mods.RA class C4Demolition : IIssueOrder, IResolveOrder { - Actor self; - public C4Demolition(Actor self) - { - this.self = self; - } + public C4Demolition(Actor self) {} public Order IssueOrder(Actor self, int2 xy, MouseInput mi, Actor underCursor) {