Release 1.8.2
This commit is contained in:
@@ -130,16 +130,16 @@ export class CharacterGenerator {
|
||||
* @return {Promise<string>}
|
||||
*/
|
||||
static async getRandomizedFirstname(isFemale, clan) {
|
||||
let table = `Japanese names (${isFemale ? "Female" : "Male"})`;
|
||||
let table = `L5RCoreTblJpNam${isFemale ? "F" : "M"}`;
|
||||
switch (clan) {
|
||||
case "ivory_kingdoms":
|
||||
table = "Ivory Kingdoms names";
|
||||
table = "aTVXI5Y5t7cBfyUE";
|
||||
break;
|
||||
case "qamarist":
|
||||
table = "Qamarist names";
|
||||
table = "bXaEmt72GLUeoyzz";
|
||||
break;
|
||||
case "ujik":
|
||||
table = "Ujik names";
|
||||
table = "d9lU98NE8G2YuN48";
|
||||
break;
|
||||
}
|
||||
const randomNames = await game.l5r5e.HelpersL5r5e.drawManyFromPack("l5r5e.core-name-tables", table, 1, {
|
||||
|
||||
@@ -745,7 +745,7 @@ export class HelpersL5r5e {
|
||||
/**
|
||||
* Shortcut method to draw names to chat (private) from a table in compendium without importing it
|
||||
* @param {String} pack Compendium name
|
||||
* @param {String} tableName Table name in this compendium
|
||||
* @param {String} tableName Table name/id in this compendium
|
||||
* @param {String} retrieve How many draw we do
|
||||
* @param {object} opt drawMany config option object
|
||||
* @return {Promise<{RollTableDraw}>} The drawn results
|
||||
@@ -758,7 +758,7 @@ export class HelpersL5r5e {
|
||||
}
|
||||
await comp.getDocuments();
|
||||
|
||||
const table = await comp.getName(tableName);
|
||||
const table = await (/^[a-zA-Z0-9]{16}$/.test(tableName) ? comp.get(tableName) : comp.getName(tableName));
|
||||
if (!table) {
|
||||
console.log(`L5R5E | Table not found[${tableName}]`, comp, table);
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user