aboutsummaryrefslogtreecommitdiff
path: root/game/menus/ButtonShowCreditsSubScript.cpp
blob: ec0e9807e37a1919a51a9fcd33f0e513a87f9023 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#include "ButtonShowCreditsSubScript.h"
#include "MenusConfig.h"
#include "mainmenu/CreditsSubScript.h"
#include <crepe/api/AudioSource.h>
#include <crepe/types.h>

using namespace crepe;
using namespace std;

void ButtonShowCreditsSubScript::init() {
	IButtonScript::init();
	this->subscribe<ButtonPressEvent>([this](const ButtonPressEvent & e) {
		return this->on_button_press(e);
	});
}

bool ButtonShowCreditsSubScript::on_button_press(const ButtonPressEvent & e) {
	this->trigger_event<ShowCreditsEvent>();
	return false;
}