minor balance tweaks
This commit is contained in:
parent
e9379a6a94
commit
283b86d04a
7 changed files with 99 additions and 31 deletions
|
|
@ -186,7 +186,7 @@ fn transition_ui(
|
|||
fn side_panel(
|
||||
mut contexts: EguiContexts,
|
||||
mut commands: Commands,
|
||||
resources: Res<Resources>,
|
||||
mut resources: ResMut<Resources>,
|
||||
mut available_workers: ResMut<AvailableWorkers>,
|
||||
buildings: Query<(&BuildingInfo, &Cost, &Name)>,
|
||||
selected: Query<(Entity, &Name), With<Selected>>,
|
||||
|
|
@ -292,6 +292,7 @@ fn side_panel(
|
|||
RichText::new(upgrade_name.as_str()).size(LARGE_FONT_SIZE);
|
||||
if resources.0.can_buy(upgrade.cost) {
|
||||
if ui.button(button_text).clicked() {
|
||||
resources.0 = resources.0 - upgrade.cost;
|
||||
commands.trigger_targets(
|
||||
UnlockUpgrade { building: selected },
|
||||
upgrade_entity,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue