Things and støff

This commit is contained in:
Kim Ravn Hansen
2025-09-14 20:43:06 +02:00
parent ed91a7f2f7
commit aeb9d776fc
25 changed files with 688 additions and 591 deletions

View File

@@ -2,10 +2,10 @@ import { PasswordPrompt } from "./passwordPrompt.js";
import { Player } from "../../models/player.js";
import { Scene } from "../scene.js";
import { UsernamePrompt } from "./usernamePrompt.js";
import { CreateUsernamePrompt } from "../playerCreation/createUsernamePrompt.js";
/** @property {Session} session */
export class AuthenticationScene extends Scene {
introText = [
"= Welcome", //
];
@@ -15,13 +15,13 @@ export class AuthenticationScene extends Scene {
onReady() {
// current prompt
this.doPrompt(new UsernamePrompt(this));
this.show(UsernamePrompt);
}
/** @param {Player} player */
usernameAccepted(player) {
this.player = player;
this.doPrompt(new PasswordPrompt(this));
this.show(PasswordPrompt);
}
passwordAccepted() {
@@ -34,4 +34,8 @@ export class AuthenticationScene extends Scene {
this.session.setScene("new JustLoggedInScene");
}
}
createPlayer() {
scene.session.setScene(new PlayerCreationScene(this.scene));
}
}