mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
World Info: Add support for character layering
Some characters have different cards depending on what the user wants from the character. However, maintaining multiple lorebooks for different personas of the same character can be difficult. In addition, there is redundancy, overlap, and possiblities to miss information when creating separate lorebooks with the same base info. Therefore, add a "DLC"/layering system of sorts for characters. This works the same way as multi-global world info where character lorebooks added as needed. The only catch is that a base character book must be tied to a card before selecting any extra info. Signed-off-by: kingbri <bdashore3@proton.me>
This commit is contained in:
@ -457,9 +457,9 @@ export function isDataURL(str) {
|
||||
return regex.test(str);
|
||||
}
|
||||
|
||||
export function getCharaFilename() {
|
||||
export function getCharaFilename(chid) {
|
||||
const context = getContext();
|
||||
const fileName = context.characters[context.characterId].avatar;
|
||||
const fileName = context.characters[chid ?? context.characterId].avatar;
|
||||
|
||||
if (fileName) {
|
||||
return fileName.replace(/\.[^/.]+$/, "")
|
||||
|
Reference in New Issue
Block a user