Only deliver reasonable clients

This commit is contained in:
Geoffrey Frogeye 2016-02-13 14:09:31 +01:00
parent 1c5f23d624
commit f31e6e74c8

View file

@ -272,6 +272,7 @@ try:
for c in Client.near(Warehouse.get(0).pos):
if d < Drone.len():
pack = c.pack()
if len(pack) == len(c.needs):
for i in pack:
Drone.get(d).addTask('load', Warehouse.get(0), Product.get(i), 1)
for i in pack: