mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-07-11 16:28:09 +07:00
Minor server tweaks
This commit is contained in:
@ -66,6 +66,10 @@ public class NetServer implements ApplicationListener{
|
|||||||
});
|
});
|
||||||
|
|
||||||
net.handleServer(ConnectPacket.class, (con, packet) -> {
|
net.handleServer(ConnectPacket.class, (con, packet) -> {
|
||||||
|
if(con.address.startsWith("steam:")){
|
||||||
|
packet.uuid = con.address.substring("steam:".length());
|
||||||
|
}
|
||||||
|
|
||||||
String uuid = packet.uuid;
|
String uuid = packet.uuid;
|
||||||
|
|
||||||
if(admins.isIPBanned(con.address)) return;
|
if(admins.isIPBanned(con.address)) return;
|
||||||
|
@ -95,6 +95,10 @@ public class EventType{
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static class ServerLoadEvent{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
public static class ContentReloadEvent{
|
public static class ContentReloadEvent{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -46,6 +46,9 @@ task dist(type: Jar){
|
|||||||
exclude("com/badlogic/gdx/**")
|
exclude("com/badlogic/gdx/**")
|
||||||
exclude("icons/**")
|
exclude("icons/**")
|
||||||
exclude("bundles/**")
|
exclude("bundles/**")
|
||||||
|
if(!versionModifier.contains("steam")){
|
||||||
|
exclude("**.dll", "**.so", "**.dylib")
|
||||||
|
}
|
||||||
|
|
||||||
manifest{
|
manifest{
|
||||||
attributes 'Main-Class': project.mainClassName
|
attributes 'Main-Class': project.mainClassName
|
||||||
|
@ -7,13 +7,14 @@ import io.anuke.arc.files.*;
|
|||||||
import io.anuke.arc.util.*;
|
import io.anuke.arc.util.*;
|
||||||
import io.anuke.mindustry.*;
|
import io.anuke.mindustry.*;
|
||||||
import io.anuke.mindustry.core.*;
|
import io.anuke.mindustry.core.*;
|
||||||
|
import io.anuke.mindustry.game.EventType.*;
|
||||||
import io.anuke.mindustry.mod.*;
|
import io.anuke.mindustry.mod.*;
|
||||||
import io.anuke.mindustry.net.Net;
|
import io.anuke.mindustry.net.Net;
|
||||||
import io.anuke.mindustry.net.*;
|
import io.anuke.mindustry.net.*;
|
||||||
|
|
||||||
import java.time.*;
|
import java.time.*;
|
||||||
|
|
||||||
import static io.anuke.arc.util.Log.*;
|
import static io.anuke.arc.util.Log.format;
|
||||||
import static io.anuke.mindustry.Vars.*;
|
import static io.anuke.mindustry.Vars.*;
|
||||||
import static io.anuke.mindustry.server.ServerControl.*;
|
import static io.anuke.mindustry.server.ServerControl.*;
|
||||||
|
|
||||||
@ -63,5 +64,7 @@ public class ServerLauncher implements ApplicationListener{
|
|||||||
Core.app.addListener(new ServerControl(args));
|
Core.app.addListener(new ServerControl(args));
|
||||||
|
|
||||||
mods.each(Mod::init);
|
mods.each(Mod::init);
|
||||||
|
|
||||||
|
Events.fire(new ServerLoadEvent());
|
||||||
}
|
}
|
||||||
}
|
}
|
Reference in New Issue
Block a user