Skip to content

Commit

Permalink
clean up quake.py
Browse files Browse the repository at this point in the history
  • Loading branch information
nfearnley committed May 21, 2024
1 parent 71fabee commit 4233ee1
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions sizebot/lib/quake.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,20 +71,20 @@ def mag_to_name(mag: float) -> str:
return r.title() + b


def scale_to_joules(user: User, g: float, factor: float) -> Decimal:
def _scale_to_joules(user: User, g: float, factor: float) -> Decimal:
return (Decimal(user.weight / 1000) / 2) * (Decimal(g) * Decimal(user.scale)) * Decimal(factor)


def step_joules(user: User) -> Decimal:
return scale_to_joules(user, G, STEP_FACTOR)
return _scale_to_joules(user, G, STEP_FACTOR)


def stomp_joules(user: User) -> Decimal:
return scale_to_joules(user, STOMP_G, STOMP_FACTOR)
return _scale_to_joules(user, STOMP_G, STOMP_FACTOR)


def jump_joules(user: User) -> Decimal:
return scale_to_joules(user, G, JUMP_FACTOR)
return _scale_to_joules(user, G, JUMP_FACTOR)


def breath_joules(user: User) -> Decimal:
Expand Down

0 comments on commit 4233ee1

Please sign in to comment.