diff options
Diffstat (limited to 'src/pke-at.cpp')
| -rw-r--r-- | src/pke-at.cpp | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/src/pke-at.cpp b/src/pke-at.cpp index 0831c08..f53d2eb 100644 --- a/src/pke-at.cpp +++ b/src/pke-at.cpp @@ -1,5 +1,7 @@ #include "level-init.hpp" +#include "pke-at-common.hpp" +#include "pke-at-data-stub.hpp" #include "pke-at-setlist-types.hpp" #include "pke-at-settings.hpp" #include "pke-at-storage-sql.hpp" @@ -17,16 +19,26 @@ void pke_at_tick(double delta) { } void pke_at_init() { - uint64_t i; + uint64_t u; pkeSettings.rt.nextLevel = pke_at_level_init_create(); - for (i = 0; i < PKE_AT_SECTION_TYPE_INDEX_COUNT; ++i) { - if (g_section_types[i].title_key[0] == '\0') continue; - g_section_types[i].title_handle = AM_GetHandle(g_section_types[i].title_key); + for (u = 0; u < PKE_AT_SECTION_TYPE_INDEX_COUNT; ++u) { + if (g_section_types[u].title_key[0] == '\0') continue; + g_section_types[u].title_handle = AM_GetHandle(g_section_types[u].title_key); + } + + for (u = 1; u < PKE_AT_KEY_INDEX_COUNT; ++u) { + g_keys[u].mtrnm_beat_asset_handle = + pke_at_audio_get_or_generate_sawtooth(g_keys[u].mtrnm_hz_beat, 0.3); + g_keys[u].mtrnm_down_beat_asset_handle = + pke_at_audio_get_or_generate_sawtooth(g_keys[u].mtrnm_hz_down_beat, 0.3); } g_at.storage = pk_new<pke_at_storage_sql>(); g_at.storage->init(); + + g_at.data = pk_new<pke_at_data_stub>(); + g_at.data->init(); } void pke_at_teardown() { |
