IEnumerable<Actor> GetOrderedActors()
{
if (Game.GameId == GameId.SamNMax)
{
return from actor in Actors.Skip(1)
where actor.IsInCurrentRoom
where actor.Layer >= 0
orderby actor.Position.Y, actor.Number
select actor;
}
else if (Game.Version == 0)
{
return from actor in Actors.Skip(1)
where actor.IsInCurrentRoom
orderby actor.Number==19? 0 : actor.Position.Y
select actor;
}
return from actor in Actors.Skip(1)
where actor.IsInCurrentRoom
where (Game.Version != 8 || actor.Layer >= 0)
orderby actor.Position.Y - actor.Layer*2000
select actor;
}