// Token: 0x06000007 RID: 7 RVA: 0x000021E0 File Offset: 0x000003E0 private Thing FindIngredient(Pawn pawn, ThingOrderRequest request) { if (request == null) { return(null); } var extraPredicate = request.ExtraPredicate(); bool validator(Thing x) { return(!x.IsForbidden(pawn) && pawn.CanReserve(x) && extraPredicate(x)); } return(GenClosest.ClosestThingReachable(pawn.Position, pawn.Map, request.Request(), PathEndMode.ClosestTouch, TraverseParms.For(pawn), 9999f, validator)); }
// Token: 0x0600000F RID: 15 RVA: 0x000022AC File Offset: 0x000004AC public IEnumerable <ThingOrderRequest> PendingRequests() { foreach (var requestedItem in requestedItems) { float num = thingHolder.TotalStackCountOfDef(requestedItem.thingDef); if (!(num < requestedItem.amount)) { continue; } var thingOrderRequest = new ThingOrderRequest { thingDef = requestedItem.thingDef, amount = requestedItem.amount - num }; yield return(thingOrderRequest); } }