12.0.29 - L'indexation d'Astrobazzarh #732
@ -491,8 +491,7 @@ export class RdDStatBlockParser {
|
||||
}
|
||||
|
||||
static extractName(actorType, statString) {
|
||||
switch (actorType) {
|
||||
case "personnage":
|
||||
if (actorType == "personnage") {
|
||||
// Check if ',né le' is present
|
||||
let namePersonnage = "Importé"
|
||||
if (statString.includes(", né")) {
|
||||
@ -505,7 +504,14 @@ export class RdDStatBlockParser {
|
||||
return Misc.upperFirst(namePersonnage?.value.toLowerCase());
|
||||
}
|
||||
}
|
||||
|
||||
const name = XRegExp.exec(statString, XRegExp("(?<value>.+)\\s+taille", 'giu'));
|
||||
if (actorType == "entite") {
|
||||
if (!(name?.value)) {
|
||||
const nameEntiteReve = XRegExp.exec(statString, XRegExp("(?<value>.+)\\s+rêve", 'giu'));
|
||||
return Misc.upperFirst(nameEntiteReve?.value || "Importé");
|
||||
}
|
||||
}
|
||||
return Misc.upperFirst(name?.value || "Importé");
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user