mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-01-07 05:50:54 +07:00
parent
c22ede229e
commit
758921c077
@ -191,6 +191,7 @@ const PlayEvent = Packages.mindustry.game.EventType.PlayEvent
|
||||
const DisposeEvent = Packages.mindustry.game.EventType.DisposeEvent
|
||||
const ServerLoadEvent = Packages.mindustry.game.EventType.ServerLoadEvent
|
||||
const ClientCreateEvent = Packages.mindustry.game.EventType.ClientCreateEvent
|
||||
const SaveWriteEvent = Packages.mindustry.game.EventType.SaveWriteEvent
|
||||
const SaveLoadEvent = Packages.mindustry.game.EventType.SaveLoadEvent
|
||||
const MapPublishEvent = Packages.mindustry.game.EventType.MapPublishEvent
|
||||
const MapMakeEvent = Packages.mindustry.game.EventType.MapMakeEvent
|
||||
|
@ -299,6 +299,7 @@ public class Renderer implements ApplicationListener{
|
||||
Draw.draw(Layer.overlayUI, overlays::drawTop);
|
||||
Draw.draw(Layer.space, this::drawLanding);
|
||||
|
||||
Events.fire(Trigger.drawOver);
|
||||
blocks.drawBlocks();
|
||||
|
||||
Groups.draw.draw(Drawc::draw);
|
||||
|
@ -33,6 +33,7 @@ public class EventType{
|
||||
socketConfigChanged,
|
||||
update,
|
||||
draw,
|
||||
drawOver,
|
||||
preDraw,
|
||||
postDraw,
|
||||
uiDrawBegin,
|
||||
@ -50,6 +51,7 @@ public class EventType{
|
||||
public static class ResizeEvent{}
|
||||
public static class MapMakeEvent{}
|
||||
public static class MapPublishEvent{}
|
||||
public static class SaveWriteEvent{}
|
||||
public static class SaveLoadEvent{}
|
||||
public static class ClientCreateEvent{}
|
||||
public static class ServerLoadEvent{}
|
||||
@ -503,7 +505,7 @@ public class EventType{
|
||||
this.player = player;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public static class PlayerBanEvent{
|
||||
@Nullable
|
||||
public final Player player;
|
||||
@ -514,7 +516,7 @@ public class EventType{
|
||||
this.uuid = uuid;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public static class PlayerUnbanEvent{
|
||||
@Nullable
|
||||
public final Player player;
|
||||
@ -525,7 +527,7 @@ public class EventType{
|
||||
this.uuid = uuid;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public static class PlayerIpBanEvent{
|
||||
public final String ip;
|
||||
|
||||
@ -533,7 +535,7 @@ public class EventType{
|
||||
this.ip = ip;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public static class PlayerIpUnbanEvent{
|
||||
public final String ip;
|
||||
|
||||
@ -541,6 +543,5 @@ public class EventType{
|
||||
this.ip = ip;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -113,13 +113,17 @@ public class SaveIO{
|
||||
|
||||
public static void write(OutputStream os, StringMap tags){
|
||||
try(DataOutputStream stream = new DataOutputStream(os)){
|
||||
SaveVersion ver = getVersion();
|
||||
|
||||
stream.write(header);
|
||||
stream.writeInt(getVersion().version);
|
||||
stream.writeInt(ver.version);
|
||||
if(tags == null){
|
||||
getVersion().write(stream);
|
||||
ver.write(stream);
|
||||
}else{
|
||||
getVersion().write(stream, tags);
|
||||
ver.write(stream, tags);
|
||||
}
|
||||
|
||||
Events.fire(new SaveWriteEvent());
|
||||
}catch(Throwable e){
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user