diff options
Diffstat (limited to 'launcher/minecraft/launch/ClaimAccount.cpp')
-rw-r--r-- | launcher/minecraft/launch/ClaimAccount.cpp | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/launcher/minecraft/launch/ClaimAccount.cpp b/launcher/minecraft/launch/ClaimAccount.cpp new file mode 100644 index 00000000..a1180f0a --- /dev/null +++ b/launcher/minecraft/launch/ClaimAccount.cpp @@ -0,0 +1,24 @@ +#include "ClaimAccount.h" +#include <launch/LaunchTask.h> + +ClaimAccount::ClaimAccount(LaunchTask* parent, AuthSessionPtr session): LaunchStep(parent) +{ + if(session->status == AuthSession::Status::PlayableOnline) + { + m_account = session->m_accountPtr; + } +} + +void ClaimAccount::executeTask() +{ + if(m_account) + { + lock.reset(new UseLock(m_account)); + emitSucceeded(); + } +} + +void ClaimAccount::finalize() +{ + lock.reset(); +} |