feat: Adds furnace heating interpolations.
All checks were successful
CI / Ubuntu (push) Successful in 11m23s
All checks were successful
CI / Ubuntu (push) Successful in 11m23s
This commit is contained in:
9
Sources/ManualS/Extensions/NormalizePercentage.swift
Normal file
9
Sources/ManualS/Extensions/NormalizePercentage.swift
Normal file
@@ -0,0 +1,9 @@
|
||||
import CoreFoundation
|
||||
|
||||
func normalizePercentage(
|
||||
_ lhs: Int,
|
||||
_ rhs: Int
|
||||
) -> Int {
|
||||
let value = Double(lhs) / Double(rhs)
|
||||
return Int((value * 1000).rounded() / 10.0)
|
||||
}
|
||||
Reference in New Issue
Block a user