explosions
This commit is contained in:
@@ -8,7 +8,7 @@ namespace OpenRa.Game
|
||||
class World
|
||||
{
|
||||
List<Actor> actors = new List<Actor>();
|
||||
List<IEffect> bullets = new List<IEffect>();
|
||||
List<IEffect> effects = new List<IEffect>();
|
||||
List<Action<World>> frameEndActions = new List<Action<World>>();
|
||||
readonly Game game;
|
||||
int lastTime = Environment.TickCount;
|
||||
@@ -19,8 +19,8 @@ namespace OpenRa.Game
|
||||
public void Add(Actor a) { actors.Add(a); ActorAdded(a); }
|
||||
public void Remove(Actor a) { actors.Remove(a); ActorRemoved(a); }
|
||||
|
||||
public void Add(Bullet b) { bullets.Add(b); }
|
||||
public void Remove(Bullet b) { bullets.Remove(b); }
|
||||
public void Add(IEffect b) { effects.Add(b); }
|
||||
public void Remove(IEffect b) { effects.Remove(b); }
|
||||
|
||||
public void AddFrameEndTask( Action<World> a ) { frameEndActions.Add( a ); }
|
||||
|
||||
@@ -42,7 +42,7 @@ namespace OpenRa.Game
|
||||
|
||||
foreach( var a in actors )
|
||||
a.Tick(game);
|
||||
foreach (var b in bullets)
|
||||
foreach (var b in effects)
|
||||
b.Tick(game);
|
||||
|
||||
Renderer.waterFrame += 0.00125f * timestep;
|
||||
@@ -53,6 +53,6 @@ namespace OpenRa.Game
|
||||
}
|
||||
|
||||
public IEnumerable<Actor> Actors { get { return actors; } }
|
||||
public IEnumerable<IEffect> Bullets { get { return bullets; } }
|
||||
public IEnumerable<IEffect> Effects { get { return effects; } }
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user