Closed Ad-Blokker closed 9 months ago
3 player in game 1 player sleeping 1/2 players to skip
1 Player leaves 2 Players in game 1 Sleeping 1/2 players to skip night
2 Players in game 2 Players sleeping 2/1 Players to skip night
Night is not being skipped, even tough more than needed are sleeping and minecraft says sleeping through this night
Player 3 joins the game 3 Players in the game 2 Players sleeping Still nothing
Player 1 that first entered the bed leaves the bed and re-enters
Skipping night is successful
In PlayerSleepStateChangeEventListener.java line 99, there is the following code: if(this.sleepService.getSleepersAmount(world) > this.sleepService.getRequiredSleepersCount(world))
and when this evaluates to true, it doesn't register the night skipping task. Shouldn't that be a less than sign so that if the number of sleepers is greater than the number of required sleepers it skips the night?
In PlayerSleepStateChangeEventListener.java line 99, there is the following code:
if(this.sleepService.getSleepersAmount(world) > this.sleepService.getRequiredSleepersCount(world))
and when this evaluates to true, it doesn't register the night skipping task. Shouldn't that be a less than sign so that if the number of sleepers is greater than the number of required sleepers it skips the night?
Hello @binarybrain11 You are right. I don't have time now but Will look into it tomorrow. Feel free to fix it and submit a pr.
Kr mrgeneralQ
Solved in #179
Describe the bug The check on how many people need to sleep has an inconsistency.
To Reproduce Steps to reproduce the behavior:
Expected behavior Dynamically change the skip amount needed when players leave / join / enter or leave the bed, therefore skipping the night when player amount needed changes
Screenshots N/A
Desktop (please complete the following information):
Additional context N/A