Files
roll20-character-sheets/Household/Household.html
T

1208 lines
60 KiB
HTML

<div class="household-tooltips">
<span data-i18n="tooltips-u">TOOLTIPS <input class="household-tooltips-cb" type="checkbox" name="attr_tooltips"
checked></span>
<input type="hidden" name="attr_tooltips" value=""/>
<div class="household-tab-select">
<input type="radio" id="household-character" name="attr_household-tab" value="character" checked/>
<label for="household-character">Character</label>
<span></span>
<input type="radio" id="household-opponent" name="attr_household-tab" value="opponent"/>
<label for="household-opponent">Opponent</label>
</div>
<div class="household-character">
<div class="household-main-grid">
<!-- Dice images -->
<input type="hidden" name="attr_diceface1"
value="[img](https://files.d20.io/images/472619007/J2KfqPVPcobbXSgxqmrBMQ/original.png)"/>
<input type="hidden" name="attr_diceface2"
value="[img](https://files.d20.io/images/472619008/54rUC72-dP_R4yNcmZDWNw/original.png)"/>
<input type="hidden" name="attr_diceface3"
value="[img](https://files.d20.io/images/472619010/tN25xHUzhzHgwYc_8m4oiQ/original.png)"/>
<input type="hidden" name="attr_diceface4"
value="[img](https://files.d20.io/images/472619009/L0S6Aiz3aR54OrTNTsxnWA/original.png)"/>
<input type="hidden" name="attr_diceface5"
value="[img](https://files.d20.io/images/472619015/BLdD2v707EvLS0NIwTx7AA/original.png)"/>
<input type="hidden" name="attr_diceface6"
value="[img](https://files.d20.io/images/472619016/CJGnEpgCHKJ-8Nvvwhyn0Q/original.png)"/>
<input type="hidden" name="attr_lastroll" value=""/>
<div class="household-skills">
<div>
<img src="https://files.d20.io/images/472619018/P3FYrBpx_b_nHxODFChfQg/original.png">
<div class="household-skills-society">
<span data-i18n="society-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_society_skill1" id="society_skill1" checked>
<label for="society_skill1"></label>
<input type="checkbox" name="attr_society_skill2" id="society_skill2">
<label for="society_skill2"></label>
</div>
<div class="household-fields household-fields-society">
<span data-i18n="art-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_society_art1" id="society_art1" checked>
<label for="society_art1"></label>
<input type="checkbox" name="attr_society_art2" id="society_art2">
<label for="society_art2"></label>
<input type="checkbox" name="attr_society_art3" id="society_art3">
<label for="society_art3"></label>
<input type="checkbox" name="attr_society_art4" id="society_art4">
<label for="society_art4"></label>
</div>
<div class="household-fields household-fields-society">
<span data-i18n="charme-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_society_charm1" id="society_charm1" checked>
<label for="society_charm1"></label>
<input type="checkbox" name="attr_society_charm2" id="society_charm2">
<label for="society_charm2"></label>
<input type="checkbox" name="attr_society_charm3" id="society_charm3">
<label for="society_charm3"></label>
<input type="checkbox" name="attr_society_charm4" id="society_charm4">
<label for="society_charm4"></label>
</div>
<div class="household-fields household-fields-society">
<span data-i18n="eloquence-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_society_eloquence1" id="society_eloquence1" checked>
<label for="society_eloquence1"></label>
<input type="checkbox" name="attr_society_eloquence2" id="society_eloquence2">
<label for="society_eloquence2"></label>
<input type="checkbox" name="attr_society_eloquence3" id="society_eloquence3">
<label for="society_eloquence3"></label>
<input type="checkbox" name="attr_society_eloquence4" id="society_eloquence4">
<label for="society_eloquence4"></label>
</div>
<div class="household-fields household-fields-society">
<span data-i18n="etiquette-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_society_etiquette1" id="society_etiquette1" checked>
<label for="society_etiquette1"></label>
<input type="checkbox" name="attr_society_etiquette2" id="society_etiquette2">
<label for="society_etiquette2"></label>
<input type="checkbox" name="attr_society_etiquette3" id="society_etiquette3">
<label for="society_etiquette3"></label>
<input type="checkbox" name="attr_society_etiquette4" id="society_etiquette4">
<label for="society_etiquette4"></label>
</div>
<div class="household-fields household-fields-society">
<span data-i18n="grace-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_society_grace1" id="society_grace1" checked>
<label for="society_grace1"></label>
<input type="checkbox" name="attr_society_grace2" id="society_grace2">
<label for="society_grace2"></label>
<input type="checkbox" name="attr_society_grace3" id="society_grace3">
<label for="society_grace3"></label>
<input type="checkbox" name="attr_society_grace4" id="society_grace4">
<label for="society_grace4"></label>
</div>
</div>
<br>
<div>
<img src="https://files.d20.io/images/472619017/Y4Kiv3TgcB9U0UMFfglmSQ/original.png">
<div class="household-skills-academia">
<span data-i18n="academia-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_academia_skill1" id="academia_skill1" checked>
<label for="academia_skill1"></label>
<input type="checkbox" name="attr_academia_skill2" id="academia_skill2">
<label for="academia_skill2"></label>
</div>
<div class="household-fields household-fields-academia">
<span data-i18n="care-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_academia_care1" id="academia_care1" checked>
<label for="academia_care1"></label>
<input type="checkbox" name="attr_academia_care2" id="academia_care2">
<label for="academia_care2"></label>
<input type="checkbox" name="attr_academia_care3" id="academia_care3">
<label for="academia_care3"></label>
<input type="checkbox" name="attr_academia_care4" id="academia_care4">
<label for="academia_care4"></label>
</div>
<div class="household-fields household-fields-academia">
<span data-i18n="craft-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_academia_craft1" id="academia_craft1" checked>
<label for="academia_craft1"></label>
<input type="checkbox" name="attr_academia_craft2" id="academia_craft2">
<label for="academia_craft2"></label>
<input type="checkbox" name="attr_academia_craft3" id="academia_craft3">
<label for="academia_craft3"></label>
<input type="checkbox" name="attr_academia_craft4" id="academia_craft4">
<label for="academia_craft4"></label>
</div>
<div class="household-fields household-fields-academia">
<span data-i18n="culture-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_academia_culture1" id="academia_culture1" checked>
<label for="academia_culture1"></label>
<input type="checkbox" name="attr_academia_culture2" id="academia_culture2">
<label for="academia_culture2"></label>
<input type="checkbox" name="attr_academia_culture3" id="academia_culture3">
<label for="academia_culture3"></label>
<input type="checkbox" name="attr_academia_culture4" id="academia_culture4">
<label for="academia_culture4"></label>
</div>
<div class="household-fields household-fields-academia">
<span data-i18n="insight-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_academia_insight1" id="academia_insight1" checked>
<label for="academia_insight1"></label>
<input type="checkbox" name="attr_academia_insight2" id="academia_insight2">
<label for="academia_insight2"></label>
<input type="checkbox" name="attr_academia_insight3" id="academia_insight3">
<label for="academia_insight3"></label>
<input type="checkbox" name="attr_academia_insight4" id="academia_insight4">
<label for="academia_insight4"></label>
</div>
<div class="household-fields household-fields-academia">
<span data-i18n="investigation-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_academia_investigation1" id="academia_investigation1" checked>
<label for="academia_investigation1"></label>
<input type="checkbox" name="attr_academia_investigation2" id="academia_investigation2">
<label for="academia_investigation2"></label>
<input type="checkbox" name="attr_academia_investigation3" id="academia_investigation3">
<label for="academia_investigation3"></label>
<input type="checkbox" name="attr_academia_investigation4" id="academia_investigation4">
<label for="academia_investigation4"></label>
</div>
</div>
<br>
<div>
<img src="https://files.d20.io/images/472619023/ki0Rg-_mlcOtcCTF2-BdRA/original.png">
<div class="household-skills-war">
<span data-i18n="war-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_war_skill1" id="war_skill1" checked>
<label for="war_skill1"></label>
<input type="checkbox" name="attr_war_skill2" id="war_skill2">
<label for="war_skill2"></label>
</div>
<div class="household-fields household-fields-war">
<span data-i18n="athletics-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_war_athletics1" id="war_athletics1" checked>
<label for="war_athletics1"></label>
<input type="checkbox" name="attr_war_athletics2" id="war_athletics2">
<label for="war_athletics2"></label>
<input type="checkbox" name="attr_war_athletics3" id="war_athletics3">
<label for="war_athletics3"></label>
<input type="checkbox" name="attr_war_athletics4" id="war_athletics4">
<label for="war_athletics4"></label>
</div>
<div class="household-fields household-fields-war">
<span data-i18n="authority-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_war_authority1" id="war_authority1" checked>
<label for="war_authority1"></label>
<input type="checkbox" name="attr_war_authority2" id="war_authority2">
<label for="war_authority2"></label>
<input type="checkbox" name="attr_war_authority3" id="war_authority3">
<label for="war_authority3"></label>
<input type="checkbox" name="attr_war_authority4" id="war_authority4">
<label for="war_authority4"></label>
</div>
<div class="household-fields household-fields-war">
<span data-i18n="fight-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_war_fight1" id="war_fight1" checked>
<label for="war_fight1"></label>
<input type="checkbox" name="attr_war_fight2" id="war_fight2">
<label for="war_fight2"></label>
<input type="checkbox" name="attr_war_fight3" id="war_fight3">
<label for="war_fight3"></label>
<input type="checkbox" name="attr_war_fight4" id="war_fight4">
<label for="war_fight4"></label>
</div>
<div class="household-fields household-fields-war">
<span data-i18n="strength-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_war_strength1" id="war_strength1" checked>
<label for="war_strength1"></label>
<input type="checkbox" name="attr_war_strength2" id="war_strength2">
<label for="war_strength2"></label>
<input type="checkbox" name="attr_war_strength3" id="war_strength3">
<label for="war_strength3"></label>
<input type="checkbox" name="attr_war_strength4" id="war_strength4">
<label for="war_strength4"></label>
</div>
<div class="household-fields household-fields-war">
<span data-i18n="will-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_war_will1" id="war_will1" checked>
<label for="war_will1"></label>
<input type="checkbox" name="attr_war_will2" id="war_will2">
<label for="war_will2"></label>
<input type="checkbox" name="attr_war_will3" id="war_will3">
<label for="war_will3"></label>
<input type="checkbox" name="attr_war_will4" id="war_will4">
<label for="war_will4"></label>
</div>
</div>
<br>
<div>
<img src="https://files.d20.io/images/472619019/1HPp35XVdu5hyg91G9_CEw/original.png">
<div class="household-skills-street">
<span data-i18n="street-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_street_skill1" id="street_skill1" checked>
<label for="street_skill1"></label>
<input type="checkbox" name="attr_street_skill2" id="street_skill2">
<label for="street_skill2"></label>
</div>
<div class="household-fields household-fields-street">
<span data-i18n="caution-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_street_caution1" id="street_caution1" checked>
<label for="street_caution1"></label>
<input type="checkbox" name="attr_street_caution2" id="street_caution2">
<label for="street_caution2"></label>
<input type="checkbox" name="attr_street_caution3" id="street_caution3">
<label for="street_caution3"></label>
<input type="checkbox" name="attr_street_caution4" id="street_caution4">
<label for="street_caution4"></label>
</div>
<div class="household-fields household-fields-street">
<span data-i18n="dexterity-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_street_dexterity1" id="street_dexterity1" checked>
<label for="street_dexterity1"></label>
<input type="checkbox" name="attr_street_dexterity2" id="street_dexterity2">
<label for="street_dexterity2"></label>
<input type="checkbox" name="attr_street_dexterity3" id="street_dexterity3">
<label for="street_dexterity3"></label>
<input type="checkbox" name="attr_street_dexterity4" id="street_dexterity4">
<label for="street_dexterity4"></label>
</div>
<div class="household-fields household-fields-street">
<span data-i18n="elusion-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_street_elusion1" id="street_elusion1" checked>
<label for="street_elusion1"></label>
<input type="checkbox" name="attr_street_elusion2" id="street_elusion2">
<label for="street_elusion2"></label>
<input type="checkbox" name="attr_street_elusion3" id="street_elusion3">
<label for="street_elusion3"></label>
<input type="checkbox" name="attr_street_elusion4" id="street_elusion4">
<label for="street_elusion4"></label>
</div>
<div class="household-fields household-fields-street">
<span data-i18n="exploration-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_street_exploration1" id="street_exploration1" checked>
<label for="street_exploration1"></label>
<input type="checkbox" name="attr_street_exploration2" id="street_exploration2">
<label for="street_exploration2"></label>
<input type="checkbox" name="attr_street_exploration3" id="street_exploration3">
<label for="street_exploration3"></label>
<input type="checkbox" name="attr_street_exploration4" id="street_exploration4">
<label for="street_exploration4"></label>
</div>
<div class="household-fields household-fields-street">
<span data-i18n="shoot-u" class="hhtooltip"></span>
<input type="checkbox" name="attr_street_shoot1" id="street_shoot1" checked>
<label for="street_shoot1"></label>
<input type="checkbox" name="attr_street_shoot2" id="street_shoot2">
<label for="street_shoot2"></label>
<input type="checkbox" name="attr_street_shoot3" id="street_shoot3">
<label for="street_shoot3"></label>
<input type="checkbox" name="attr_street_shoot4" id="street_shoot4">
<label for="street_shoot4"></label>
</div>
</div>
</div>
<div class="household-aces">
<h3 data-i18n="acesupthesleeve-u" class="hhtooltip"></h3>
<br>
<br>
<div>
<div>
<input type="checkbox" name="attr_ace_heart" id="ace_heart">
<label for="ace_heart"></label>
</div>
<div>
<input type="checkbox" name="attr_ace_diamond" id="ace_diamond">
<label for="ace_diamond"></label>
</div>
<div>
<input type="checkbox" name="attr_ace_club" id="ace_club">
<label for="ace_club"></label>
</div>
<div>
<input type="checkbox" name="attr_ace_spade" id="ace_spade">
<label for="ace_spade"></label>
</div>
<div>
<input type="checkbox" name="attr_ace_joker" id="ace_joker">
<label for="ace_joker"></label>
</div>
</div>
</div>
<div class="household-decorum">
<h3 data-i18n="decorum-u" class="hhtooltip"></h3>
<div>
<div>
<input type="radio" name="attr_decorum" id="decorum_uncouth" value="uncouth">
<label for="decorum_uncouth"></label>
<span data-i18n="uncouth-u"></span>
</div>
<div>
<input type="radio" name="attr_decorum" id="decorum_shabby" value="shabby">
<label for="decorum_shabby"></label>
<span data-i18n="shabby-u"></span>
</div>
<div>
<input type="radio" name="attr_decorum" id="decorum_decent" value="decent">
<label for="decorum_decent"></label>
<span data-i18n="decent-u"></span>
</div>
<div>
<input type="radio" name="attr_decorum" id="decorum_elegant" value="elegant">
<label for="decorum_elegant"></label>
<span data-i18n="elegant-u"></span>
</div>
<div>
<input type="radio" name="attr_decorum" id="decorum_pompous" value="pompous">
<label for="decorum_pompous"></label>
<span data-i18n="pompous-u"></span>
</div>
</div>
</div>
<div class="household-avatar">
<img name="attr_character_avatar">
<img class="household-logo"
src="https://files.d20.io/images/472619024/WD5IjZX7QHO-jEwMjLQkVQ/original.png">
<div class="outgunned-dice-roller">
<input type="number" name="attr_num_dice" min="2" max="9" value="2">
<button type="action" name="act_diceroller" data-i18n="roll-u">ROLL</button>
<br>
<br>
<button type="action" name="act_reroll" data-i18n="reroll-u">RE-ROLL</button>
<button type="action" name="act_freereroll" data-i18n="freereroll-u">FREE RE-ROLL</button>
<button type="action" name="act_allin" data-i18n="allin-u">ALL IN</button>
</div>
</div>
<div class="household-traits">
<h3 data-i18n="traits-u" class="hhtooltip"></h3>
<div>
<input type="text" name="attr_trait_name" placeholder="Name">
<textarea name="attr_trait_text"></textarea>
</div>
<fieldset class="repeating_traits">
<div>
<input type="text" name="attr_name" placeholder="Name">
<textarea name="attr_text"></textarea>
</div>
</fieldset>
</div>
<div class="household-stress">
<h3 data-i18n="stress-u" class="hhtooltip"></h3>
<div>
<input type="checkbox" name="attr_stress1">
<input type="checkbox" name="attr_stress2">
<input type="checkbox" name="attr_stress3">
<input type="checkbox" name="attr_stress4">
<input type="checkbox" name="attr_stress5">
<input type="checkbox" name="attr_stress6">
<input type="checkbox" name="attr_stress7">
<span><input type="checkbox" name="attr_stress8"></span>
<input type="checkbox" name="attr_stress9">
<input type="checkbox" name="attr_stress10">
<input type="checkbox" name="attr_stress11">
<input type="checkbox" name="attr_stress12">
</div>
</div>
<div class="household-details">
<span data-i18n="name-u"></span>
<input type="text" name="attr_character_name">
<span data-i18n="folk-u"></span>
<input type="text" name="attr_folk">
<span data-i18n="homeland-u"></span>
<input type="text" name="attr_homeland">
<span data-i18n="profession-u"></span>
<input type="text" name="attr_profession">
<span data-i18n="vocation-u"></span>
<input type="text" name="attr_vocation">
<span data-i18n="languages-u"></span>
<input type="text" name="attr_languages">
<span data-i18n="appearance-u"></span>
<input type="text" name="attr_appearance">
</div>
<div class="household-moves">
<h3 class="hhtooltip" data-i18n="moves-u"></h3>
<div>
<div>
<input type="text" name="attr_move_name" placeholder="Name">
<div>
<input type="checkbox" name="attr_ace_heart_move" id="ace_heart_move">
<label for="ace_heart_move"></label>
</div>
<div>
<input type="checkbox" name="attr_ace_diamond_move" id="ace_diamond_move">
<label for="ace_diamond_move"></label>
</div>
<div>
<input type="checkbox" name="attr_ace_club_move" id="ace_club_move">
<label for="ace_club_move"></label>
</div>
<div>
<input type="checkbox" name="attr_ace_spade_move" id="ace_spade_move">
<label for="ace_spade_move"></label>
</div>
</div>
<textarea name="attr_move_text"></textarea>
<span>Used:
<input type="checkbox" name="attr_move_used" id="move_used">
<label for="move_used" title="Used"></label>
</span>
</div>
<fieldset class="repeating_moves">
<div class="household-rep-moves">
<div>
<input type="text" name="attr_move_name" placeholder="Name">
<div>
<label><input type="checkbox" name="attr_ace_heart_move"></label>
</div>
<div>
<label><input type="checkbox" name="attr_ace_diamond_move"></label>
</div>
<div>
<label><input type="checkbox" name="attr_ace_club_move"></label>
</div>
<div>
<label><input type="checkbox" name="attr_ace_spade_move"></label>
</div>
</div>
<textarea name="attr_move_text"></textarea>
<span>Used:
<label title="Used"><input type="checkbox" name="attr_move_used"></label>
</span>
</div>
</fieldset>
</div>
<div class="household-conditions">
<h3 data-i18n="conditions-u" class="hhtooltip"></h3>
<div>
<span data-i18n="embarrassed-u"></span>
<input type="checkbox" name="attr_condition_embarrassed" id="condition_embarrassed">
<label for="condition_embarrassed"></label>
<span data-i18n="confused-u"></span>
<input type="checkbox" name="attr_condition_confused" id="condition_confused">
<label for="condition_confused"></label>
<span data-i18n="hurt-u"></span>
<input type="checkbox" name="attr_condition_hurt" id="condition_hurt">
<label for="condition_hurt"></label>
<span data-i18n="frightened-u"></span>
<input type="checkbox" name="attr_condition_frightened" id="condition_frightened">
<label for="condition_frightened"></label>
<span data-i18n="tired-u"></span>
<input class="household-conditions-other" type="checkbox" name="attr_condition_tired">
<span data-i18n="sick-u"></span>
<input class="household-conditions-other" type="checkbox" name="attr_condition_sick">
<span data-i18n="poisoned-u"></span>
<input class="household-conditions-other" type="checkbox" name="attr_condition_poisoned">
<span data-i18n="broken-u"></span>
<input class="household-conditions-other" type="checkbox" name="attr_condition_broken">
<input type="text" name="attr_custom_condition_text1">
<input class="household-conditions-other" type="checkbox" name="attr_custom_condition_enabled1">
<input type="text" name="attr_custom_condition_text2">
<input class="household-conditions-other" type="checkbox" name="attr_custom_condition_enabled2">
<input type="text" name="attr_custom_condition_text3">
<input class="household-conditions-other" type="checkbox" name="attr_custom_condition_enabled3">
</div>
</div>
<div class="household-memories">
<h3 data-i18n="memories-u" class="hhtooltip"></h3>
<div>
<textarea name="attr_memory"></textarea>
</div>
<fieldset class="repeating_memories">
<div>
<textarea name="attr_name"></textarea>
</div>
</fieldset>
</div>
<div class="household-contracts">
<h3 data-i18n="contracts-u" class="hhtooltip"></h3>
<div>
<div>
<textarea name="attr_text_concession" placeholder="Concession"></textarea>
<span>Used:
<input type="checkbox" name="attr_contract_used" id="contract_used">
<label for="contract_used"></label>
</span>
</div>
<textarea name="attr_text_counterpart" placeholder="Counterpart"></textarea>
</div>
<fieldset class="repeating_contracts">
<div>
<input type="text" name="attr_name" placeholder="Name">
<div>
<textarea name="attr_text_concession" placeholder="Concession"></textarea>
<span>Used:
<label> <input type="checkbox" name="attr_contract_used"></label>
</span>
</div>
<textarea name="attr_text_counterpart" placeholder="Counterpart"></textarea>
</div>
</fieldset>
</div>
<div class="household-equipment">
<div class="household-societalclass">
<label data-i18n="poor-u"></label>
<input type="radio" name="attr_societal_class" value="poor">
<label data-i18n="middleclass-u"></label>
<input type="radio" name="attr_societal_class" value="middleclass">
<label data-i18n="welloff-u"></label>
<input type="radio" name="attr_societal_class" value="welloff">
<label data-i18n="rich-u"></label>
<input type="radio" name="attr_societal_class" value="rich">
</div>
<div class="household-coins">
<label data-i18n="coins-u"></label>
<input name="attr_coins" type="number" min="0" value="0">
</div>
<div class="household-equipment-list">
<h3 data-i18n="equipment-u" class="hhtooltip"></h3>
<div>
<input type="text" name="attr_equipment_name" placeholder="Name">
<!-- <input type="text" name="attr_equipment_description" placeholder="Description">-->
<textarea name="attr_equipment_description" placeholder="Description"></textarea>
</div>
</div>
<div class="household-equipment-list">
<fieldset class="repeating_equipment">
<div class="household-equipment-rep">
<input type="text" name="attr_name" placeholder="Name">
<textarea name="attr_equipment_description" placeholder="Description"></textarea>
</div>
</fieldset>
</div>
</div>
<div class="household-ttt">
<h3 data-i18n="ttt-u" class="hhtooltip"></h3>
<div class="household-ttt-value">
<label>1</label>
<input type="radio" name="attr_ttt_value" value="1">
<label>2</label>
<input type="radio" name="attr_ttt_value" value="2">
<label>3</label>
<input type="radio" name="attr_ttt_value" value="3">
<label>4</label>
<input type="radio" name="attr_ttt_value" value="4">
<label>5</label>
<input type="radio" name="attr_ttt_value" value="5">
</div>
<div class="household-ttt-text">
<fieldset class="repeating_ttt">
<div>
<textarea name="attr_value"></textarea>
</div>
</fieldset>
</div>
</div>
<div class="household-experiences">
<h3 class="hhtooltip" data-i18n="experience-u"></h3>
<div>
<textarea name="attr_experience"></textarea>
</div>
<fieldset class="repeating_experiences">
<div>
<textarea name="attr_name"></textarea>
</div>
</fieldset>
</div>
<div class="household-notes">
<h3 data-i18n="notes-u">Notes</h3>
<textarea name="attr_notes"></textarea>
</div>
</div>
</div>
<div class="household-opponent">
<div class="household-opponent-grid">
<br>
<div class="household-opponent-title">
<div>
<input type="text" name="attr_opponent_name">
<input type="checkbox" name="attr_opponent_difficulty_1" id="opponent_difficulty_1" value="1">
<label for="opponent_difficulty_1"></label>
<input type="checkbox" name="attr_opponent_difficulty_2" id="opponent_difficulty_2" value="1">
<label for="opponent_difficulty_2"></label>
<input type="checkbox" name="attr_opponent_difficulty_3" id="opponent_difficulty_3" value="1">
<label for="opponent_difficulty_3"></label>
<input type="checkbox" name="attr_opponent_difficulty_4" id="opponent_difficulty_4" value="1">
<label for="opponent_difficulty_4"></label>
<input type="checkbox" name="attr_opponent_difficulty_5" id="opponent_difficulty_5" value="1">
<label for="opponent_difficulty_5"></label>
</div>
</div>
<div class="household-opponent-portrait">
<img name="attr_character_avatar">
</div>
<div class="household-opponent-description">
<br>
<span data-i18n="description-u"></span>
<textarea name="attr_opponent_description"></textarea>
</div>
<br>
<div class="household-opponent-stress">
<span data-i18n="opponentstress-u"></span>
<div>
<input type="checkbox" name="attr_stress_1" placeholder="Name">
<input type="checkbox" name="attr_move_1" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_2" placeholder="Name">
<input type="checkbox" name="attr_move_2" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_3" placeholder="Name">
<input type="checkbox" name="attr_move_3" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_4" placeholder="Name">
<input type="checkbox" name="attr_move_4" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_5" placeholder="Name">
<input type="checkbox" name="attr_move_5" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_6" placeholder="Name">
<input type="checkbox" name="attr_move_6" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_7" placeholder="Name">
<input type="checkbox" name="attr_move_7" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_8" placeholder="Name">
<input type="checkbox" name="attr_move_8" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_9" placeholder="Name">
<input type="checkbox" name="attr_move_9" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_10" placeholder="Name">
<input type="checkbox" name="attr_move_10" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_11" placeholder="Name">
<input type="checkbox" name="attr_move_11" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_12" placeholder="Name">
<input type="checkbox" name="attr_move_12" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_13" placeholder="Name">
<input type="checkbox" name="attr_move_13" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_14" placeholder="Name">
<input type="checkbox" name="attr_move_14" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_15" placeholder="Name">
<input type="checkbox" name="attr_move_15" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_16" placeholder="Name">
<input type="checkbox" name="attr_move_16" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_17" placeholder="Name">
<input type="checkbox" name="attr_move_17" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_18" placeholder="Name">
<input type="checkbox" name="attr_move_18" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_19" placeholder="Name">
<input type="checkbox" name="attr_move_19" placeholder="Name">
</div>
<div>
<input type="checkbox" name="attr_stress_20" placeholder="Name">
<input type="checkbox" name="attr_move_20" placeholder="Name">
</div>
</div>
<span class="household-opponent-stressnote" data-i18n="opponentstressnote-u"></span>
<br>
<span></span>
<div class="household-opponent-label-textfield">
<span data-i18n="opponenttraits-u"></span>
<input type="text" name="attr_opponent_traits">
<span data-i18n="opponentoptional-u"></span>
<input type="text" name="attr_opponent_optionaltraits">
<span data-i18n="opponentmoves-u"></span>
<input type="text" name="attr_opponent_movelist">
<div class="household-opponent-actions">
<span data-i18n="opponentactions-u"></span>
<span></span>
<span class="household-opponent-textright">I</span>
<input type="text" name="attr_opponent_actions_1">
<span class="household-opponent-textright">II</span>
<input type="text" name="attr_opponent_actions_2">
<span class="household-opponent-textright">III</span>
<input type="text" name="attr_opponent_actions_3">
<span class="household-opponent-textright">IIII</span>
<input type="text" name="attr_opponent_actions_4">
<span class="household-opponent-textright">V</span>
<input type="text" name="attr_opponent_actions_5">
<span class="household-opponent-textright">VI</span>
<input type="text" name="attr_opponent_actions_6">
</div>
</div>
<div class="household-opponent-move-details">
<span data-i18n="opponentmovedetails-u"></span>
<span></span>
<fieldset class="repeating_opponent-movedetails">
<div class="household-opponent-move-rec">
<input type="text" name="attr_move_name">
<textarea name="attr_move_detail"></textarea>
</div>
</fieldset>
</div>
<br>
<div class="household-opponent-label-textfield">
<span data-i18n="opponentnotes-u"></span>
<textarea name="attr_opponent_notes"></textarea>
</div>
</div>
</div>
</div>
<rolltemplate class="sheet-rolltemplate-diceroller">
<div class="sheet-household-rolltemplate">
<div>
<span>{{character}}</span>
<div>{{diceresult1}} <span>{{resulttype1}}</span></div>
<div>{{diceresult2}} <span>{{resulttype2}}</span></div>
<div>{{diceresult3}} <span>{{resulttype3}}</span></div>
<div>{{diceresult4}} <span>{{resulttype4}}</span></div>
<div>{{diceresult5}} <span>{{resulttype5}}</span></div>
<div>{{diceresult6}} <span>{{resulttype6}}</span></div>
<div>
<span>{{message}}</span>
<span>{{result}}</span>
</div>
</div>
</div>
</rolltemplate>
<rolltemplate class="sheet-rolltemplate-hidden">
</rolltemplate>
<!-- -->
<!-- -->
<!-- Sheetworker -->
<!-- -->
<!-- -->
<script type="text/worker">
const getRollTemplate = function() {
return "&{template:diceroller} ";
}
const diceParser = function(info) {
console.log("Rolling dice!");
const attrsToGet = ["num_dice", "diceface1", "diceface2", "diceface3", "diceface4", "diceface5", "diceface6"];
const diceFace = "diceface";
getAttrs(attrsToGet, function(v) {
/*
v.diceface1 = "♥";
v.diceface2 = "♦";
v.diceface3 = "♣";
v.diceface4 = "♠";
v.diceface5 = "Ɦ";
v.diceface6 = "✄";
*/
console.log("Num dice: " + v.num_dice);
// Start a roll JUST to collect the dice roll results to build our output
startRoll("!&{template:default} {{roll=[[" + v.num_dice + "D6]]}}", (dummyResults) => {
// Roll results example : {"rollId":"-OTvv7we44Qrp8QNKp0u","results":{"roll":{"result":11,"dice":[2,6,1,2],"expression":"4D6","rolls":[{"sides":6,"dice":4,"results":[2,6,1,2]}]}}}
// Need to count up the matching rolls 'yahtzee' style
let aggregatedRolls = {
1: 0,
2: 0,
3: 0,
4: 0,
5: 0,
6: 0
};
dummyResults.results.roll.dice.forEach(val => {
aggregatedRolls[+val] = aggregatedRolls[+val]+1;
});
finishRoll(dummyResults.rollId, {});
const resultTypes = ["", "", "BASIC", "CRITICAL", "EXTREME", "IMPOSSIBLE", "JACKPOT!"]
// We now know how many of each dice values we rolled, so we can build strings of image urls and send them through another dice roll
let stubRoll = getRollTemplate() + "{{character= @{character_name} }} ";
let successes = 0;
for(let i=1; i<=6; i++) {
stubRoll += "{{diceresult" + i + "=" + v[diceFace + i].repeat(aggregatedRolls[i]) + "}} ";
if(aggregatedRolls[i] > 1) {
stubRoll += "{{resulttype" + i + "=" + resultTypes[aggregatedRolls[i]] + "}} ";
successes++;
}
}
// Store successes
aggregatedRolls.successes = successes;
// Store re-roll, free re-roll and all-in statuses
aggregatedRolls.reroll = false;
aggregatedRolls.freereroll = false;
aggregatedRolls.allin = false;
console.log("Aggregated rolls: " + JSON.stringify(aggregatedRolls));
// Store the roll results for re-rolls etc.
setAttrs({lastroll: JSON.stringify(aggregatedRolls)});
startRoll(getRollTemplate() + "{{character= @{character_name} }} " + stubRoll, (results) => {
finishRoll(results.rollId, {});
});
});
});
}
// Event callback
on("clicked:diceroller", diceParser);
// Re-roll and Free Re-Roll function
const reroll = function(info, free, allin) {
console.log("- Reroll: Free: " + free + " All-In: " + allin);
// Create our 'type' string for messages
let msgType = "Re-Roll";
if(free) {
msgType = "Free Re-Roll";
}
if(allin) {
msgType = "All-In";
}
// Get our last roll and our dice
const attrsToGet = ["num_dice", "lastroll", "diceface1", "diceface2", "diceface3", "diceface4", "diceface5", "diceface6"];
const diceFace = "diceface"
getAttrs(attrsToGet, function(values) {
/*
v.diceface1 = "♥";
v.diceface2 = "♦";
v.diceface3 = "♣";
v.diceface4 = "♠";
v.diceface5 = "Ɦ";
v.diceface6 = "✄";
*/
if(!values.lastroll) {
startRoll(getRollTemplate() + " {{character= @{character_name} }} {{message=No Roll To " + msgType + "}}", (results) => {
finishRoll(results.rollId, {});
});
return;
}
let aggregatedRolls = JSON.parse(values.lastroll);
// Store a copy to check for extra, or improved successes
let lastAggregatedRolls = JSON.parse(values.lastroll);
// If we haven't done a re-roll and we are all-in, then return
if((!aggregatedRolls.reroll && !aggregatedRolls.freereroll) && allin) {
startRoll(getRollTemplate() + "{{character= @{character_name} }} {{message=Cannot All-In Without A Re-Roll!}}", (results) => {
finishRoll(results.rollId, {});
});
return;
}
// If we are doing an All-In and didn't get a better result, then return
if(allin && !aggregatedRolls.betterResult) {
startRoll(getRollTemplate() + "{{character= @{character_name} }} {{message=Cannot All-In As Re-Roll Didn't Produce A Better Result!}}", (results) => {
finishRoll(results.rollId, {});
});
return;
}
if(aggregatedRolls.successes === 0 && !free) {
// Cannot re-roll with no successes UNLESS free
startRoll(getRollTemplate() + "{{character= @{character_name} }} {{message=Cannot Re-Roll With No Successes!}}", (results) => {
finishRoll(results.rollId, {});
});
return;
}
// If we've already done a re-roll and we are NOT all-in, then return
if((aggregatedRolls.reroll || aggregatedRolls.freereroll) && !allin) {
startRoll(getRollTemplate() + "{{character= @{character_name} }} {{message=Already Re-Rolled!}}", (results) => {
finishRoll(results.rollId, {});
});
return;
}
// If we are doing an All-In and haven't done a re-roll, then return
if(allin && !aggregatedRolls.reroll && !aggregatedRolls.freereroll) {
startRoll(getRollTemplate() + "{{character= @{character_name} }} {{message=Cannot All-In Without A Re-Roll First!}}", (results) => {
finishRoll(results.rollId, {});
});
return;
}
// If we are doing an All-In and haven't done a re-roll, then return
if(allin && aggregatedRolls.allin) {
startRoll(getRollTemplate() + "{{character= @{character_name} }} {{message=Cannot All-In More Than Once!}}", (results) => {
finishRoll(results.rollId, {});
});
return;
}
// Count the number of rolls where we got 1 symbol
let diceToReroll = 0;
for(let i=1; i<=6; i++) {
if(aggregatedRolls[i] === 1) {
diceToReroll++;
aggregatedRolls[i] = 0;
}
}
if(!diceToReroll && !free) {
// Send an error message via a roll template
console.log("ERROR: No dice to re-roll!");
startRoll(getRollTemplate() + "{{character= @{character_name} }} {{message=No Dice To " + msgType + "}}", (results) => {
finishRoll(results.rollId, {});
});
}
else {
// We have some dice to roll and add to our current results
console.log("Re-rolling " + diceToReroll + " dice");
startRoll("&{template:hidden} {{roll=[[" + diceToReroll + "D6]]}}", (dummyResults) => {
dummyResults.results.roll.dice.forEach(val => {
aggregatedRolls[+val] = aggregatedRolls[+val]+1;
});
finishRoll(dummyResults.rollId, {});
const resultTypes = ["", "", "BASIC", "CRITICAL", "EXTREME", "IMPOSSIBLE", "JACKPOT!"]
// We now know how many of each dice values we rolled, so we can build strings of image urls and send them through another dice roll
let stubRoll = getRollTemplate() + "{{character= @{character_name} }} ";
let successes = 0;
for(let i=1; i<=6; i++) {
stubRoll += "{{diceresult" + i + "=" + values[diceFace + i].repeat(aggregatedRolls[i]) + "}} ";
if(aggregatedRolls[i] > 1) {
stubRoll += "{{resulttype" + i + "=" + resultTypes[aggregatedRolls[i]] + "}} ";
successes++;
}
}
// Did the re-roll succeed? Yes, if:
// 1. There are more successes
// 2. One or more of the successes is better
let message = "Re-Roll Failed!\n\nLose A Success!";
if(free) {
message = "Free Re-Roll!";
}
if(allin) {
message = "All-In Failed!\n\nLose ALL Successes!";
}
let extraSuccesses = 0;
let increasedSuccesses = 0;
if(successes > aggregatedRolls.successes) {
console.log("Re-rolled more successes");
extraSuccesses = successes - aggregatedRolls.successes;
}
for(let i=1; i<=6; i++) {
if(lastAggregatedRolls[i] >= 2 && aggregatedRolls[i] > lastAggregatedRolls[i]) {
console.log("Increased success: " + i + ": " + aggregatedRolls[i] + " vs. " + lastAggregatedRolls[i]);
increasedSuccesses++;
}
}
if(extraSuccesses || increasedSuccesses) {
message = msgType + " Success!\n\n";
if(extraSuccesses) {
message += "" + extraSuccesses + " Extra Success" + (extraSuccesses > 1 ? "es!" : "!\n\n");
}
if(increasedSuccesses) {
message += "" + increasedSuccesses + " Increased Success" + (increasedSuccesses > 1 ? "es!" : "!\n" );
}
aggregatedRolls.betterResult = true;
}
else if(free) {
message = msgType + " Flat!\n\nNo Change!";
aggregatedRolls.betterResult = false;
}
else {
aggregatedRolls.betterResult = false;
}
// Store successes
aggregatedRolls.successes = successes;
if(free) {
aggregatedRolls.freereroll = true;
}
else if(allin) {
aggregatedRolls.allin = true;
}
else {
aggregatedRolls.reroll = true;
}
// Store the roll results for free re-rolls and all-ins
setAttrs({lastroll: JSON.stringify(aggregatedRolls)});
startRoll(stubRoll + " {{message=" + message + "}} ", (results) => {
finishRoll(results.rollId, {});
});
});
}
});
}
// Event callback for re-roll
on("clicked:reroll", reroll);
// Event callback for free re-roll
on("clicked:freereroll", function(info) {
console.log("Free Reroll");
reroll(info, true)
});
on("clicked:allin", function(info) {
console.log("All-In");
reroll(info, false, true)
});
// Function to force continuity across roulette checkboxes
on("change:roulette2 change:roulette3 change:roulette4 change:roulette5 change:roulette6 ", function(e) {
console.log("change:rouletteN: " + JSON.stringify(e));
// Fill in any blanks if user accidentally clicks out of sequence
getAttrs(["roulette1", "roulette2", "roulette3", "roulette4", "roulette5", "roulette6"], function(values) {
// Get changed number
let clicked = +e.sourceAttribute.replace("roulette", "");
// See how far round the wheel we are:
let current = 1;
let attrs = {};
for(let i=1; i<=6; i++) {
if(+values["roulette" + i] === 0 && i < clicked) {
// Fill it in
attrs["roulette" + i] = 1;
}
if(+values["roulette" + i] === 1 && i > clicked) {
// Fill it in
attrs["roulette" + i] = 0;
}
}
setAttrs(attrs, {silent: true});
});
});
/*
* Roulette dice roll
*/
on("clicked:roulette", function() {
getAttrs(["roulette1", "roulette2", "roulette3", "roulette4", "roulette5", "roulette6"], function(values) {
// See how far round the wheel we are:
let current = 1;
for(let i=1; i<=6; i++) {
if(+values["roulette" + i] === 1) {
current = i;
}
}
console.log("Current roulette: " + current);
// Now need to roll a D6 and get higher
startRoll("&{template:hidden} {{result=[[1D6]]}}", (dummyResults) => {
message = "SURVIVED!";
console.log(JSON.stringify(dummyResults));
if(dummyResults.results.result.result <= current) {
message = "LEFT FOR DEAD!"
}
else {
// Increment roulette
setAttrs({["roulette" + (current+1)]: "1"});
}
finishRoll(dummyResults.rollId, {});
startRoll(getRollTemplate() + "{{character= @{character_name} }} {{result=" + dummyResults.results.result.result + "}} {{message=" + message + "}}", (results) => {
finishRoll(results.rollId, {});
});
});
});
});
/*
* Sheet opened
*/
on("sheet:opened", function(e) {
console.log("sheet:opened: " + JSON.stringify(e));
// Reset last stored roll
setAttrs({lastroll: ""});
});
/*
*
*/
on("change:num_dice", function(e) {
let attrs;
if(+e.newValue < 2) {
attrs = {num_dice: 2};
}
if(+e.newValue > 9) {
attrs = {num_dice: 9};
}
if(attrs) {
setAttrs(attrs);
}
});
on("change:repeating_stress", function(e) {
console.log(JSON.stringify(e));
});
</script>
</div>