MCPcopy Create free account
hub / github.com/BespokeSynth/BespokeSynth / LoadState

Method LoadState

Source/DrumPlayer.cpp:1281–1303  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1279}
1280
1281void DrumPlayer::LoadState(FileStreamIn& in, int rev)
1282{
1283 IDrawableModule::LoadState(in, rev);
1284
1285 if (ModularSynth::sLoadingFileSaveStateRev < 423)
1286 in >> rev;
1287 LoadStateValidate(rev <= GetModuleSaveStateRev());
1288
1289 for (int i = 0; i < NUM_DRUM_HITS; ++i)
1290 {
1291 mDrumHits[i].mSample.LoadState(in);
1292 in >> mDrumHits[i].mLinkId;
1293 in >> mDrumHits[i].mVol;
1294 in >> mDrumHits[i].mSpeed;
1295 if (rev >= 1)
1296 {
1297 in >> mDrumHits[i].mHitCategory;
1298 mDrumHits[i].UpdateHitDirectoryDropdown();
1299 }
1300 }
1301
1302 mNeedSetup = false;
1303}

Callers

nothing calls this directly

Calls 2

LoadStateValidateFunction · 0.85

Tested by

no test coverage detected