diff --git a/core/src/mindustry/logic/LExecutor.java b/core/src/mindustry/logic/LExecutor.java index 01e5266fea..16dfe01bf2 100644 --- a/core/src/mindustry/logic/LExecutor.java +++ b/core/src/mindustry/logic/LExecutor.java @@ -1360,13 +1360,20 @@ public class LExecutor{ exec.setobj(result, i < 0 || i >= builds.size ? null : builds.get(i)); } } - case unitCount -> exec.setnum(result, data.units.size); + case unitCount -> { + UnitType type = exec.obj(extra) instanceof UnitType u ? u : null; + if(type == null){ + exec.setnum(result, data.units.size); + }else{ + exec.setnum(result, data.unitsByType[type.id].size); + } + } case coreCount -> exec.setnum(result, data.cores.size); case playerCount -> exec.setnum(result, data.players.size); case buildCount -> { Block block = exec.obj(extra) instanceof Block b ? b : null; if(block == null){ - exec.setobj(result, null); + exec.setnum(result, data.buildings.size); }else{ exec.setnum(result, data.getBuildings(block).size); } diff --git a/core/src/mindustry/logic/LStatements.java b/core/src/mindustry/logic/LStatements.java index 1a9e0473d8..30b7b52b56 100644 --- a/core/src/mindustry/logic/LStatements.java +++ b/core/src/mindustry/logic/LStatements.java @@ -1748,7 +1748,7 @@ public class LStatements{ fields(table, index, i -> index = i); } - if(type == FetchType.buildCount || type == FetchType.build){ + if(type == FetchType.buildCount || type == FetchType.build || type == FetchType.unitCount){ row(table); fields(table, "block", extra, i -> extra = i); diff --git a/servers_v7.json b/servers_v7.json index f8984c7fea..a760a6979e 100644 --- a/servers_v7.json +++ b/servers_v7.json @@ -3,6 +3,10 @@ "name": "STP", "address": ["23.88.73.88:25617"] }, + { + "name" : "LesGarsCools", + "address": ["est1.be"] + }, { "name": "meiqiuMDT", "address": ["cn1.meiqiumdy.top:7000","cn1.meiqiumdt.top:7002","cn1.meiqiumdt.top:7006","bj-1.lcf.icu:10240"] @@ -234,7 +238,7 @@ }, { "name": "Extra Utilities", - "address": ["222.186.59.147:15142", "222.186.59.147:15143"] + "address": ["222.186.59.147:15142", "222.186.59.147:15143", "p1.i9mr.com:44922", "p1.i9mr.com:44834"] }, { "name": "Alex Multiverse", @@ -259,5 +263,9 @@ { "name": "SkyPlex", "address": ["mc-skyplex.net"] + }, + { + "name": "Gadgetroch's Server", + "address": ["mindustry.gadgetroch.com", "mindustry.gadgetroch.com:6568"] } ]