Fix welcome page freezing
This commit is contained in:
@@ -93,12 +93,20 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
function getCbsCondition(){
|
function getCbsCondition(){
|
||||||
|
try{
|
||||||
const cbsConditions:CbsConditions = {
|
const cbsConditions:CbsConditions = {
|
||||||
firstmsg: firstMessage ?? false,
|
firstmsg: firstMessage ?? false,
|
||||||
chatRole: DBState.db.characters[$selectedCharID].chats[DBState.db.characters[$selectedCharID].chatPage]?.message?.[idx]?.role ?? null,
|
chatRole: DBState.db.characters[$selectedCharID].chats[DBState.db.characters[$selectedCharID].chatPage]?.message?.[idx]?.role ?? null,
|
||||||
}
|
}
|
||||||
return cbsConditions
|
return cbsConditions
|
||||||
}
|
}
|
||||||
|
catch(e){
|
||||||
|
return {
|
||||||
|
firstmsg: firstMessage ?? false,
|
||||||
|
chatRole: null,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function displaya(message:string){
|
function displaya(message:string){
|
||||||
msgDisplay = risuChatParser(message, {chara: name, chatID: idx, rmVar: true, visualize: true, cbsConditions: getCbsCondition()})
|
msgDisplay = risuChatParser(message, {chara: name, chatID: idx, rmVar: true, visualize: true, cbsConditions: getCbsCondition()})
|
||||||
|
|||||||
Reference in New Issue
Block a user