Unit Mine Speed Game Rule Implementation and World Processor Set Rule for Unit Mine Speed (#10318)
* unitMineSpeedMultiplier Creation
added unitMineSpeedMultiplier
added unitMineSpeed(Team team)
* World Proccesor: SetRuleI unitMineSpeed Implemented
* World Processor: SetRuleI unitCrashDamage Implemented
* Revert "World Processor: SetRuleI unitCrashDamage Implemented"
This reverts commit 1b7187b046.
* Forgor to add, unitMineSpeedMultiplier is now editable per team
This commit is contained in:
@@ -1515,7 +1515,7 @@ public class LExecutor{
|
||||
state.rules.bannedUnits.remove(u);
|
||||
}
|
||||
}
|
||||
case unitHealth, unitBuildSpeed, unitCost, unitDamage, blockHealth, blockDamage, buildSpeed, rtsMinSquad, rtsMinWeight -> {
|
||||
case unitHealth, unitBuildSpeed, unitMineSpeed, unitCost, unitDamage, blockHealth, blockDamage, buildSpeed, rtsMinSquad, rtsMinWeight -> {
|
||||
Team team = p1.team();
|
||||
if(team != null){
|
||||
float num = value.numf();
|
||||
@@ -1523,6 +1523,7 @@ public class LExecutor{
|
||||
case buildSpeed -> team.rules().buildSpeedMultiplier = Mathf.clamp(num, 0.001f, 50f);
|
||||
case unitHealth -> team.rules().unitHealthMultiplier = Math.max(num, 0.001f);
|
||||
case unitBuildSpeed -> team.rules().unitBuildSpeedMultiplier = Mathf.clamp(num, 0f, 50f);
|
||||
case unitMineSpeed -> team.rules().unitMineSpeedMultiplier = Math.max(num, 0f);
|
||||
case unitCost -> team.rules().unitCostMultiplier = Math.max(num, 0f);
|
||||
case unitDamage -> team.rules().unitDamageMultiplier = Math.max(num, 0f);
|
||||
case blockHealth -> team.rules().blockHealthMultiplier = Math.max(num, 0.001f);
|
||||
|
||||
Reference in New Issue
Block a user