Some checks on 20Q
Fix a bug with babele on drop a compendium in 20q
This commit is contained in:
@@ -285,7 +285,7 @@
|
|||||||
"incskill3": "Skill increases (3-5)",
|
"incskill3": "Skill increases (3-5)",
|
||||||
"choosem": "Pick one",
|
"choosem": "Pick one",
|
||||||
"choosef": "Pick one",
|
"choosef": "Pick one",
|
||||||
"money": "Starting wealth :",
|
"money": "Starting wealth in Koku :",
|
||||||
"glory": "Glory :",
|
"glory": "Glory :",
|
||||||
"school": "School :",
|
"school": "School :",
|
||||||
"status": "Status",
|
"status": "Status",
|
||||||
|
|||||||
@@ -285,7 +285,7 @@
|
|||||||
"incskill3": "Skill increases (3-5)",
|
"incskill3": "Skill increases (3-5)",
|
||||||
"choosem": "Pick one",
|
"choosem": "Pick one",
|
||||||
"choosef": "Pick one",
|
"choosef": "Pick one",
|
||||||
"money": "Starting wealth :",
|
"money": "Starting wealth in Koku :",
|
||||||
"glory": "Glory :",
|
"glory": "Glory :",
|
||||||
"school": "School :",
|
"school": "School :",
|
||||||
"status": "Status",
|
"status": "Status",
|
||||||
|
|||||||
@@ -285,7 +285,7 @@
|
|||||||
"incskill3": "Augmentations de compétences (3-5)",
|
"incskill3": "Augmentations de compétences (3-5)",
|
||||||
"choosem": "En choisir un",
|
"choosem": "En choisir un",
|
||||||
"choosef": "En choisir une",
|
"choosef": "En choisir une",
|
||||||
"money": "Fortune de départ :",
|
"money": "Fortune de départ en Koku :",
|
||||||
"glory": "Gloire :",
|
"glory": "Gloire :",
|
||||||
"school": "École :",
|
"school": "École :",
|
||||||
"status": "Statut",
|
"status": "Statut",
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
import { HelpersL5r5e } from "../helpers.js";
|
||||||
import { TwentyQuestions } from "./twenty-questions.js";
|
import { TwentyQuestions } from "./twenty-questions.js";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -12,14 +13,14 @@ export class TwentyQuestionsDialog extends FormApplication {
|
|||||||
actor = null;
|
actor = null;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Errors object
|
* Errors
|
||||||
*/
|
*/
|
||||||
errors = {};
|
errors = [];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Cache for items (techniques, adv...)
|
* Cache for items (techniques, adv...)
|
||||||
*/
|
*/
|
||||||
cache = {};
|
cache = null;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Assign the default options
|
* Assign the default options
|
||||||
@@ -67,7 +68,15 @@ export class TwentyQuestionsDialog extends FormApplication {
|
|||||||
this.actor = actor;
|
this.actor = actor;
|
||||||
this.object = new TwentyQuestions(actor);
|
this.object = new TwentyQuestions(actor);
|
||||||
this.errors = this.object.validateForm();
|
this.errors = this.object.validateForm();
|
||||||
this._constructCache();
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Construct async cache here
|
||||||
|
* @override
|
||||||
|
*/
|
||||||
|
async _render(force = false, options = {}) {
|
||||||
|
await this._constructCache();
|
||||||
|
return super._render(force, options);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -105,7 +114,7 @@ export class TwentyQuestionsDialog extends FormApplication {
|
|||||||
* @param options
|
* @param options
|
||||||
* @return {Object}
|
* @return {Object}
|
||||||
*/
|
*/
|
||||||
getData(options = null) {
|
async getData(options = null) {
|
||||||
return {
|
return {
|
||||||
...super.getData(options),
|
...super.getData(options),
|
||||||
ringsList: game.l5r5e.HelpersL5r5e.getRingsList(),
|
ringsList: game.l5r5e.HelpersL5r5e.getRingsList(),
|
||||||
@@ -114,10 +123,8 @@ export class TwentyQuestionsDialog extends FormApplication {
|
|||||||
techniquesList: CONFIG.l5r5e.techniques,
|
techniquesList: CONFIG.l5r5e.techniques,
|
||||||
data: this.object.data,
|
data: this.object.data,
|
||||||
cache: this.cache,
|
cache: this.cache,
|
||||||
errors: Object.keys(this.errors)
|
errors: this.errors.join(", "),
|
||||||
.map((key) => `${game.i18n.localize("l5r5e.rings." + key)} (${this.errors[key]})`)
|
hasErrors: this.errors.length > 0,
|
||||||
.join(", "), // TODO better msg :D
|
|
||||||
hasErrors: Object.keys(this.errors).length > 0,
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -138,7 +145,7 @@ export class TwentyQuestionsDialog extends FormApplication {
|
|||||||
const stepKey = $(event.currentTarget).parents(".tq-drag-n-drop").data("step");
|
const stepKey = $(event.currentTarget).parents(".tq-drag-n-drop").data("step");
|
||||||
const itemId = $(event.currentTarget).parents(".property").data("propertyId");
|
const itemId = $(event.currentTarget).parents(".property").data("propertyId");
|
||||||
this._deleteOwnedItem(stepKey, itemId);
|
this._deleteOwnedItem(stepKey, itemId);
|
||||||
this.render(false);
|
this.submit();
|
||||||
});
|
});
|
||||||
|
|
||||||
// Submit button
|
// Submit button
|
||||||
@@ -176,10 +183,7 @@ export class TwentyQuestionsDialog extends FormApplication {
|
|||||||
// Add the item (step and cache)
|
// Add the item (step and cache)
|
||||||
this._addOwnedItem(item, stepKey);
|
this._addOwnedItem(item, stepKey);
|
||||||
|
|
||||||
// TODO specific event (no added honor if tech selected etc)
|
this.submit();
|
||||||
// console.log(this.object.data, this.cache);
|
|
||||||
|
|
||||||
this.render(false);
|
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
console.warn(err);
|
console.warn(err);
|
||||||
}
|
}
|
||||||
@@ -194,14 +198,19 @@ export class TwentyQuestionsDialog extends FormApplication {
|
|||||||
* @override
|
* @override
|
||||||
*/
|
*/
|
||||||
async _updateObject(event, formData) {
|
async _updateObject(event, formData) {
|
||||||
|
// Check "Or" conditions
|
||||||
|
formData["step7.social_add_glory"] = formData["step7.skill"] === "none" ? 5 : 0;
|
||||||
|
formData["step8.social_add_honor"] = formData["step8.skill"] === "none" ? 10 : 0;
|
||||||
|
if (formData["step13.skill"] !== "none" && this.object.data.step13.advantage.length > 0) {
|
||||||
|
formData["step13.skill"] = "none";
|
||||||
|
}
|
||||||
|
|
||||||
// Update 20Q object data
|
// Update 20Q object data
|
||||||
this.object.updateFromForm(formData);
|
this.object.updateFromForm(formData);
|
||||||
|
|
||||||
// Get errors if any
|
// Get errors if any
|
||||||
this.errors = this.object.validateForm();
|
this.errors = this.object.validateForm();
|
||||||
|
|
||||||
// Only on close/submit
|
|
||||||
// if (event.type === "submit") {
|
|
||||||
// Store this form datas in actor
|
// Store this form datas in actor
|
||||||
this.actor.data.data.twenty_questions = this.object.data;
|
this.actor.data.data.twenty_questions = this.object.data;
|
||||||
this.actor.update({
|
this.actor.update({
|
||||||
@@ -209,16 +218,16 @@ export class TwentyQuestionsDialog extends FormApplication {
|
|||||||
twenty_questions: this.object.data,
|
twenty_questions: this.object.data,
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
// }
|
|
||||||
this.render(false);
|
this.render(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Construct the cache tree with Items full object
|
* Construct the cache tree with Items full object
|
||||||
*/
|
*/
|
||||||
_constructCache() {
|
async _constructCache() {
|
||||||
this.cache = {};
|
this.cache = {};
|
||||||
TwentyQuestions.itemsList.forEach((stepName) => {
|
for (const stepName of TwentyQuestions.itemsList) {
|
||||||
// Check if current step value is a array
|
// Check if current step value is a array
|
||||||
let step = getProperty(this.object.data, stepName);
|
let step = getProperty(this.object.data, stepName);
|
||||||
if (!step || !Array.isArray(step)) {
|
if (!step || !Array.isArray(step)) {
|
||||||
@@ -232,16 +241,19 @@ export class TwentyQuestionsDialog extends FormApplication {
|
|||||||
|
|
||||||
// Get linked Item, and store it in cache (delete null value and old items)
|
// Get linked Item, and store it in cache (delete null value and old items)
|
||||||
const newStep = [];
|
const newStep = [];
|
||||||
step.forEach((id) => {
|
for (const id of step) {
|
||||||
const item = game.items.get(id);
|
if (!id) {
|
||||||
if (!id || !item) {
|
continue;
|
||||||
return;
|
}
|
||||||
|
const item = await HelpersL5r5e.getObjectGameOrPack(id, "Item");
|
||||||
|
if (!item) {
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
newStep.push(id);
|
newStep.push(id);
|
||||||
getProperty(this.cache, stepName).push(item);
|
getProperty(this.cache, stepName).push(item);
|
||||||
});
|
}
|
||||||
setProperty(this.object.data, stepName, newStep);
|
setProperty(this.object.data, stepName, newStep);
|
||||||
});
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -50,15 +50,15 @@ export class TwentyQuestions {
|
|||||||
clan: "",
|
clan: "",
|
||||||
ring: "",
|
ring: "",
|
||||||
skill: "",
|
skill: "",
|
||||||
social_status: 0,
|
social_status: 30,
|
||||||
},
|
},
|
||||||
step2: {
|
step2: {
|
||||||
family: "",
|
family: "",
|
||||||
ring: "",
|
ring: "",
|
||||||
skill1: "",
|
skill1: "",
|
||||||
skill2: "",
|
skill2: "",
|
||||||
wealth: 0,
|
wealth: 3,
|
||||||
social_glory: 0,
|
social_glory: 39,
|
||||||
},
|
},
|
||||||
step3: {
|
step3: {
|
||||||
school: "",
|
school: "",
|
||||||
@@ -82,7 +82,7 @@ export class TwentyQuestions {
|
|||||||
techniques: [],
|
techniques: [],
|
||||||
school_ability: [],
|
school_ability: [],
|
||||||
equipment: [],
|
equipment: [],
|
||||||
social_honor: 0,
|
social_honor: 30,
|
||||||
},
|
},
|
||||||
step4: {
|
step4: {
|
||||||
stand_out: "",
|
stand_out: "",
|
||||||
@@ -97,12 +97,12 @@ export class TwentyQuestions {
|
|||||||
step7: {
|
step7: {
|
||||||
clan_relations: "",
|
clan_relations: "",
|
||||||
skill: "",
|
skill: "",
|
||||||
social_add_glory: null,
|
social_add_glory: 0,
|
||||||
},
|
},
|
||||||
step8: {
|
step8: {
|
||||||
bushido: "",
|
bushido: "",
|
||||||
skill: "",
|
skill: "",
|
||||||
social_add_honor: null,
|
social_add_honor: 0,
|
||||||
},
|
},
|
||||||
step9: {
|
step9: {
|
||||||
success: "",
|
success: "",
|
||||||
@@ -213,7 +213,7 @@ export class TwentyQuestions {
|
|||||||
const formData = this.data;
|
const formData = this.data;
|
||||||
|
|
||||||
// Update the actor real datas
|
// Update the actor real datas
|
||||||
actorDatas.zeni = formData.step2.wealth;
|
actorDatas.zeni = Math.floor(formData.step2.wealth * 50);
|
||||||
actorDatas.identity = {
|
actorDatas.identity = {
|
||||||
...actorDatas.identity,
|
...actorDatas.identity,
|
||||||
clan: formData.step1.clan,
|
clan: formData.step1.clan,
|
||||||
@@ -274,7 +274,7 @@ export class TwentyQuestions {
|
|||||||
if (itemData.data?.bought_at_rank) {
|
if (itemData.data?.bought_at_rank) {
|
||||||
itemData.data.bought_at_rank = 0;
|
itemData.data.bought_at_rank = 0;
|
||||||
}
|
}
|
||||||
actor.createEmbeddedEntity("OwnedItem", duplicate(itemData));
|
actor.createEmbeddedEntity("OwnedItem", itemData);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -292,13 +292,22 @@ export class TwentyQuestions {
|
|||||||
* Return a array of errors, empty array if no errors founds
|
* Return a array of errors, empty array if no errors founds
|
||||||
*/
|
*/
|
||||||
validateForm() {
|
validateForm() {
|
||||||
// Rings & Skills
|
const errors = [];
|
||||||
|
|
||||||
|
// Rings & Skills, 3pt max for each
|
||||||
const rings = this._checkRingsOrSkills("ringList", 2); // ring start at 1
|
const rings = this._checkRingsOrSkills("ringList", 2); // ring start at 1
|
||||||
|
for (const key in rings) {
|
||||||
|
errors.push(`${game.i18n.localize("l5r5e.rings." + key)} (${rings[key]})`);
|
||||||
|
}
|
||||||
|
|
||||||
const skills = this._checkRingsOrSkills("skillList", 3); // skill start at 0
|
const skills = this._checkRingsOrSkills("skillList", 3); // skill start at 0
|
||||||
|
for (const key in skills) {
|
||||||
|
errors.push(
|
||||||
|
`${game.i18n.localize("l5r5e.skills." + CONFIG.l5r5e.skills.get(key) + "." + key)} (${skills[key]})`
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
// TODO Techniques / peculiarities
|
return errors;
|
||||||
|
|
||||||
return { ...rings, ...skills };
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -97,6 +97,12 @@ export class HelpersL5r5e {
|
|||||||
|
|
||||||
// Unknown pack object, iterate all packs
|
// Unknown pack object, iterate all packs
|
||||||
for (const comp of game.packs) {
|
for (const comp of game.packs) {
|
||||||
|
// TODO Bug with babele if "comp.getEntity(id)" return null...
|
||||||
|
const babeleFix = (await comp.getIndex()).some((e) => e._id === id);
|
||||||
|
if (!babeleFix) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
const data = await comp.getEntity(id);
|
const data = await comp.getEntity(id);
|
||||||
if (data) {
|
if (data) {
|
||||||
return HelpersL5r5e.createItemFromCompendium(data);
|
return HelpersL5r5e.createItemFromCompendium(data);
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@@ -17,4 +17,16 @@
|
|||||||
.dropbox {
|
.dropbox {
|
||||||
min-height: 75px;
|
min-height: 75px;
|
||||||
}
|
}
|
||||||
|
.errors {
|
||||||
|
position: sticky;
|
||||||
|
top: 0px;
|
||||||
|
left: 0px;
|
||||||
|
z-index: 999;
|
||||||
|
display: block;
|
||||||
|
width: 100%;
|
||||||
|
background-color: $l5r5e-red;
|
||||||
|
border: 1px solid $dark-red;
|
||||||
|
border-radius: 1rem;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,7 +5,8 @@
|
|||||||
{{/each}}
|
{{/each}}
|
||||||
</ul>
|
</ul>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
{{#ifCond itemsList.length '<' hideDndAt}}
|
||||||
<fieldset class="{{itemType}} dropbox" data-step="{{stepName}}">
|
<fieldset class="{{itemType}} dropbox" data-step="{{stepName}}">
|
||||||
<legend class="section-header"><i class="fa fa-arrow-down" aria-hidden="true"></i> {{ localize 'l5r5e.global.drop_here' }}</legend>
|
<legend class="section-header"><i class="fa fa-arrow-down" aria-hidden="true"></i> {{ localize 'l5r5e.global.drop_here' }}</legend>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
{{/ifCond}}
|
||||||
@@ -121,7 +121,7 @@
|
|||||||
<label>
|
<label>
|
||||||
{{localize 'l5r5e.twenty_questions.money'}}
|
{{localize 'l5r5e.twenty_questions.money'}}
|
||||||
<br>
|
<br>
|
||||||
<input type="text" name="step2.wealth" value="{{data.step2.wealth}}" data-dtype="Number"
|
<input type="number" name="step2.wealth" value="{{data.step2.wealth}}" data-dtype="Number"
|
||||||
placeholder="0">
|
placeholder="0">
|
||||||
</label>
|
</label>
|
||||||
<br>
|
<br>
|
||||||
@@ -265,18 +265,18 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td class="fifty">
|
<td class="fifty">
|
||||||
{{localize 'l5r5e.twenty_questions.startech'}}
|
|
||||||
<br>
|
|
||||||
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step3.techniques stepName='step3.techniques' itemType='techniques' }}
|
|
||||||
<br>
|
|
||||||
{{localize 'l5r5e.twenty_questions.schoolab'}}
|
{{localize 'l5r5e.twenty_questions.schoolab'}}
|
||||||
<br>
|
<br>
|
||||||
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step3.school_ability stepName='step3.school_ability' itemType='techniques' }}
|
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step3.school_ability stepName='step3.school_ability' itemType='techniques' hideDndAt=1 }}
|
||||||
|
<br>
|
||||||
|
{{localize 'l5r5e.twenty_questions.startech'}}
|
||||||
|
<br>
|
||||||
|
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step3.techniques stepName='step3.techniques' itemType='techniques' hideDndAt=5 }}
|
||||||
</td>
|
</td>
|
||||||
<td class="fifty">
|
<td class="fifty">
|
||||||
{{localize 'l5r5e.twenty_questions.outfit'}}
|
{{localize 'l5r5e.twenty_questions.outfit'}}
|
||||||
<br>
|
<br>
|
||||||
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step3.equipment stepName='step3.equipment' itemType='items' }}
|
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step3.equipment stepName='step3.equipment' itemType='items' hideDndAt=10 }}
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
@@ -359,7 +359,7 @@
|
|||||||
{{localize 'l5r5e.twenty_questions.incglory'}}
|
{{localize 'l5r5e.twenty_questions.incglory'}}
|
||||||
<br>
|
<br>
|
||||||
<input type="number" name="step7.social_add_glory" value="{{data.step7.social_add_glory}}"
|
<input type="number" name="step7.social_add_glory" value="{{data.step7.social_add_glory}}"
|
||||||
data-dtype="Number" placeholder="0">
|
data-dtype="Number" placeholder="0" disabled>
|
||||||
</label>
|
</label>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@@ -396,7 +396,7 @@
|
|||||||
{{localize 'l5r5e.twenty_questions.inchonor'}}
|
{{localize 'l5r5e.twenty_questions.inchonor'}}
|
||||||
<br>
|
<br>
|
||||||
<input type="number" name="step8.social_add_honor" value="{{data.step8.social_add_honor}}"
|
<input type="number" name="step8.social_add_honor" value="{{data.step8.social_add_honor}}"
|
||||||
data-dtype="Number" placeholder="0">
|
data-dtype="Number" placeholder="0" disabled>
|
||||||
</label>
|
</label>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@@ -414,7 +414,7 @@
|
|||||||
<br>
|
<br>
|
||||||
{{localize 'l5r5e.twenty_questions.distinction'}}
|
{{localize 'l5r5e.twenty_questions.distinction'}}
|
||||||
<br>
|
<br>
|
||||||
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step9.distinction stepName='step9.distinction' itemType='peculiarities' }}
|
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step9.distinction stepName='step9.distinction' itemType='peculiarities' hideDndAt=1 }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
@@ -425,7 +425,7 @@
|
|||||||
<br>
|
<br>
|
||||||
{{localize 'l5r5e.twenty_questions.adversity'}}
|
{{localize 'l5r5e.twenty_questions.adversity'}}
|
||||||
<br>
|
<br>
|
||||||
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step10.adversity stepName='step10.adversity' itemType='peculiarities' }}
|
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step10.adversity stepName='step10.adversity' itemType='peculiarities' hideDndAt=1 }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
@@ -436,7 +436,7 @@
|
|||||||
<br>
|
<br>
|
||||||
{{localize 'l5r5e.twenty_questions.passion'}}
|
{{localize 'l5r5e.twenty_questions.passion'}}
|
||||||
<br>
|
<br>
|
||||||
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step11.passion stepName='step11.passion' itemType='peculiarities' }}
|
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step11.passion stepName='step11.passion' itemType='peculiarities' hideDndAt=1 }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
@@ -447,7 +447,7 @@
|
|||||||
<br>
|
<br>
|
||||||
{{localize 'l5r5e.twenty_questions.anxiety'}}
|
{{localize 'l5r5e.twenty_questions.anxiety'}}
|
||||||
<br>
|
<br>
|
||||||
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step12.anxiety stepName='step12.anxiety' itemType='peculiarities' }}
|
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step12.anxiety stepName='step12.anxiety' itemType='peculiarities' hideDndAt=1 }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
@@ -466,6 +466,7 @@
|
|||||||
<select name="step13.skill" class="skill-select">
|
<select name="step13.skill" class="skill-select">
|
||||||
{{#select data.step13.skill}}
|
{{#select data.step13.skill}}
|
||||||
<option value="none">{{localize 'l5r5e.twenty_questions.choosef'}}</option>
|
<option value="none">{{localize 'l5r5e.twenty_questions.choosef'}}</option>
|
||||||
|
{{#ifCond cache.step13.advantage.length '==' '0'}}
|
||||||
{{#each skillsList as |skills catId|}}
|
{{#each skillsList as |skills catId|}}
|
||||||
<optgroup label="{{localizeSkill catId 'title'}}">
|
<optgroup label="{{localizeSkill catId 'title'}}">
|
||||||
{{#each skills as |obj|}}
|
{{#each skills as |obj|}}
|
||||||
@@ -473,6 +474,7 @@
|
|||||||
{{/each}}
|
{{/each}}
|
||||||
</optgroup>
|
</optgroup>
|
||||||
{{/each}}
|
{{/each}}
|
||||||
|
{{/ifCond}}
|
||||||
{{/select}}
|
{{/select}}
|
||||||
</select>
|
</select>
|
||||||
</label>
|
</label>
|
||||||
@@ -483,7 +485,7 @@
|
|||||||
<td class="">
|
<td class="">
|
||||||
{{localize 'l5r5e.twenty_questions.advant'}}
|
{{localize 'l5r5e.twenty_questions.advant'}}
|
||||||
<br>
|
<br>
|
||||||
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step13.advantage stepName='step13.advantage' itemType='peculiarities' }}
|
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step13.advantage stepName='step13.advantage' itemType='peculiarities' hideDndAt=1 }}
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
@@ -491,7 +493,7 @@
|
|||||||
<br>
|
<br>
|
||||||
{{localize 'l5r5e.twenty_questions.disadvant'}}
|
{{localize 'l5r5e.twenty_questions.disadvant'}}
|
||||||
<br>
|
<br>
|
||||||
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step13.disadvantage stepName='step13.disadvantage' itemType='peculiarities' }}
|
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step13.disadvantage stepName='step13.disadvantage' itemType='peculiarities' hideDndAt=1 }}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -506,7 +508,7 @@
|
|||||||
<label>
|
<label>
|
||||||
{{localize 'l5r5e.twenty_questions.accoutr'}}
|
{{localize 'l5r5e.twenty_questions.accoutr'}}
|
||||||
<br>
|
<br>
|
||||||
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step14.special_features stepName='step14.special_features' itemType='items' }}
|
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step14.special_features stepName='step14.special_features' itemType='items' hideDndAt=1 }}
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -526,7 +528,7 @@
|
|||||||
<label>
|
<label>
|
||||||
{{localize 'l5r5e.twenty_questions.object'}}
|
{{localize 'l5r5e.twenty_questions.object'}}
|
||||||
<br>
|
<br>
|
||||||
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step16.item stepName='step16.item' itemType='items' }}
|
{{> 'systems/l5r5e/templates/actors/character/twenty-questions-item.html' itemsList=cache.step16.item stepName='step16.item' itemType='items' hideDndAt=1 }}
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user