Пример #1
0
 public void CrystalCollected(Crystal c)
 {
     this._crystalsCollected.Add(c.CrystalId);
 }
Пример #2
0
 private static Crystal GetCrystal(World world, XmlElement cdef)
 {
     var id = int.Parse(cdef.GetAttribute("Id"));
     var tilePos = new TilePos(int.Parse(cdef.GetAttribute("Left")), int.Parse(cdef.GetAttribute("Top")));
     var position = tilePos.ToPosition();
     var score = int.Parse(cdef.GetAttribute("Score"));
     var energy = int.Parse(cdef.GetAttribute("Energy"));
     var result = new Crystal(world, position, id, score, energy);
     return result;
 }