Skip to content

Commit

Permalink
Add beep when firing laser
Browse files Browse the repository at this point in the history
  • Loading branch information
RocketGod-git committed Aug 24, 2024
1 parent 2b3aac8 commit 7d2fe20
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Binary file modified fap/laser_tag.fap
Binary file not shown.
6 changes: 5 additions & 1 deletion laser_tag_app.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ struct LaserTagApp {
};

const NotificationSequence sequence_vibro_1 = {&message_vibro_on, &message_vibro_off, NULL};
const NotificationSequence sequence_short_beep =
{&message_note_c4, &message_delay_50, &message_sound_off, NULL};

static void laser_tag_app_timer_callback(void* context) {
furi_assert(context);
Expand Down Expand Up @@ -203,9 +205,11 @@ void laser_tag_app_fire(LaserTagApp* app) {
FURI_LOG_D(TAG, "Laser fired, decreasing ammo by 1");
game_state_decrease_ammo(app->game_state, 1);

notification_message(app->notifications, &sequence_short_beep);

notification_message(app->notifications, &sequence_blink_blue_100);

FURI_LOG_I(TAG, "Notifying user with blink blue");
FURI_LOG_I(TAG, "Notifying user with blink blue and short beep");
app->need_redraw = true;
}

Expand Down

0 comments on commit 7d2fe20

Please sign in to comment.