mirror of
https://github.com/MineLittlePony/MineLittlePony.git
synced 2025-02-16 17:44:23 +01:00
Fixed resource reloading
This commit is contained in:
parent
11391b6ed3
commit
00fec6900a
1 changed files with 11 additions and 5 deletions
|
@ -140,12 +140,18 @@ public class PonyManager implements IPonyManager, ResourceReloadListener, ISkinC
|
|||
}
|
||||
|
||||
@Override
|
||||
public CompletableFuture<Void> reload(Synchronizer sync, ResourceManager sender, Profiler profiler, Profiler profile2, Executor backendExecutor, Executor mainThreadExecutor) {
|
||||
return CompletableFuture.runAsync(() -> {
|
||||
profiler.push("Reloading all background ponies");
|
||||
public CompletableFuture<Void> reload(Synchronizer sync, ResourceManager sender,
|
||||
Profiler serverProfiler, Profiler clientProfiler,
|
||||
Executor serverExecutor, Executor clientExecutor) {
|
||||
|
||||
sync.getClass();
|
||||
return sync.whenPrepared(null).thenRunAsync(() -> {
|
||||
clientProfiler.startTick();
|
||||
clientProfiler.push("Reloading all background ponies");
|
||||
reloadAll(sender);
|
||||
profiler.endTick();
|
||||
}, backendExecutor);
|
||||
clientProfiler.pop();
|
||||
clientProfiler.endTick();
|
||||
}, clientExecutor);
|
||||
}
|
||||
|
||||
public void reloadAll(ResourceManager resourceManager) {
|
||||
|
|
Loading…
Reference in a new issue