public static void main(String[] args) { Animate.animate( "Zombicus humans", (Cell<Double> time, Stream<Unit> sTick, Dimension windowSize) -> { World world = new World(windowSize); List<Cell<Character>> chars = new ArrayList<>(); int id = 0; for (int x = 100; x < windowSize.width; x += 100) for (int y = 150; y < windowSize.height; y += 150) { Point pos0 = new Point(x, y); HomoSapiens h = new HomoSapiens(world, id, pos0, time, sTick); chars.add(h.character); id++; } return sequence(chars); }); }