2 using System.Collections.Generic;
13 public Vector Value {
get;
set; }
18 public TimeSpan CreationTime {
get;
private set; }
23 public TimeSpan Lifetime
32 public TimeSpan MaximumLifetime {
get;
set; }
34 public Force( Vector f )
37 CreationTime = Game.Time.SinceStartOfGame;
38 MaximumLifetime = TimeSpan.MaxValue;
41 public Force( Vector f, TimeSpan t )
44 MaximumLifetime = CreationTime + t;
50 public virtual void Destroy()
52 this.MaximumLifetime = TimeSpan.Zero;
55 public bool IsDestroyed()
57 return Lifetime > MaximumLifetime;
TimeSpan SinceStartOfGame
Aika joka on kulunut pelin alusta.
Sisältää tiedon ajasta, joka on kulunut pelin alusta ja viime päivityksestä.