release v1.0.0
This commit is contained in:
parent
09e244d748
commit
6d887cfb04
4 changed files with 8 additions and 27 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
|
@ -1 +1,3 @@
|
||||||
/target
|
/target
|
||||||
|
/builds
|
||||||
|
/webbuild
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,11 @@
|
||||||
(
|
(
|
||||||
map: {
|
map: {
|
||||||
MouseButton(Middle): [
|
|
||||||
CameraOrbitEnable,
|
|
||||||
],
|
|
||||||
KeyCode(ShiftLeft): [
|
KeyCode(ShiftLeft): [
|
||||||
MultiPlaceTower,
|
MultiPlaceTower,
|
||||||
],
|
],
|
||||||
|
MouseButton(Middle): [
|
||||||
|
CameraOrbitEnable,
|
||||||
|
],
|
||||||
KeyCode(F1): [
|
KeyCode(F1): [
|
||||||
ToggleDebugUI,
|
ToggleDebugUI,
|
||||||
],
|
],
|
||||||
|
|
|
||||||
|
|
@ -70,7 +70,9 @@ fn select(
|
||||||
mut writer: EventWriter<SelectEntity>,
|
mut writer: EventWriter<SelectEntity>,
|
||||||
) {
|
) {
|
||||||
// avoid deselecting when clicking on ui
|
// avoid deselecting when clicking on ui
|
||||||
if physics_query.contains(trigger.event().target) {
|
if trigger.event().button == PointerButton::Primary
|
||||||
|
&& physics_query.contains(trigger.event().target)
|
||||||
|
{
|
||||||
writer.write(SelectEntity(Some(trigger.event().target)));
|
writer.write(SelectEntity(Some(trigger.event().target)));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -37,7 +37,6 @@ impl Plugin for UiIngamePlugin {
|
||||||
.run_if(in_state(GameUIState::Default).and(not(in_state(CoreState::Dead)))),
|
.run_if(in_state(GameUIState::Default).and(not(in_state(CoreState::Dead)))),
|
||||||
game_over.run_if(in_state(GameState::GameOver)),
|
game_over.run_if(in_state(GameState::GameOver)),
|
||||||
plan_ui.run_if(in_state(GameUIState::Default).and(in_state(Phase::Plan))),
|
plan_ui.run_if(in_state(GameUIState::Default).and(in_state(Phase::Plan))),
|
||||||
execute_ui.run_if(in_state(GameUIState::Default).and(in_state(Phase::Execute))),
|
|
||||||
transition_ui.run_if(
|
transition_ui.run_if(
|
||||||
in_state(GameUIState::Default).and(
|
in_state(GameUIState::Default).and(
|
||||||
not(in_state(PhaseTransitionState::None))
|
not(in_state(PhaseTransitionState::None))
|
||||||
|
|
@ -102,28 +101,6 @@ fn plan_ui(
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
fn execute_ui(mut contexts: EguiContexts, mut res: ResMut<Resources>) {
|
|
||||||
let ctx = contexts.ctx_mut().unwrap();
|
|
||||||
egui::Window::new("ExecuteUI")
|
|
||||||
.resizable(false)
|
|
||||||
.collapsible(false)
|
|
||||||
.title_bar(false)
|
|
||||||
.anchor(Align2::CENTER_TOP, [0., 0.])
|
|
||||||
.show(ctx, |ui| {
|
|
||||||
// todo - remove this
|
|
||||||
if ui
|
|
||||||
.button(RichText::new("DEBUG - $$$").size(LARGE_FONT_SIZE))
|
|
||||||
.clicked()
|
|
||||||
{
|
|
||||||
res.0 = res.0
|
|
||||||
+ Quantity {
|
|
||||||
souls: 100,
|
|
||||||
bones: 100,
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
#[derive(Resource, DerefMut, Deref)]
|
#[derive(Resource, DerefMut, Deref)]
|
||||||
struct TransitionTimer(Timer);
|
struct TransitionTimer(Timer);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue