mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-01-25 22:58:47 +07:00
Update BlockInventoryFragment.java
This commit is contained in:
parent
124480f96b
commit
7871b5bdaa
@ -42,6 +42,7 @@ public class BlockInventoryFragment extends Fragment{
|
||||
int removed = tile.block().removeStack(tile, item, amount);
|
||||
|
||||
player.addItem(item, removed);
|
||||
Events.fire(new WithdrawEvent(tile, player, item, amount));
|
||||
for(int j = 0; j < Mathf.clamp(removed / 3, 1, 8); j++){
|
||||
Time.run(j * 3f, () -> Call.transferItemEffect(item, tile.drawx(), tile.drawy(), player));
|
||||
}
|
||||
@ -100,7 +101,7 @@ public class BlockInventoryFragment extends Fragment{
|
||||
holding = false;
|
||||
holdTime = 0f;
|
||||
|
||||
Events.fire(new WithdrawEvent());
|
||||
Events.fire(new WithdrawEvent(tile, player, item, amount));
|
||||
}
|
||||
}
|
||||
|
||||
@ -153,7 +154,7 @@ public class BlockInventoryFragment extends Fragment{
|
||||
lastItem = item;
|
||||
holding = true;
|
||||
holdTime = 0f;
|
||||
Events.fire(new WithdrawEvent());
|
||||
Events.fire(new WithdrawEvent(tile, player, item, amount));
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user