Add new character addition screen
This commit is contained in:
@@ -6,7 +6,7 @@ import { Capacitor } from "@capacitor/core"
|
||||
import { DataBase, type MessageGenerationInfo } from "./storage/database"
|
||||
|
||||
interface alertData{
|
||||
type: 'error'| 'normal'|'none'|'ask'|'wait'|'selectChar'|'input'|'toast'|'wait2'|'markdown'|'select'|'login'|'tos'|'cardexport'|'requestdata'
|
||||
type: 'error'| 'normal'|'none'|'ask'|'wait'|'selectChar'|'input'|'toast'|'wait2'|'markdown'|'select'|'login'|'tos'|'cardexport'|'requestdata'|'addchar'
|
||||
msg: string,
|
||||
submsg?: string
|
||||
}
|
||||
@@ -57,6 +57,21 @@ export async function alertNormalWait(msg:string){
|
||||
}
|
||||
}
|
||||
|
||||
export async function alertAddCharacter() {
|
||||
alertStore.set({
|
||||
'type': 'addchar',
|
||||
'msg': language.addCharacter
|
||||
})
|
||||
while(true){
|
||||
if (get(alertStore).type === 'none'){
|
||||
break
|
||||
}
|
||||
await sleep(10)
|
||||
}
|
||||
|
||||
return get(alertStore).msg
|
||||
}
|
||||
|
||||
export async function alertLogin(){
|
||||
alertStore.set({
|
||||
'type': 'login',
|
||||
|
||||
@@ -39,6 +39,7 @@ export const CurrentShowMemoryLimit = writable(db.showMemoryLimit)
|
||||
export const ShowVN = writable(false)
|
||||
export const SettingsMenuIndex = writable(-1)
|
||||
export const CurrentVariablePointer = writable({} as {[key:string]: string|number|boolean})
|
||||
export const OpenRealmStore = writable(false)
|
||||
|
||||
function createSimpleCharacter(char:character|groupChat){
|
||||
if((!char) || char.type === 'group'){
|
||||
|
||||
Reference in New Issue
Block a user