Skip to content

Commit

Permalink
Default new profile name to launcher username (#1066)
Browse files Browse the repository at this point in the history
Instead of always naming new profiles "SPTarkov", use the launcher
username as the default.

This improves the UX as you can quickly click through account creation
on multiple accounts without needing to remember to re-enter a new
profile name for each account
  • Loading branch information
chompDev authored Jan 10, 2025
2 parents c334855 + 89b292e commit 9612ca2
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions project/src/callbacks/ProfileCallbacks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,12 @@ export class ProfileCallbacks {
* Handle client/game/profile/nickname/reserved
*/
public getReservedNickname(url: string, info: IEmptyRequestData, sessionID: string): IGetBodyResponseData<string> {
const fullProfile = this.profileHelper.getFullProfile(sessionID);
if (fullProfile?.info?.username)
{
return this.httpResponse.getBody(fullProfile.info.username);
}

return this.httpResponse.getBody("SPTarkov");
}

Expand Down

0 comments on commit 9612ca2

Please sign in to comment.