mirror of
https://github.com/PolarisSS13/Polaris.git
synced 2026-08-22 20:56:33 +01:00
between() -> clamp() & swaps args 1 and 2 in uses
This commit is contained in:
@@ -84,4 +84,4 @@
|
||||
// Damages the component. Contains necessary checks. Negative damage "heals" the component.
|
||||
/obj/item/computer_hardware/take_damage(var/amount)
|
||||
damage += round(amount) // We want nice rounded numbers here.
|
||||
damage = between(0, damage, max_damage) // Clamp the value.
|
||||
damage = clamp(damage, 0, max_damage) // Clamp the value.
|
||||
|
||||
Reference in New Issue
Block a user