Skip to content

Commit

Permalink
Merge branch 'master' into yzh
Browse files Browse the repository at this point in the history
  • Loading branch information
YaeSakuraQvQ committed Mar 2, 2024
2 parents 3e958c2 + 03174e6 commit 928125e
Show file tree
Hide file tree
Showing 30 changed files with 972 additions and 1,059 deletions.
73 changes: 73 additions & 0 deletions assets/bundles/bundle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,79 @@ update.failCheck = Check failed.
update.download = Download
update.close = Close

settings.tags.restart = 需要重启游戏
settings.tags.reloadWorld = 需要重新进入世界
settings.tags.performance = 可能影响性能

settings.graphics.ui = UI窗口
settings.MI2UI.showEmojis = 启用Emoji窗口
settings.MI2UI.showCoreInfo = 启用核心信息窗口
settings.MI2UI.showMindowMap = 启用小地图窗口
settings.MI2UI.showLogicHelper = 启用逻辑辅助窗口
settings.graphics.zone = 渲染范围建筑
settings.MI2UI.enPlayerCursor = 玩家光标
settings.MI2UI.enOverdriveZone = 超速范围
settings.MI2UI.enMenderZone = 修复范围
settings.MI2UI.enSpawnZone = 敌人刷怪点
settings.MI2UI.enTurretRangeZone = 炮台视野范围
settings.MI2UI.enUnitRangeZone = 单位视野范围
settings.graphics.distributionReveal = 渲染之物流揭示
settings.MI2UI.enDistributionReveal = 启用物流揭示
settings.MI2UI.drevealBridge = 渲染桥带物流
settings.MI2UI.drevealJunction = 渲染交叉器物流
settings.MI2UI.drevealUnloader = 渲染装卸器物流
settings.MI2UI.drevealInventory = 渲染建筑内物品
settings.graphics.overlay = 渲染叠加层
settings.MI2UI.enBlockHpBar = 建筑血条
settings.MI2UI.enUnitHpBar = 单位血条
settings.MI2UI.unitHpBarDamagedOnly = 单位满血隐藏血条
settings.MI2UI.unitHpBarStyle = 单位血条样式
settings.MI2UI.enUnitHitbox = 单位碰撞箱
settings.MI2UI.enUnitLogic = 单位逻辑线
settings.MI2UI.enUnitPath = 单位寻路线
settings.MI2UI.enUnitPath.length = 寻路线长度
settings.graphics.drawGroups = 渲染实体组
settings.MI2UI.disableWreck = 不渲染残骸
settings.MI2UI.disableUnit = 不渲染单位
settings.MI2UI.disableBullet = 不渲染子弹
settings.MI2UI.disableBuilding = 不渲染建筑
settings.game.speedctrl = 自动变速器
settings.MI2UI.speedctrl.basefps = 基准帧数
settings.MI2UI.speedctrl.cutoff = 截止帧数
settings.input = 输入
settings.MI2UI.inputReplace = 替换输入控制器
settings.MI2UI.instantBuild = 沙盒瞬间建造
settings.MI2UI.rtsFormDoubleTap = RTS编队双击灵敏度
settings.MI2UI.forceTapTile = 强制跨队交互
settings.MI2UI.edgePanning = 屏边移动视角
settings.modify = 修改原版
settings.MI2UI.blockSelectTableHeight = 方块选择面板高度
settings.MI2UI.modifyBlockBars = 修改方块信息条
settings.MI2UI.replaceTopTable = 替换TopTable
settings.MI2UI.modTopTableFollowMouse = 模组TopTable跟随鼠标
settings.MI2UI.maxSchematicSize = 最大蓝图尺寸
settings.MI2UI.maxZoom = 最大缩放
settings.MI2UI.minZoom = 最小缩放
settings.MI2UI.enableUpdate = 模组更新检查

settings.CoreInfo.showCoreItems = 显示核心物品
settings.CoreInfo.showUnits = 显示单位总数
settings.CoreInfo.showPowerGraphs = 显示电网条
settings.CoreInfo.itemsMaxHeight = 物品面板最大高度
settings.CoreInfo.unitsMaxHeight = 单位面板最大高度

settings.MindowMap.drawLabel = 显示玩家标签
settings.MindowMap.drawSpawn = 显示刷怪点
settings.MindowMap.drawFog = 显示战争迷雾
settings.MindowMap.drawIndicator = 显示攻击指示器
settings.MindowMap.drawObjective = 显示地图目标
settings.MindowMap.size = 小地图尺寸
settings.MindowMap.drawUnitColorDiff = 单位图标色差
settings.MindowMap.drawUnitOutline = 单位描边量

settings.LogicHelper.autocomplete = 自动补全
settings.LogicHelper.split = 分隔符

mi2u.settings.cleanUp = Clean Up MI2U Settings
mi2u.settings.removeConf = (IRREVERSIBLE)Confirm remove this setting:
mi2u.settings.removeAllConf = [scarlet](IRREVERSIBLE)Confirm remove all MI2U settings?
Expand Down
167 changes: 96 additions & 71 deletions assets/bundles/bundle_zh_CN.properties
Original file line number Diff line number Diff line change
Expand Up @@ -87,77 +87,102 @@ update.failCheck = 检查更新失败
update.download = 下载
update.close = 关闭

mi2u.settings.cleanUp = 清理MI2U选项
mi2u.settings.removeConf = (不可撤销)确认清除这个选项:
mi2u.settings.removeAllConf = [scarlet](不可撤销)确认清除所有MI2U选项吗?
mindow2.settings.title = MI2U 选项
mindow2.settings.allIntro = 本界面罗列了MI2U的所有选项,包括各窗口特有的选项
mindow2.settings.curMindowName = 当前调整的Mindow2的名称是:\n
mindow2.settings.noMindowNameWarning = Mindow2没有名称,UI选项不可用。
mindow2.settings.help = 帮助信息
settings.mindow2.scale = 缩放UI 5% ~ 400%
settings.main.playerCursor = 玩家光标
settings.main.overdriveZone = 超速区域显示
settings.main.menderZone = 修理器区域显示
settings.main.enTurretZone = 炮台区域显示
settings.main.flashZoneAlpha = 区域闪烁强度
settings.main.spawnZone = 刷怪点常显
settings.main.disableWreck = 关闭残骸
settings.main.disableUnit = 关闭单位渲染
settings.main.disableBullet = 关闭子弹渲染
settings.main.disableBuilding = 关闭建筑渲染
settings.main.blockHpBar = 建筑血条
settings.main.unitHpBar = 单位血条
settings.main.unitHpBarStyle = 单位血条样式
settings.main.unitHpBarDamagedOnly = 血条仅损伤单位
settings.main.unitHitbox = 单位碰撞箱
settings.main.unitLogic = 逻辑线
settings.main.unitLogicTimer = 逻辑时计
settings.main.unitPath = 单位寻路
settings.main.enUnitPath.length = 寻路线长上限
settings.main.enUnitRangeZone = 单位视野区域显示
settings.main.distributionReveal = 揭示传输器件
settings.main.dreveal.bridge = 揭示桥带
settings.main.dreveal.junction = 揭示单格传输元件
settings.main.dreveal.unloader = 揭示装卸器
settings.main.dreveal.inventory = 揭示建筑物品栏
settings.main.emoji = []
settings.main.coreInfo = 核心信息
settings.main.mindowMap = 窗体化小地图
settings.main.mapInfo = 地图信息
settings.main.logicHelper = 逻辑辅助
settings.main.speedctrl = 自动变速器选项
settings.main.speedctrl.basefps = 逻辑帧数(卡顿时,变速器调整时间流动来模拟这个帧数)
settings.main.speedctrl.cutoff = 截止帧数(变速器支持的最低帧数,过低将使UI卡顿)
settings.main.instantBuild = 沙盒模式瞬间建造
settings.main.modifyBlockSelectTable = 修改建筑选择面板
settings.main.blockSelectTableHeight = 建筑选择面板高度(默认=194)(重进存档生效)
settings.main.rtsFormDoubleTap = RTS编队双击判定时长(毫秒)
settings.main.modifyBlockBars = 替换原版方块数值条(重启生效)
settings.main.modifyTopTable = 替换原版方块信息面板(重启生效)
settings.main.topTableFollowMouse = 方块信息面板跟随鼠标(重进存档生效)
settings.main.inputReplace = 替换原版输入处理(AI需要此功能)(重启生效)
settings.main.forceTapTile = 跨队点击建筑
settings.main.edgePanning = 屏边移动视角
settings.main.enableUpdate = 更新检查
settings.main.maxSchematicSize = 蓝图尺寸上限
settings.main.maxZoom = 视野最大放大(默认=6)
settings.main.minZoom = 视野最小缩小(默认=1.5)
settings.coreInfo.showCoreItems = 显示核心物品
settings.coreInfo.showUnits = 显示单位计数
settings.coreInfo.showPowerGraphs = 显示电网条
settings.coreInfo.itemsMaxHeight = 物品面板高度上限
settings.coreInfo.unitsMaxHeight = 单位面板高度上限
settings.mindowMap.drawLabel = 显示玩家标签
settings.mindowMap.drawSpawn = 显示刷怪点
settings.mindowMap.drawFog = 显示迷雾
settings.mindowMap.drawIndicator = 显示攻击警告
settings.mindowMap.drawObjective = 显示地图目标
settings.mindowMap.drawUnitColorDiff = 单位图标色差
settings.mindowMap.drawUnitOutline = 单位描边
settings.mindowMap.size = 小地图尺寸(原版=140)
settings.mindowMap.worldDataUpdate.tiles = 天眼查世界数据每帧更新格数
settings.logicHelper.autocomplete = 自动补全
settings.tags.restart = 需要重启游戏
settings.tags.reloadWorld = 需要重新进入世界
settings.tags.performance = 可能影响性能

settings.graphics.ui = UI窗口
settings.MI2UI.showEmojis = 启用Emoji窗口
settings.MI2UI.showCoreInfo = 启用核心信息窗口
settings.MI2UI.showMindowMap = 启用小地图窗口
settings.MI2UI.showLogicHelper = 启用逻辑辅助窗口
settings.graphics.zone = 渲染范围建筑
settings.MI2UI.enPlayerCursor = 玩家光标
settings.MI2UI.enOverdriveZone = 超速范围
settings.MI2UI.enMenderZone = 修复范围
settings.MI2UI.enSpawnZone = 敌人刷怪点
settings.MI2UI.enTurretRangeZone = 炮台视野范围
settings.MI2UI.enUnitRangeZone = 单位视野范围
settings.graphics.distributionReveal = 渲染之物流揭示
settings.MI2UI.enDistributionReveal = 启用物流揭示
settings.MI2UI.drevealBridge = 渲染桥带物流
settings.MI2UI.drevealJunction = 渲染交叉器物流
settings.MI2UI.drevealJunction.description = 绘制交叉器内的物品、路由器的物品和传输方向。
settings.MI2UI.drevealUnloader = 渲染装卸器物流
settings.MI2UI.drevealUnloader.description = 绘制装卸器上次传输的方向,其中红色条表示抽取,黄色条表示卸入。如果装卸器空选,还会绘制上次传输的物品。
settings.MI2UI.drevealInventory = 渲染建筑内物品
settings.MI2UI.drevealInventory.description = 对于没有物流揭示的建筑,绘制建筑内容物列表。在覆盖层上显示建筑中所有的物品、液体及其数量,炮台还会显示弹药数量。
settings.graphics.overlay = 渲染叠加层
settings.MI2UI.enBlockHpBar = 建筑血条
settings.MI2UI.enUnitHpBar = 单位血条
settings.MI2UI.unitHpBarDamagedOnly = 单位满血隐藏血条
settings.MI2UI.unitHpBarStyle = 单位血条样式
settings.MI2UI.enUnitHitbox = 单位碰撞箱
settings.MI2UI.enUnitLogic = 单位逻辑线
settings.MI2UI.enUnitLogic.description = 显示被处理器控制的单位的移动目标、控制计时器、物品传输计时器。
settings.MI2UI.enUnitPath = 单位寻路线
settings.MI2UI.enUnitPath.description = 显示单位的寻路路径,包括传统生存模式的寻路和RTS寻路。在多人游戏无效。
settings.MI2UI.enUnitPath.length = 寻路线长度
settings.graphics.drawGroups = 渲染实体组
settings.MI2UI.disableWreck = 不渲染残骸
settings.MI2UI.disableUnit = 不渲染单位
settings.MI2UI.disableBullet = 不渲染子弹
settings.MI2UI.disableBuilding = 不渲染建筑
settings.game.speedctrl = 自动变速器
settings.game.speedctrl.description = Mindustry的渲染帧率和逻辑帧率绑定,使得严重的掉帧可以拖慢物流建筑效率。自动变速器在掉帧情况中可以适当减缓游戏时间流速,抵消掉帧影响。\n注意!这可能影响逻辑处理器的补帧机制。
settings.MI2UI.speedctrl.basefps = 基准帧数
settings.MI2UI.speedctrl.basefps.description = 自动变速器要模拟的帧率,通常要设定为你设置的最大帧率或设备的屏幕刷新率。
settings.MI2UI.speedctrl.cutoff = 截止帧数
settings.MI2UI.speedctrl.cutoff.description = 变速器抵消的帧率下限,若渲染帧率低于该值,低于的部分将不做抵消。以免整个游戏响应太慢。
settings.input = 输入
settings.MI2UI.inputReplace = 替换输入控制器
settings.MI2UI.inputReplace.description = 将原版的输入控制[accent]替换[]为本Mod的输入控制。AI、小地图和RTS编队视角跳转等功能均以此为前置。
settings.MI2UI.instantBuild = 沙盒瞬间建造
settings.MI2UI.rtsFormDoubleTap = RTS编队双击灵敏度
settings.MI2UI.forceTapTile = 强制跨队交互
settings.MI2UI.edgePanning = 屏边移动视角
settings.modify = 修改原版
settings.MI2UI.blockSelectTableHeight = 方块选择面板高度
settings.MI2UI.modifyBlockBars = 修改信息窗信息
settings.MI2UI.modifyBlockBars.description = 在单位信息栏和建筑信息栏中替换或添加血量条、护盾条等更详细的信息。
settings.MI2UI.replaceTopTable = 替换TopTable
settings.MI2UI.replaceTopTable.description = 将原版光标悬浮的信息窗[accent]替换[]为本Mod的信息窗。可以同时显示光标处的地形、单位、建筑。
settings.MI2UI.modTopTableFollowMouse = 模组TopTable跟随鼠标
settings.MI2UI.modTopTableFollowMouse.description = 将本Mod的信息窗从右下角分离出来,跟随光标移动。不支持原版信息窗。
settings.MI2UI.maxSchematicSize = 最大蓝图尺寸
settings.MI2UI.maxZoom = 最大缩放
settings.MI2UI.minZoom = 最小缩放
settings.MI2UI.enableUpdate = 模组更新检查

settings.CoreInfo.showCoreItems = 显示核心物品
settings.CoreInfo.showCoreItems.description = 类似原版的核心物品栏。具有物品统计图功能。点击图标弹出物品的60秒统计图
settings.CoreInfo.showUnits = 显示单位总数
settings.CoreInfo.showUnits.description = 统计各类型单位数量。点击图标跳转视角到随机的单位上。
settings.CoreInfo.showPowerGraphs = 显示电网条
settings.CoreInfo.showPowerGraphs.description = 电网条将每一个电网单独显示出来。光标悬浮时,展示该电网的电力IO统计图。通过界面中的电力图标的按钮可以切换电网条显示模式。
settings.CoreInfo.itemsMaxHeight = 物品面板最大高度
settings.CoreInfo.unitsMaxHeight = 单位面板最大高度

settings.MindowMap.drawLabel = 显示玩家标签
settings.MindowMap.drawSpawn = 显示刷怪点
settings.MindowMap.drawFog = 显示战争迷雾
settings.MindowMap.drawIndicator = 显示攻击指示器
settings.MindowMap.drawObjective = 显示地图目标
settings.MindowMap.size = 小地图尺寸
settings.MindowMap.drawUnitColorDiff = 单位图标色差
settings.MindowMap.drawUnitOutline = 单位描边量

settings.LogicHelper.autocomplete = 自动补全
settings.LogicHelper.split = 分隔符

settings.mindow.scale = 窗口缩放

settings.meta.category = MI2U设置项
settings.meta.dialogTitle = MI2U设置项
settings.meta.mindowHelp = 帮助信息
settings.meta.oldVersionButton = 旧版设置项
settings.meta.oldVersion.tip = 点击以文本形式复制到剪切板
settings.meta.oldVersion = 本Mod自1.6.x版本开始使用新的设置框架,所有设置存入玩家的个人settings存档,以便随游戏数据一起导入导出。\n可以使用我开发的设置项管理器模组BlackDeluxeCat/SettingSweep来管理个人settings存档。\n如果你误填了某个设置项导致本Mod的崩坏,请先停用MI2-Utilities-Java,然后下载SettingSweep,找到并删除引发问题的设置项。\n旧版设置文件(Mod文件夹中)已停用,1.7.0仍可以查看、以文本形式导出旧版设置项,随后的版本将完全废弃并移除相关代码。

mindow2.helpInfoTitle = 帮助信息
mindow2.uiHelp = Mindow2是MI2U开发的简易窗体。\
Expand Down
2 changes: 1 addition & 1 deletion mod.hjson
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ displayName: "MI2-Utilities Java"
name: "mi2-utilities-java"

#the mod version
version: 1.5.6
version: 1.5.6b

#the minimum game build required to run this mod
minGameVersion: 146
Expand Down
6 changes: 2 additions & 4 deletions src/mi2u/MI2UTmp.java
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
package mi2u;

import arc.graphics.Color;
import arc.math.geom.Point2;
import arc.math.geom.Rect;
import arc.math.geom.Vec2;
import arc.graphics.*;
import arc.math.geom.*;

public class MI2UTmp{
public static final Color c1 = new Color();
Expand Down
18 changes: 9 additions & 9 deletions src/mi2u/MI2Utilities.java
Original file line number Diff line number Diff line change
Expand Up @@ -56,22 +56,22 @@ public MI2Utilities(){
InputUtils.init();

//anyone need max size < vanilla size, open an issue on Github
maxSchematicSize = Math.max(maxSchematicSize, MI2USettings.getInt("maxSchematicSize", 64));
MI2USettings.putInt("maxSchematicSize", maxSchematicSize);
maxSchematicSize = Math.max(maxSchematicSize, mi2ui.settings.getInt("maxSchematicSize", 64));
mi2ui.settings.putInt("maxSchematicSize", maxSchematicSize);

renderer.maxZoom = Strings.parseFloat(MI2USettings.getStr("maxZoom", "6"));
renderer.minZoom = Strings.parseFloat(MI2USettings.getStr("minZoom", "1.5"));
renderer.maxZoom = mi2ui.settings.getFloat("maxZoom");
renderer.minZoom = mi2ui.settings.getFloat("minZoom");

Time.runTask(40f, () -> {
mi2ui.addTo(Core.scene.root);
mi2ui.visible(() -> state.isGame() && ui.hudfrag.shown);
if(MI2USettings.getBool("showEmojis")) emojis.addTo(emojis.hasParent() ? emojis.parent : Core.scene.root);
if(mi2ui.settings.getBool("showEmojis")) emojis.addTo(emojis.hasParent() ? emojis.parent : Core.scene.root);
emojis.visible(() -> !state.isGame() || ui.hudfrag.shown);
if(MI2USettings.getBool("showCoreInfo")) coreInfo.addTo(coreInfo.hasParent() ? coreInfo.parent : Core.scene.root);
if(mi2ui.settings.getBool("showCoreInfo")) coreInfo.addTo(coreInfo.hasParent() ? coreInfo.parent : Core.scene.root);
coreInfo.visible(() -> state.isGame() && ui.hudfrag.shown);
if(MI2USettings.getBool("showMindowMap")) mindowmap.addTo(mindowmap.hasParent() ? mindowmap.parent : Core.scene.root);
if(mi2ui.settings.getBool("showMindowMap")) mindowmap.addTo(mindowmap.hasParent() ? mindowmap.parent : Core.scene.root);
mindowmap.visible(() -> state.isGame() && ui.hudfrag.shown);
if(MI2USettings.getBool("showLogicHelper", true)) logicHelper.addTo(logicHelper.hasParent() ? logicHelper.parent : ui.logic);
if(mi2ui.settings.getBool("showLogicHelper")) logicHelper.addTo(logicHelper.hasParent() ? logicHelper.parent : ui.logic);

RendererExt.initBase();
ModifyFuncs.modifyVanilla();
Expand All @@ -81,7 +81,7 @@ public MI2Utilities(){

//popup too early will cause font rendering bug.
Time.runTask(140f, () -> {
if(MI2USettings.getBool("enableUpdate", true)) checkUpdate();
if(mi2ui.settings.getBool("enableUpdate")) checkUpdate();
});
});

Expand Down
4 changes: 2 additions & 2 deletions src/mi2u/MI2Utils.java
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package mi2u;

import arc.struct.ObjectMap;
import arc.struct.*;
import arc.util.*;

import java.lang.reflect.Field;
import java.lang.reflect.*;
import java.util.*;

public class MI2Utils{
Expand Down
Loading

0 comments on commit 928125e

Please sign in to comment.