diff --git a/Scripts/自定义节点等级.pluto b/Scripts/自定义节点等级.pluto index 365003c..4665997 100644 --- a/Scripts/自定义节点等级.pluto +++ b/Scripts/自定义节点等级.pluto @@ -18,13 +18,8 @@ local function launchNode(nodeId, minLevel, maxLevel, hardMode) infoStr = infoStr:gsub("}", " tier=1\r\n}") end - if minLevel then - infoStr = infoStr:gsub("minEnemyLevel=%d+", $"minEnemyLevel={minLevel}") - end - - if maxLevel then - infoStr = infoStr:gsub("maxEnemyLevel=%d+", $"maxEnemyLevel={maxLevel}") - end + infoStr = infoStr:gsub("minEnemyLevel=%d+", $"minEnemyLevel={minLevel}") + infoStr = infoStr:gsub("maxEnemyLevel=%d+", $"maxEnemyLevel={maxLevel}") args:SetLevel(info.levelOverride:GetFullName()) args:AddContextTag(infoStr) @@ -43,14 +38,12 @@ end local commands = {} commands["节点"] = function(text) local parts = text:split(" ") - local nodeId = regionNames[parts[2]] or parts[2] - launchNode(nodeId, tonumber(parts[3]), tonumber(parts[4]), false) + launchNode(regionNames[parts[2]], tonumber(parts[3]), tonumber(parts[4]), false) end commands["钢铁"] = function(text) local parts = text:split(" ") - local nodeId = regionNames[parts[2]] or parts[2] - launchNode(nodeId, tonumber(parts[3]), tonumber(parts[4]), true) + launchNode(regionNames[parts[2]], tonumber(parts[3]), tonumber(parts[4]), true) end for prefix in commands do