feat: 请求量pop位置调整
This commit is contained in:
parent
fc25e2bd1c
commit
f60629aadf
|
|
@ -20,11 +20,4 @@ public class CraftingTreeNodeMixin {
|
|||
// push the requestedAmount before addContainerItems is called
|
||||
RequestedAmountHolder.push(requestedAmount);
|
||||
}
|
||||
|
||||
@Inject(method = "request(Lappeng/crafting/inv/CraftingSimulationState;JLappeng/api/stacks/KeyCounter;)V",
|
||||
at = @At(value = "RETURN"))
|
||||
private void clearRequestedAmountOnReturn(CraftingSimulationState inv, long requestedAmount, KeyCounter containerItems, CallbackInfo ci) {
|
||||
// pop the pushed requested amount on return
|
||||
RequestedAmountHolder.pop();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -55,6 +55,7 @@ public abstract class CraftingTreeProcessMixin {
|
|||
CraftingTreeNodeAccessor parentAcc = (CraftingTreeNodeAccessor) craftingTreeNode;
|
||||
AEKey parentTarget = parentAcc.eap$getWhat();
|
||||
long requested = RequestedAmountHolder.get();
|
||||
RequestedAmountHolder.pop();
|
||||
|
||||
// 根据配置决定是否在 provider 间轮询分配请求量(默认开启)
|
||||
long perProvider = 1L;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user