diff options
Diffstat (limited to 'logic/minecraft/onesix')
-rw-r--r-- | logic/minecraft/onesix/OneSixInstance.cpp | 8 | ||||
-rw-r--r-- | logic/minecraft/onesix/OneSixInstance.h | 2 |
2 files changed, 8 insertions, 2 deletions
diff --git a/logic/minecraft/onesix/OneSixInstance.cpp b/logic/minecraft/onesix/OneSixInstance.cpp index 54381a99..2846640c 100644 --- a/logic/minecraft/onesix/OneSixInstance.cpp +++ b/logic/minecraft/onesix/OneSixInstance.cpp @@ -150,7 +150,7 @@ QStringList OneSixInstance::processMinecraftArgs(AuthSessionPtr session) return parts; } -std::shared_ptr<LaunchTask> OneSixInstance::createLaunchTask(AuthSessionPtr session) +QString OneSixInstance::createLaunchScript(AuthSessionPtr session) { QString launchScript; QIcon icon = ENV.icons()->getIcon(iconKey()); @@ -256,7 +256,11 @@ std::shared_ptr<LaunchTask> OneSixInstance::createLaunchTask(AuthSessionPtr sess launchScript += "traits " + trait + "\n"; } launchScript += "launcher onesix\n"; + return launchScript; +} +std::shared_ptr<LaunchTask> OneSixInstance::createLaunchTask(AuthSessionPtr session) +{ auto process = LaunchTask::create(std::dynamic_pointer_cast<MinecraftInstance>(getSharedPtr())); auto pptr = process.get(); @@ -290,7 +294,7 @@ std::shared_ptr<LaunchTask> OneSixInstance::createLaunchTask(AuthSessionPtr sess { auto step = std::make_shared<LaunchMinecraft>(pptr); step->setWorkingDirectory(minecraftRoot()); - step->setLaunchScript(launchScript); + step->setAuthSession(session); process->appendStep(step); } // run post-exit command if that's needed diff --git a/logic/minecraft/onesix/OneSixInstance.h b/logic/minecraft/onesix/OneSixInstance.h index 824e3786..09150158 100644 --- a/logic/minecraft/onesix/OneSixInstance.h +++ b/logic/minecraft/onesix/OneSixInstance.h @@ -56,6 +56,8 @@ public: virtual std::shared_ptr<LaunchTask> createLaunchTask(AuthSessionPtr account) override; virtual std::shared_ptr<Task> createJarModdingTask() override; + virtual QString createLaunchScript(AuthSessionPtr session) override; + virtual void cleanupAfterRun() override; virtual QString intendedVersionId() const override; |