remove 'private' keyword where possible

This commit is contained in:
Chris Forbes
2011-06-29 09:15:39 +12:00
parent 587b2ef0d1
commit 0e45968573
16 changed files with 27 additions and 34 deletions

View File

@@ -19,7 +19,7 @@ namespace OpenRA.Mods.RA.Air
{
public readonly int2 Pos;
private Fly( int2 px ) { Pos = px; }
Fly( int2 px ) { Pos = px; }
public static Fly ToPx( int2 px ) { return new Fly( px ); }
public static Fly ToCell( int2 pos ) { return new Fly( Util.CenterOfCell( pos ) ); }

View File

@@ -29,9 +29,8 @@ namespace OpenRA.Mods.RA
class Contrail : ITick, IPostRender
{
private ContrailInfo Info = null;
private Turret ContrailTurret = null;
ContrailInfo Info = null;
Turret ContrailTurret = null;
ContrailHistory history;

View File

@@ -439,7 +439,7 @@ namespace OpenRA.Mods.RA
}
//Build a random unit of the given type. Not going to be needed once there is actual AI...
private void BuildRandom(string category)
void BuildRandom(string category)
{
// Pick a free queue
var queue = world.ActorsWithTrait<ProductionQueue>()

View File

@@ -21,7 +21,7 @@ namespace OpenRA.Mods.RA
class DefaultShellmapScript: IWorldLoaded, ITick
{
Dictionary<string, Actor> Actors;
private static int2 ViewportOrigin;
static int2 ViewportOrigin;
public void WorldLoaded(World w)
{

View File

@@ -13,14 +13,11 @@ using OpenRA.Traits;
namespace OpenRA.Mods.RA
{
class SurrenderOnDisconnectInfo : TraitInfo<SurrenderOnDisconnect>
{
}
class SurrenderOnDisconnectInfo : TraitInfo<SurrenderOnDisconnect> {}
class SurrenderOnDisconnect : ITick
{
private bool Disconnected = false;
bool Disconnected = false;
public void Tick(Actor self)
{

View File

@@ -87,7 +87,7 @@ namespace OpenRA.Mods.RA
}
}
private void ChangeOwnership(Actor self, Player previousOwner, Player originalOwner)
void ChangeOwnership(Actor self, Player previousOwner, Player originalOwner)
{
self.World.AddFrameEndTask(w =>
{
@@ -108,7 +108,7 @@ namespace OpenRA.Mods.RA
});
}
private void ChangeOwnership(Actor self, Actor captor, Player previousOwner)
void ChangeOwnership(Actor self, Actor captor, Player previousOwner)
{
self.World.AddFrameEndTask(w =>
{