mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-02-05 00:17:33 +07:00
Cleanup & Steam crash fix
This commit is contained in:
parent
0350e6bbf4
commit
cd684996e1
@ -38,6 +38,8 @@ public class Vars implements Loadable{
|
|||||||
public static boolean loadedLogger = false, loadedFileLogger = false;
|
public static boolean loadedLogger = false, loadedFileLogger = false;
|
||||||
/** Whether to enable various experimental features (e.g. cliffs) */
|
/** Whether to enable various experimental features (e.g. cliffs) */
|
||||||
public static boolean experimental = false;
|
public static boolean experimental = false;
|
||||||
|
/** Name of current Steam player. */
|
||||||
|
public static String steamPlayerName = "";
|
||||||
/** Maximum extra padding around deployment schematics. */
|
/** Maximum extra padding around deployment schematics. */
|
||||||
public static final int maxLoadoutSchematicPad = 5;
|
public static final int maxLoadoutSchematicPad = 5;
|
||||||
/** Maximum schematic size.*/
|
/** Maximum schematic size.*/
|
||||||
@ -54,16 +56,14 @@ public class Vars implements Loadable{
|
|||||||
public static final String ghApi = "https://api.github.com";
|
public static final String ghApi = "https://api.github.com";
|
||||||
/** URL for discord invite. */
|
/** URL for discord invite. */
|
||||||
public static final String discordURL = "https://discord.gg/mindustry";
|
public static final String discordURL = "https://discord.gg/mindustry";
|
||||||
/** URL for sending crash reports to */
|
/** URL for sending crash reports to. Currently offline. */
|
||||||
public static final String crashReportURL = "http://192.99.169.18/report";
|
public static final String crashReportURL = "http://192.99.169.18/report";
|
||||||
/** URL the links to the wiki's modding guide.*/
|
/** URL the links to the wiki's modding guide.*/
|
||||||
public static final String modGuideURL = "https://mindustrygame.github.io/wiki/modding/1-modding/";
|
public static final String modGuideURL = "https://mindustrygame.github.io/wiki/modding/1-modding/";
|
||||||
/** URL to the JSON file containing all the global, public servers. Not queried in BE. */
|
|
||||||
public static final String serverJsonURL = "https://raw.githubusercontent.com/Anuken/Mindustry/master/servers.json";
|
|
||||||
/** URL to the JSON file containing all the BE servers. Only queried in BE. */
|
/** URL to the JSON file containing all the BE servers. Only queried in BE. */
|
||||||
public static final String serverJsonBeURL = "https://raw.githubusercontent.com/Anuken/Mindustry/master/servers_be.json";
|
public static final String serverJsonBeURL = "https://raw.githubusercontent.com/Anuken/Mindustry/master/servers_be.json";
|
||||||
/** URL to the JSON file containing all the BE servers. Only queried in the V6 alpha (will be removed once it's out). */
|
/** URL to the JSON file containing all the BE servers. */
|
||||||
public static final String serverJsonV6URL = "https://raw.githubusercontent.com/Anuken/Mindustry/master/servers_v6.json";
|
public static final String serverJsonURL = "https://raw.githubusercontent.com/Anuken/Mindustry/master/servers_v6.json";
|
||||||
/** URL of the github issue report template.*/
|
/** URL of the github issue report template.*/
|
||||||
public static final String reportIssueURL = "https://github.com/Anuken/Mindustry/issues/new?labels=bug&template=bug_report.md";
|
public static final String reportIssueURL = "https://github.com/Anuken/Mindustry/issues/new?labels=bug&template=bug_report.md";
|
||||||
/** list of built-in servers.*/
|
/** list of built-in servers.*/
|
||||||
|
@ -156,7 +156,10 @@ public class MapEditorDialog extends Dialog implements Disposable{
|
|||||||
}
|
}
|
||||||
|
|
||||||
platform.publish(map);
|
platform.publish(map);
|
||||||
}).padTop(-3).size(swidth * 2f + 10, 60f).update(b -> b.setText(editor.tags.containsKey("steamid") ? editor.tags.get("author").equals(player.name) ? "@workshop.listing" : "@view.workshop" : "@editor.publish.workshop"));
|
}).padTop(-3).size(swidth * 2f + 10, 60f).update(b ->
|
||||||
|
b.setText(editor.tags.containsKey("steamid") ?
|
||||||
|
editor.tags.get("author").equals(steamPlayerName) ? "@workshop.listing" : "@view.workshop" :
|
||||||
|
"@editor.publish.workshop"));
|
||||||
|
|
||||||
menu.cont.row();
|
menu.cont.row();
|
||||||
}
|
}
|
||||||
|
@ -513,7 +513,7 @@ public class JoinDialog extends BaseDialog{
|
|||||||
Core.settings.remove("server-list");
|
Core.settings.remove("server-list");
|
||||||
}
|
}
|
||||||
|
|
||||||
var url = becontrol.active() ? serverJsonBeURL : serverJsonV6URL;
|
var url = becontrol.active() ? serverJsonBeURL : serverJsonURL;
|
||||||
Log.info("Fetching community servers at @", url);
|
Log.info("Fetching community servers at @", url);
|
||||||
|
|
||||||
//get servers
|
//get servers
|
||||||
|
@ -1,7 +0,0 @@
|
|||||||
package mindustry.world.meta;
|
|
||||||
|
|
||||||
public enum PowerType{
|
|
||||||
consumer,
|
|
||||||
producer,
|
|
||||||
bridge
|
|
||||||
}
|
|
@ -130,6 +130,7 @@ public class DesktopLauncher extends ClientLauncher{
|
|||||||
player.name = SVars.net.friends.getPersonaName();
|
player.name = SVars.net.friends.getPersonaName();
|
||||||
Core.settings.put("name", player.name);
|
Core.settings.put("name", player.name);
|
||||||
}
|
}
|
||||||
|
steamPlayerName = SVars.net.friends.getPersonaName();
|
||||||
//update callbacks
|
//update callbacks
|
||||||
Core.app.addListener(new ApplicationListener(){
|
Core.app.addListener(new ApplicationListener(){
|
||||||
@Override
|
@Override
|
||||||
|
Loading…
Reference in New Issue
Block a user