chore: run gdformat
This commit is contained in:
@@ -79,10 +79,12 @@ var MOD_CHOICES = [
|
||||
},
|
||||
]
|
||||
|
||||
|
||||
func _ready() -> void:
|
||||
placeholder_tex = PlaceholderTexture2D.new()
|
||||
placeholder_tex.size = Vector2(64.0, 64.0)
|
||||
|
||||
|
||||
func _draw_random_choice(fortune: float = 1.0) -> Dictionary:
|
||||
var total_weight: int = 0
|
||||
for choice in MOD_CHOICES:
|
||||
@@ -95,6 +97,7 @@ func _draw_random_choice(fortune: float = 1.0) -> Dictionary:
|
||||
return u
|
||||
return MOD_CHOICES.back()
|
||||
|
||||
|
||||
func draw_random_mod(fortune: float = 1.0) -> PlayerStatsModifier:
|
||||
var choice = _draw_random_choice(fortune)
|
||||
var mod: PlayerStatsModifier = PlayerStatsModifier.new()
|
||||
@@ -104,9 +107,10 @@ func draw_random_mod(fortune: float = 1.0) -> PlayerStatsModifier:
|
||||
mod.description = choice["description"]
|
||||
mod.internal_name = choice["internal_name"]
|
||||
mod.tex = choice["tex"]
|
||||
mod.title = choice["name"]
|
||||
mod.title = choice["name"]
|
||||
|
||||
return mod
|
||||
|
||||
|
||||
|
||||
func calculate_weight(weight: float, fortune: float):
|
||||
return weight**(1 / 1 + fortune)
|
||||
return weight ** (1 / 1 + fortune)
|
||||
|
Reference in New Issue
Block a user