Files
PojavLauncher_iOS/Natives/authenticator/LocalAuthenticator.m
T
Eilionoir Tunnicliff 289b47abfc Move demo mode stuffs to secure location
This way, local mode users cannot use it to download game files without a license.
2023-01-19 11:44:04 -05:00

19 lines
617 B
Objective-C

#import "BaseAuthenticator.h"
@implementation LocalAuthenticator
- (void)loginWithCallback:(Callback)callback {
self.authData[@"oldusername"] = self.authData[@"username"] = self.authData[@"input"];
self.authData[@"accessToken"] = @"0";
self.authData[@"profileId"] = @"00000000-0000-0000-0000-000000000000";
setenv("POJAV_GAME_DIR", [NSString stringWithFormat:@"%s/Library/Application Support/minecraft", getenv("POJAV_HOME")].UTF8String, 1);
callback(nil, [super saveChanges]);
}
- (void)refreshTokenWithCallback:(Callback)callback {
// Nothing to do
callback(nil, YES);
}
@end