mirror of
https://github.com/Grasscutters/Grasscutter.git
synced 2025-01-09 03:22:52 +08:00
Medicine revival&Login white screen (#1883)
* Update InventorySystem.java -:[fix] Medicine revival * Update GameMainQuest.java -:[fix] Login white screen
This commit is contained in:
parent
c51f7610b2
commit
ccf182d692
@ -167,7 +167,7 @@ public class GameMainQuest {
|
||||
boolean didRewind = false;
|
||||
for (GameQuest quest : sortedByOrder) {
|
||||
int i = sortedByOrder.indexOf(quest);
|
||||
if ( i == sortedByOrder.size()) {
|
||||
if ( (i+1) >= sortedByOrder.size()) {
|
||||
didRewind = quest.rewind(null);
|
||||
} else {
|
||||
didRewind = quest.rewind(sortedByOrder.get(i+1));
|
||||
|
@ -778,7 +778,7 @@ public class InventorySystem extends BaseGameSystem {
|
||||
}
|
||||
|
||||
int[] satiationParams = itemData.getSatiationParams();
|
||||
if (satiationParams != null && target.isPresent()) {
|
||||
if (satiationParams != null && satiationParams.length > 0 && target.isPresent()) {
|
||||
// Invoke and call player use food event.
|
||||
var event = new PlayerUseFoodEvent(params.player, itemData, params.targetAvatar.getAsEntity()); event.call();
|
||||
if (event.isCanceled()) return false;
|
||||
|
Loading…
Reference in New Issue
Block a user