IAssignment IJobSource.FindAssignment(ILivingObject living) { if (m_itemTracker.IsEnabled == false) { return(null); } var ob = m_itemTracker.GetFirst(); if (ob == null) { return(null); } var job = new StoreToStockpileJob(this, this, ob); m_jobs.Add(job); this.Environment.World.Jobs.Add(job); ob.ReservedBy = this; return(job); }
IAssignment IJobSource.FindAssignment(ILivingObject living) { if (m_itemTracker.IsEnabled == false) return null; var ob = m_itemTracker.GetFirst(); if (ob == null) return null; var job = new StoreToStockpileJob(this, this, ob); m_jobs.Add(job); this.Environment.World.Jobs.Add(job); ob.ReservedBy = this; return job; }