mirror of
https://github.com/Nighthawk42/roll20-character-sheets.git
synced 2026-09-01 04:32:28 +00:00
1046 lines
49 KiB
HTML
1046 lines
49 KiB
HTML
<input type="radio" name="attr_tab" class="tab tab1" value="1" checked="checked"><span title="Main"></span>
|
|
<input type="radio" name="attr_tab" class="tab tab2" value="2" style="top: -56px;left: 235px;" ><span title="Background"></span>
|
|
<input type="radio" name="attr_tab" class="tab tab3" value="3" style="top: -88px;left: 392px;" ><span title="Settings"></span>
|
|
|
|
<span class="version bold">Sheet Version: 1.55</span>
|
|
|
|
<!--
|
|
<div>
|
|
<button type="action" name="act_character" >Character</button>
|
|
<button type="action" name="act_journal" >Journal</button>
|
|
<button type="action" name="act_configuration" >Configuration</button>
|
|
</div>
|
|
<input type="hidden" class="sheet-tabstoggle" name="attr_sheetTab" value="character" />
|
|
-->
|
|
<!-- --------------------------------------------------------------------------------- -->
|
|
<!-- --------------------------- PAGE 1 ---------------------------------------------- -->
|
|
<!-- --------------------------------------------------------------------------------- -->
|
|
<div class="tab-content tab1 page1">
|
|
|
|
<!-- NAME SECTION -->
|
|
<div class="name section columnflex nowrap">
|
|
|
|
<div class="rowflex nowrap spaced">
|
|
|
|
<div class="columnflex nowrap">
|
|
<label style="width:100px;">Character name</label>
|
|
<input name="attr_character_name" type="text">
|
|
</div>
|
|
<div class="columnflex nowrap">
|
|
<label style="width:80px;">Player name</label>
|
|
<input name="attr_player_name" type="text">
|
|
</div>
|
|
<div class="columnflex nowrap">
|
|
<label>Campaign</label>
|
|
<input name="attr_campaign" type="text">
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="rowflex nowrap spaced">
|
|
|
|
<div class="columnflex nowrap">
|
|
<label>Race</label>
|
|
<input name="attr_race" placeholder="race" type="text">
|
|
</div>
|
|
<div class="columnflex nowrap">
|
|
<label>Origin</label>
|
|
<input name="attr_origin" placeholder="origin" type="text">
|
|
</div>
|
|
<div class="columnflex nowrap">
|
|
<label>Class</label>
|
|
<input name="attr_class" placeholder="class" type="text">
|
|
</div>
|
|
<div class="columnflex nowrap">
|
|
<label class="w40" title="@{rank}">Level</label>
|
|
<input name="attr_rank" title="@{rank}" type="number" placeholder="1" class="w40">
|
|
</div>
|
|
<div class="columnflex nowrap">
|
|
<label class="w40" title="Hit Dice">HD</label>
|
|
<input name="attr_hd" type="text" placeholder="d8" title="Hit Dice: @{hd}" class="w40">
|
|
</div>
|
|
<div class="columnflex nowrap">
|
|
<label class="w30">MP</label>
|
|
<input name="attr_mp" type="number" placeholder="" title="Mission Points" class="w40">
|
|
</div>
|
|
<div class="columnflex nowrap">
|
|
<label class="w70" title="@{td}">Tension Die</label>
|
|
<select name="attr_td">
|
|
<option value="d4">d4</option>
|
|
<option value="d6" selected>d6</option>
|
|
<option value="d8">d8</option>
|
|
<option value="d10">d10</option>
|
|
<option value="d12">d12</option>
|
|
</select>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
<!-- ATTRIBUTES SECTION -->
|
|
|
|
<div class="attr columnflex nowrap spaced center">
|
|
<div class="stat columnflex nowrap center middle">
|
|
<button name="roll_str" title="%{str}" type="roll" value="@{whisper}&{template:stargate} {{title=Strength Check}} @{show_name} {{[[d20+(@{str_mod})]]=[[d20+(@{str_mod})]]}}" class="txt-btn large">STR</button>
|
|
<input name="attr_str" type="number" value="10">
|
|
<span class="mod" name="attr_str_mod" title="@{str_mod}"></span>
|
|
</div>
|
|
<div class="stat columnflex nowrap center middle">
|
|
<button name="roll_dex" type="roll" title="%{dex}" value="@{whisper}&{template:stargate} {{title=Dexterity Check}} @{show_name} {{[[d20+(@{dex_mod})]]=[[d20+(@{dex_mod})]]}}" class="txt-btn large">DEX</button>
|
|
<input name="attr_dex" type="number" value="10">
|
|
<span class="mod" name="attr_dex_mod" title="@{dex_mod}"></span>
|
|
</div>
|
|
<div class="stat columnflex nowrap center middle">
|
|
<button name="roll_con" type="roll" title="%{con}" value="@{whisper}&{template:stargate} {{title=Constitution Check}} @{show_name} {{[[d20+(@{con_mod})]]=[[d20+(@{con_mod})]]}}" class="txt-btn large">CON</button>
|
|
<input name="attr_con" type="number" value="10">
|
|
<span class="mod" name="attr_con_mod" title="@{con_mod}"></span>
|
|
</div>
|
|
<div class="stat columnflex nowrap center middle">
|
|
<button name="roll_int" type="roll" title="%{int}" value="@{whisper}&{template:stargate} {{title=Intelligence Check}} @{show_name} {{[[d20+(@{int_mod})]]=[[d20+(@{int_mod})]]}}" class="txt-btn large">INT</button>
|
|
<input name="attr_int" type="number" value="10">
|
|
<span class="mod" name="attr_int_mod" title="@{int_mod}"></span>
|
|
</div>
|
|
<div class="stat columnflex nowrap center middle">
|
|
<button name="roll_wis" type="roll" title="%{wis}" value="@{whisper}&{template:stargate} {{title=Wisdom Check}} @{show_name} {{[[d20+(@{wis_mod})]]=[[d20+(@{wis_mod})]]}}" class="txt-btn large">WIS</button>
|
|
<input name="attr_wis" type="number" value="10">
|
|
<span class="mod" name="attr_wis_mod" title="@{wis_mod}"></span>
|
|
</div>
|
|
<div class="stat columnflex nowrap center middle">
|
|
<button name="roll_cha" type="roll" title="%{cha}" value="@{whisper}&{template:stargate} {{title=Charisma Check}} @{show_name} {{[[d20+(@{cha_mod})]]=[[d20+(@{cha_mod})]]}}" class="txt-btn large">CHA</button>
|
|
<input name="attr_cha" type="number" value="10">
|
|
<span class="mod" name="attr_cha_mod" title="@{cha_mod}"></span>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
<!-- Skills (20)-->
|
|
|
|
<div class="skills section columnflex nowrap spaced">
|
|
<h3>Skills</h3>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_acrobatics_c" type="checkbox" value="1">
|
|
<input name="attr_acrobatics" type="number" title="@{acrobatics}" value="0" class="w30">
|
|
<button name="roll_acrobatics" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Acrobatics Check}} @{show_name} {{[[d20+(@{acrobatics})]]=[[d20+(@{acrobatics})]]}}">Acrobatics</button>
|
|
<span>(dex)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_animalhandling_c" type="checkbox" value="1">
|
|
<input name="attr_animalhandling" type="number" title="@{animalhandling}" value="0" class="w30">
|
|
<button name="roll_animalhandling" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Animal Handling Check}} @{show_name} {{[[d20+(@{animalhandling})]]=[[d20+(@{animalhandling})]]}}">Animal Handling</button>
|
|
<span>(wis)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_athletics_c" type="checkbox" value="1">
|
|
<input name="attr_athletics" type="number" title="@{athletics}" value="0" class="w30">
|
|
<button name="roll_athletics" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Athletics Check}} @{show_name} {{[[d20+(@{athletics})]]=[[d20+(@{athletics})]]}}">Athletics</button>
|
|
<span>(str)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_culture_c" type="checkbox" value="1">
|
|
<input name="attr_culture" type="number" title="@{culture}" value="0" class="w30">
|
|
<button name="roll_culture" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Culture Check}} @{show_name} {{[[d20+(@{culture})]]=[[d20+(@{culture})]]}}">Culture</button>
|
|
<span>(wis)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_deception_c" type="checkbox" value="1">
|
|
<input name="attr_deception" type="number" title="@{deception}" value="0" class="w30">
|
|
<button name="roll_deception" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Deception Check}} @{show_name} {{[[d20+(@{deception})]]=[[d20+(@{deception})]]}}">Deception</button>
|
|
<span>(cha)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_engineering_c" type="checkbox" value="1">
|
|
<input name="attr_engineering" type="number" title="@{engineering}" value="0" class="w30">
|
|
<button name="roll_engineering" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Engineering Check}} @{show_name} {{[[d20+(@{engineering})]]=[[d20+(@{engineering})]]}}">engineering</button>
|
|
<span>(int)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_history_c" type="checkbox" value="1">
|
|
<input name="attr_history" type="number" title="@{history}" value="0" class="w30">
|
|
<button name="roll_history" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=History Check}} @{show_name} {{[[d20+(@{history})]]=[[d20+(@{history})]]}}">history</button>
|
|
<span>(int)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_insight_c" type="checkbox" value="1">
|
|
<input name="attr_insight" type="number" title="@{insight}" value="0" class="w30">
|
|
<button name="roll_insight" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Insight Check}} @{show_name} {{[[d20+(@{insight})]]=[[d20+(@{insight})]]}}">insight</button>
|
|
<span>(wis)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_intimidation_c" type="checkbox" value="1">
|
|
<input name="attr_intimidation" type="number" title="@{intimidation}" value="0" class="w30">
|
|
<button name="roll_intimidation" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Intimidation Check}} @{show_name} {{[[d20+(@{intimidation})]]=[[d20+(@{intimidation})]]}}">intimidation</button>
|
|
<span>(cha)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_investigation_c" type="checkbox" value="1">
|
|
<input name="attr_investigation" type="number" title="@{investigation}" value="0" class="w30">
|
|
<button name="roll_investigation" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Investigation Check}} @{show_name} {{[[d20+(@{investigation})]]=[[d20+(@{investigation})]]}}">investigation</button>
|
|
<span>(int)</span>
|
|
</div>
|
|
|
|
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_medicine_c" type="checkbox" value="1">
|
|
<input name="attr_medicine" type="number" title="@{medicine}" value="0" class="w30">
|
|
<button name="roll_medicine" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=medicine Check}} @{show_name} {{[[d20+(@{medicine})]]=[[d20+(@{medicine})]]}}">medicine</button>
|
|
<span>(wis)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_nature_c" type="checkbox" value="1">
|
|
<input name="attr_nature" type="number" title="@{nature}" value="0" class="w30">
|
|
<button name="roll_nature" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=nature Check}} @{show_name} {{[[d20+(@{nature})]]=[[d20+(@{nature})]]}}">nature</button>
|
|
<span>(int)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_perception_c" type="checkbox" value="1">
|
|
<input name="attr_perception" type="number" title="@{perception}" value="0" class="w30">
|
|
<button name="roll_perception" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=perception Check}} @{show_name} {{[[d20+(@{perception})]]=[[d20+(@{perception})]]}}">perception</button>
|
|
<span>(wis)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_performance_c" type="checkbox" value="1">
|
|
<input name="attr_performance" type="number" title="@{performance}" value="0" class="w30">
|
|
<button name="roll_performance" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=performance Check}} @{show_name} {{[[d20+(@{performance})]]=[[d20+(@{performance})]]}}">performance</button>
|
|
<span>(cha)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_persuasion_c" type="checkbox" value="1">
|
|
<input name="attr_persuasion" type="number" title="@{persuasion}" value="0" class="w30">
|
|
<button name="roll_persuasion" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Persuasion Check}} @{show_name} {{[[d20+(@{persuasion})]]=[[d20+(@{persuasion})]]}}">persuasion</button>
|
|
<span>(cha)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_pilot_c" type="checkbox" value="1">
|
|
<input name="attr_pilot" type="number" title="@{}" value="0" class="w30">
|
|
<button name="roll_pilot" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=pilot Check}} @{show_name} {{[[d20+(@{pilot})]]=[[d20+(@{pilot})]]}}">pilot</button>
|
|
<span>(dex)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_science_c" type="checkbox" value="1">
|
|
<input name="attr_science" type="number" title="@{science}" value="0" class="w30">
|
|
<button name="roll_science" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=science Check}} @{show_name} {{[[d20+(@{science})]]=[[d20+(@{science})]]}}">science</button>
|
|
<span>(int)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_sleight_c" type="checkbox" value="1">
|
|
<input name="attr_sleight" type="number" title="@{sleight}" value="0" class="w30">
|
|
<button name="roll_sleight" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Sleight of Hand Check}} @{show_name} {{[[d20+(@{sleight})]]=[[d20+(@{sleight})]]}}">Sleight of Hand</button>
|
|
<span>(dex)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_stealth_c" type="checkbox" value="1">
|
|
<input name="attr_stealth" type="number" title="@{stealth}" value="0" class="w30">
|
|
<button name="roll_stealth" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=stealth Check}} @{show_name} {{[[d20+(@{stealth})]]=[[d20+(@{stealth})]]}}">stealth</button>
|
|
<span>(dex)</span>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_survival_c" type="checkbox" value="1">
|
|
<input name="attr_survival" type="number" title="@{survival}" value="0" class="w30">
|
|
<button name="roll_survival" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=survival Check}} @{show_name} {{[[d20+(@{survival})]]=[[d20+(@{survival})]]}}">survival</button>
|
|
<span>(wis)</span>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
<!-- hp -->
|
|
|
|
<div class="hp rowflex nowrap">
|
|
<div class="section columnflex nowrap middle center">
|
|
<label class="txtcenter" title="Hit Points">HP</label>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_hp" type="number" value="" placeholder="20" title="@{hp}" class="stat w40">
|
|
<span class="slash">/</span>
|
|
<input name="attr_hp_max" type="number" value="" placeholder="20" title="@{hp|max}" class="stat w40">
|
|
</div>
|
|
|
|
</div>
|
|
<div class="section columnflex nowrap middle center determ">
|
|
<label class="txtcenter" title="Temporary Hit Points">Temp HP</label>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_hp_temp" type="number" value="" title="@{hp_temp}" class="stat w40">
|
|
<span class="slash">/</span>
|
|
<input name="attr_hp_temp_max" type="number" value="" title="@{hp_temp|max}" class="stat w40">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<!-- condition -->
|
|
|
|
<div class="condition section columnflex nowrap spaced">
|
|
<h3 class="txtcenter" title="@{condition}" >CONDITION</h3>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_condition" type="radio" value="0" checked="true">
|
|
<span>Normal</span>
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_condition" type="radio" value="1">
|
|
<span>Disadv ability checks</span>
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_condition" type="radio" value="2">
|
|
<span>speed halved</span>
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_condition" type="radio" value="3">
|
|
<span>disadv attacks, saves</span>
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_condition" type="radio" value="4">
|
|
<span>HP max halved</span>
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_condition" type="radio" value="5">
|
|
<span>speed zero</span>
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_condition" type="radio" value="6">
|
|
<span>death</span>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<!-- prof -->
|
|
|
|
<div class="prof rowflex nowrap">
|
|
<div class="section columnflex nowrap middle center">
|
|
<label class="wide" title="Proficiency Bonus">Prof Bonus</label>
|
|
<input name="attr_prof" type="number" value="2" class="stat w40" title="Proficiency Bonus: @{prof}">
|
|
</div>
|
|
<div class="section columnflex nowrap middle center init">
|
|
<button name="roll_init" type="roll" value="@{whisper}&{template:stargate} {{title=Initiative}} @{show_name} {{ Roll =[[d20+(@{init}) &{tracker}]]}}" title="%{init}" class="txt-btn">Initiative</button>
|
|
<input name="attr_init" type="number" value="0" title="@{init}" class="stat w40">
|
|
</div>
|
|
<div class="section columnflex nowrap middle center moxie">
|
|
<button name="roll_moxie" type="roll" value="@{whisper}&{template:stargate} {{title=Moxie}} @{show_name} {{ Roll =[[d20+(@{moxie}) &{tracker}]]}}" class="txt-btn" title="Social Initiative: %{moxie}" >Moxie</button>
|
|
<input name="attr_moxie" type="number" value="0" class="stat w40" title="Social Initiative: @{moxie}">
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<!-- ac -->
|
|
|
|
<div class="ac rowflex nowrap">
|
|
<div class="section columnflex nowrap middle center">
|
|
<label class="wide">Armor Class</label>
|
|
<input name="attr_ac" type="number" value="10" class="stat w70" title="@{ac}">
|
|
</div>
|
|
<div class="section columnflex nowrap middle center">
|
|
<label class="wide">determination</label>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_determination" type="number" value="2" title="@{determination}" class="stat w40">
|
|
<span class="slash">/</span>
|
|
<input name="attr_determination_max" type="number" value="2" title="@{determination|max}" class="stat w40">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<!-- speed -->
|
|
|
|
<div class="speed rowflex nowrap">
|
|
<div class="section columnflex nowrap middle center">
|
|
<label class="bold txtcenter">Speed</label>
|
|
<input name="attr_speed" type="text" value="6m" class="w70 stat">
|
|
</div>
|
|
<div class="section death columnflex nowrap middle center">
|
|
<button name="roll_deathsave" type="roll" value="@{whisper}&{template:stargate} {{color=black}} {{title=Death Save}} @{show_name} {{Result=[[d20]]}}" title="%{deathsave}" class="txt-btn large">Death Save</button>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_death_success1" type="checkbox" value="1">
|
|
<input name="attr_death_success2" type="checkbox" value="1">
|
|
<input name="attr_death_success3" type="checkbox" value="1">
|
|
<span>Sucesses</span>
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_death_failure1" type="checkbox" value="1">
|
|
<input name="attr_death_failure2" type="checkbox" value="1">
|
|
<input name="attr_death_failure3" type="checkbox" value="1">
|
|
<span>Failures</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<!-- saves -->
|
|
|
|
<div class="saves section columnflex nowrap">
|
|
<h3>Saves</h3>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_str_save_c" type="checkbox" value="1">
|
|
<input name="attr_str_save" title="@{str_save}" type="number" value="0" title="@{str_save}" class="w30">
|
|
<button name="roll_str_save" title="%{str_save}" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Strength Save}} @{show_name} {{[[d20+(@{str_save})]]=[[d20+(@{str_save})]]}}" title="%{str_save}">Strength</button>
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_dex_save_c" type="checkbox" value="1">
|
|
<input name="attr_dex_save" type="number" value="0" title="@{dex_save}" class="w30">
|
|
<button name="roll_dex_save" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Dexterity Save}} @{show_name} {{[[d20+(@{dex_save})]]=[[d20+(@{dex_save})]]}}" title="%{dex_save}">Dexterity</button>
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_con_save_c" type="checkbox" value="1">
|
|
<input name="attr_con_save" type="number" value="0" class="w30">
|
|
<button name="roll_con_save" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Constitution Save}} @{show_name} {{[[d20+(@{con_save})]]=[[d20+(@{con_save})]]}}">Constitution</button>
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_int_save_c" type="checkbox" value="1">
|
|
<input name="attr_int_save" type="number" value="0" class="w30">
|
|
<button name="roll_int_save" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Intelligence Save}} @{show_name} {{[[d20+(@{int_save})]]=[[d20+(@{int_save})]]}}">Intelligence</button>
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<input name="attr_wis_save_c" type="checkbox" value="1">
|
|
<input name="attr_wis_save" type="number" value="0" class="w30">
|
|
<button name="roll_wis_save" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Wisdom Save}} @{show_name} {{[[d20+(@{wis_save})]]=[[d20+(@{wis_save})]]}}">Wisdom</button>
|
|
</div>
|
|
<div class="rowflex nowrap mb20">
|
|
<input name="attr_cha_save_c" type="checkbox" value="1">
|
|
<input name="attr_cha_save" type="number" value="0" class="w30">
|
|
<button name="roll_cha_save" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=Charisma Save}} @{show_name} {{[[d20+(@{cha_save})]]=[[d20+(@{cha_save})]]}}">Charisma</button>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<!-- bulk -->
|
|
|
|
<div class="bulk section columnflex nowrap middle center">
|
|
<h3>Tactical Vest Bulk</h3>
|
|
<input name="attr_bulk" type="number" value="8" class="stat w40">
|
|
</div>
|
|
|
|
<!-- ammo -->
|
|
|
|
|
|
|
|
<!-- inventory mini -->
|
|
|
|
<div class="section inventory columnflex nowrap center">
|
|
<h4>Inventory</h4>
|
|
<textarea name="attr_inventory" title="@{inventory}"></textarea>
|
|
</div>
|
|
|
|
<!-- attacks -->
|
|
|
|
<div class="attacks section">
|
|
<span class="name bold">Attack/Action Name</span>
|
|
<span class="bold">to hit</span>
|
|
<span class="bold pl20">dmg</span>
|
|
<span class="bold dmg-type">type</span>
|
|
<span class="bold">range</span>
|
|
<span class="bold">Cap/Reload</span>
|
|
<span class="bold pl20">special</span>
|
|
|
|
<!-- attack1 -->
|
|
<div class="rowflex nowrap">
|
|
<button name="roll_attack1" type="roll" title="%{attack1}" value="@{whisper}&{template:stargate} {{title=@{attack1}}} @{show_name} {{[[d20+(@{attack1_to_hit})]]=[[d20+(@{attack1_to_hit})]]}} {{Damage=[[@{attack1_dmg}+0]] @{attack1_dmgtype} }} {{desc=@{attack1_special} }}"></button>
|
|
<input name="attr_attack1" type="text" class="ml15" placeholder="Sidearm(Beretta M9)">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack1_to_hit" type="text" class="w40" placeholder="4">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack1_dmg" type="text" class="w70 mr15" placeholder="1d6">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack1_dmgtype" type="text" class="w50" placeholder="piercing">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack1_range" type="text" class="w50" placeholder="50/100">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack1_reload" type="text" class="w50" placeholder="15/1">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack1_special" type="text" class="w110 mr15">
|
|
</div>
|
|
|
|
<!-- attack2 -->
|
|
<div class="rowflex nowrap">
|
|
<button name="roll_attack2" type="roll" title="%{attack2}" value="@{whisper}&{template:stargate} {{title=@{attack2}}} @{show_name} {{[[d20+(@{attack2_to_hit})]]=[[d20+(@{attack2_to_hit})]]}} {{Damage=[[@{attack2_dmg}+0]] @{attack2_dmgtype} }} {{desc=@{attack2_special} }}"></button>
|
|
<input name="attr_attack2" type="text" class="ml15" placeholder="attack/action name">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack2_to_hit" type="text" class="w40" placeholder="4">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack2_dmg" type="text" class="w70 mr15" placeholder="1d6">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack2_dmgtype" type="text" class="w50">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack2_range" type="text" class="w50">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack2_reload" type="text" class="w50">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack2_special" type="text" class="w110 mr15">
|
|
</div>
|
|
|
|
<!-- attack3 -->
|
|
<div class="rowflex nowrap">
|
|
<button name="roll_attack3" type="roll" title="%{attack3}" value="@{whisper}&{template:stargate} {{title=@{attack3}}} @{show_name} {{[[d20+(@{attack3_to_hit})]]=[[d20+(@{attack3_to_hit})]]}} {{Damage=[[@{attack3_dmg}+0]] @{attack3_dmgtype} }} {{desc=@{attack3_special} }}"></button>
|
|
<input name="attr_attack3" type="text" class="ml15" placeholder="attack/action name">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack3_to_hit" type="text" class="w40" placeholder="4">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack3_dmg" type="text" class="w70 mr15" placeholder="1d6">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack3_dmgtype" type="text" class="w50">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack3_range" type="text" class="w50">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack3_reload" type="text" class="w50">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack3_special" type="text" class="w110 mr15">
|
|
</div>
|
|
|
|
<!-- attack4 -->
|
|
<div class="rowflex nowrap">
|
|
<button name="roll_attack4" type="roll" title="%{attack4}" value="@{whisper}&{template:stargate} {{title=@{attack4}}} @{show_name} {{[[d20+(@{attack4_to_hit})]]=[[d20+(@{attack4_to_hit})]]}} {{Damage=[[@{attack4_dmg}+0]] @{attack4_dmgtype} }} {{desc=@{attack4_special} }}"></button>
|
|
<input name="attr_attack4" type="text" class="ml15" placeholder="attack/action name">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack4_to_hit" type="text" class="w40" placeholder="4">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack4_dmg" type="text" class="w70 mr15" placeholder="1d6">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack4_dmgtype" type="text" class="w50">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack4_range" type="text" class="w50">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack4_reload" type="text" class="w50">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack4_special" type="text" class="w110 mr15">
|
|
</div>
|
|
|
|
<!-- attack5 -->
|
|
<div class="rowflex nowrap">
|
|
<button name="roll_attack5" type="roll" title="%{attack5}" value="@{whisper}&{template:stargate} {{title=@{attack5}}} @{show_name} {{[[d20+(@{attack5_to_hit})]]=[[d20+(@{attack5_to_hit})]]}} {{Damage=[[@{attack5_dmg}+0]] @{attack5_dmgtype} }} {{desc=@{attack5_special} }}"></button>
|
|
<input name="attr_attack5" type="text" class="ml15" placeholder="attack/action name">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack5_to_hit" type="text" class="w40" placeholder="4">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack5_dmg" type="text" class="w70 mr15" placeholder="1d6+@{td}">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack5_dmgtype" type="text" class="w50">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack5_range" type="text" class="w50">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack5_reload" type="text" class="w50">
|
|
</div>
|
|
<div>
|
|
<input name="attr_attack5_special" type="text" class="w110 mr15">
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<!-- --------------------------------------------------------------------------------- -->
|
|
<!-- --------------------------- PAGE 2 ---------------------------------------------- -->
|
|
<!-- --------------------------------------------------------------------------------- -->
|
|
<div class="tab-content tab2 page2">
|
|
|
|
<div class="section racial_abilities columnflex nowrap center">
|
|
<label>Racial Abilities</label>
|
|
<textarea name="attr_racial"></textarea>
|
|
</div>
|
|
|
|
<div class="section feats columnflex nowrap center">
|
|
<label>Feats</label>
|
|
<textarea name="attr_feats"></textarea>
|
|
</div>
|
|
|
|
<div class="section class columnflex nowrap center">
|
|
<label>Class Abilities</label>
|
|
<textarea name="attr_class_abilities"></textarea>
|
|
</div>
|
|
|
|
<div class="section equipment columnflex nowrap center">
|
|
<label>Equipment</label>
|
|
<textarea name="attr_equipment"></textarea>
|
|
</div>
|
|
|
|
<div class="section prof columnflex nowrap center">
|
|
<label>Proficiencies</label>
|
|
<textarea name="attr_proficiencies"></textarea>
|
|
</div>
|
|
|
|
<div class="section notes columnflex nowrap center">
|
|
<label>Notes</label>
|
|
<textarea name="attr_notes"></textarea>
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
<!-- --------------------------------------------------------------------------------- -->
|
|
<!-- --------------------------- PAGE 3 ---------------------------------------------- -->
|
|
<!-- --------------------------------------------------------------------------------- -->
|
|
|
|
|
|
<div class="tab-content tab3 page3">
|
|
|
|
<div class="section settings columnflex nowrap center">
|
|
<label>Settings</label>
|
|
|
|
<div class="rowflex nowrap">
|
|
<span title="@{whisper}">Whisper rolls?</span>
|
|
<input name="attr_whisper" title="@{whisper}" type="checkbox" value="/w gm">
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<span title="@{show_name}">Show name in rolls?</span>
|
|
<select name="attr_show_name" title="@{show_name}">
|
|
<option value="{{subtitle=@{character_name} }}">Yes</option>
|
|
<option value=" ">No</option>
|
|
</select>
|
|
</div>
|
|
|
|
<div class="rowflex nowrap">
|
|
<button name="roll_hd" type="roll" title="%{hd}" value="@{whisper}&{template:stargate} {{color=green}} {{title=Short Rest}} @{show_name} !modbattr --silent --name @{character_name} --hp|{{Healing=[[@{hd}]]}}!!! {{desc=One roll of the Hit Dice.}}">Short Rest</button>
|
|
<button name="roll_longrest" type="roll" title="%{longrest}" value="@{whisper}&{template:stargate} {{color=green}} {{title=Long Rest}} @{show_name} !modbattr --silent --name @{character_name} --hp|{{Healing=[[@{rank}@{hd}]]}}!!! {{desc=Rolls a number of Hit Dice equal to the characters level, and recovers that amount of health. }}">Long Rest</button>
|
|
<button name="roll_td" type="roll" title="%{td}" value="@{whisper}&{template:stargate} {{title=Tension Die (@{td})}} @{show_name} {{Roll=[[@{td}]]}} {{desc=Rolls the current tension die for the episode. }}">Tension Dice</button>
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<label>Custom roll</label>
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<button name="roll_custom1" type="roll" value="@{whisper}@{custom1}"></button>
|
|
<input type="text" name="attr_custom1" value="&{template:stargate} {{color=green}} {{title=Med Kit}} @{show_name} {{Healing=[[1d4]]}} {{desc=Heals someone with a medic kit. }}">
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<button name="roll_custom2" type="roll" value="@{whisper}@{custom2}"></button>
|
|
<input type="text" name="attr_custom2" value="&{template:stargate} {{color=white}} {{title=Scientific Discovery}} @{show_name} {{DC=[[8+(@{wis_mod}[wisdom modifier])+(@{prof}[proficiency])]] Wisdom or Intelligence Save}} {{desc=Archeologist: As an action you can cause a target emotional and mental distress by using cultural taboos against them. If the target fails a Wisdom save (DC 8+ Intelligence modifier + Proficiency Bonus) you may spend a number of Eureka points. The target is stunned for a number of rounds equal to the Eureka points spent. A target that passes its save is immune to this ability for 24 hours (and possibly very upset). }}">
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<button name="roll_custom3" type="roll" value="@{whisper}@{custom3}"></button>
|
|
<input type="text" name="attr_custom3" value="&{template:stargate} {{color=white}} {{title=Tension Die (@{td})}} @{show_name} {{Roll=[[@{td}]]}} {{desc=Rolls the current tension die for the episode. }}">
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<button name="roll_custom4" type="roll" value="@{whisper}@{custom4}"></button>
|
|
<input type="text" name="attr_custom4" value="&{template:stargate} {{title=Tension Die (@{td})}} @{show_name} {{Roll=[[@{td}]]}} {{desc=Rolls the current tension die for the episode. }}">
|
|
</div>
|
|
</div>
|
|
|
|
<div class="section other columnflex nowrap center">
|
|
<label>Other stats</label>
|
|
<div class="rowflex nowrap">
|
|
<span>Mission Points(MP):</span>
|
|
<input name="attr_mp" type="number" placeholder="" title="Mission Points @{mp}" class="w40">
|
|
/
|
|
<input name="attr_mp_max" type="number" placeholder="" title="Total Mission Points @{mp|max}" class="w40">
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<span>Eureka Points:</span>
|
|
<input name="attr_eureka" type="number" placeholder="" title="Eureka Points: @{eureka}" value="0" class="w40">
|
|
/
|
|
<input name="attr_eureka_max" type="number" placeholder="" title="Max Eureka Points: @{eureka|max}" class="w40">
|
|
</div>
|
|
<div class="columnflex nowrap">
|
|
<span>Wounds/Ability Damage</span>
|
|
<textarea name="attr_ability_damage" class="dmg"></textarea>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="section changelog columnflex nowrap center">
|
|
<img class="sheet-phoenix" src="https://raw.githubusercontent.com/Anduh/roll20-character-sheets/stargate-147/Stargate-RPG/images/SG-phoenix.png" alt="Stargate Phoenix logo">
|
|
<button name="roll_help" type="roll" class="txt-btn" value="@{whisper}&{template:stargate} {{title=[(Link)Sheet Userguide](https://wiki.roll20.net/Stargate) }} {{subtitle=Roll20 Wiki}} {{desc= (Right-click to open in a new tab)\n**Official Stargate RPG**\n**Roll20 Character Sheet**\n created by **Andreas J.**([@anduh_](https://twitter.com/anduh_)) }}">More Info</button>
|
|
<label>Changelog v.1.55(Nov. 3rd)</label>
|
|
<span>* more stats to track on Settings page</span>
|
|
<label>Changelog v.1.50(Oct. 20th)</label>
|
|
<span>* add Stargate Phoenix image to roll template<br>
|
|
* integrate ChatSetAttr commands to Short/Long Rest buttons<br>
|
|
* added whisper toggle to Saves<br>
|
|
* Link to sheet wiki page (button on settings page)</span>
|
|
</div>
|
|
|
|
|
|
<div class="ammo">
|
|
<div class="section columnflex nowrap">
|
|
<label class=" other">NPC stuff</label>
|
|
<div class="rowflex nowrap">
|
|
<span>CR:</span>
|
|
<input name="attr_cr" type="number" placeholder="" title="Challenge Rating: @{cr}" value="" class="w40">
|
|
<span>Speed</span>
|
|
<input name="attr_speed_npc" type="text" style="width:200px" placeholder="1m Fly(6m)" title="@{speed_npc}" value="" class="w40">
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<span>Type:</span>
|
|
<input name="attr_type" type="text" style="width:350px" placeholder="Medium Humanoid(Scout 2)" title="Challenge Rating: @{type}" value="" class="w40">
|
|
</div>
|
|
</div>
|
|
|
|
<div class="section columnflex nowrap">
|
|
<label class=" other">Living Series</label>
|
|
<div class="rowflex nowrap">
|
|
<span>Stargaterpg.com username</span>
|
|
<input name="attr_living_series_user" type="text" placeholder="" value="" class="w40" style="width:100px">
|
|
<span title="You can see your Roll20 id by going to your Roll20 profile page, and copying the numbers in the URL">Roll20 ID</span>
|
|
<input name="attr_roll20id" type="text" style="width:100px" title="You can see your Roll20 id by going to your Roll20 profile page, and copying the numbers in the URL" value="" class="w40">
|
|
</div>
|
|
<div class="rowflex nowrap">
|
|
<span>Stargaterpg.com character link</span>
|
|
<input name="attr_cahracter_link" type="text" style="width:350px" placeholder="The url to your character sheet" value="" class="w40">
|
|
</div>
|
|
</div>
|
|
|
|
<div class="ammo grid">
|
|
<div class="section columnflex nowrap middle center">
|
|
<label>Ammo Weapon 1</label>
|
|
<input name="attr_ammo1" type="number" value="0">
|
|
</div>
|
|
<div class="section columnflex nowrap middle center">
|
|
<label>Ammo Weapon 2</label>
|
|
<input name="attr_ammo2" type="number" value="0">
|
|
</div>
|
|
<div class="section columnflex nowrap middle center">
|
|
<label>Ammo Weapon 3</label>
|
|
<input name="attr_ammo3" type="number" value="0">
|
|
</div>
|
|
<div class="section columnflex nowrap middle center">
|
|
<label>Ammo Weapon 4</label>
|
|
<input name="attr_ammo4" type="number" value="0">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<!-- --------------------------------------------------------------------------------- -->
|
|
<!-- --------------------------- ROLL TEMPLATES -------------------------------------- -->
|
|
<!-- --------------------------------------------------------------------------------- -->
|
|
|
|
<rolltemplate class="sheet-rolltemplate-stargate">
|
|
<div class="sheet-container sheet-color-{{color}}">
|
|
<div class="sheet-header">
|
|
{{#title}}<div class="sheet-title">{{title}}<img class="sheet-phoenix" src="https://raw.githubusercontent.com/Anduh/roll20-character-sheets/stargate-147/Stargate-RPG/images/SG-phoenix.png" alt="Stargate Phoenix logo"> </div>{{/title}}
|
|
{{#subtitle}}<div class="sheet-subtitle">{{subtitle}}</div>{{/subtitle}}
|
|
</div>
|
|
<div class="sheet-content">
|
|
{{#allprops() title subtitle desc color}}
|
|
<div class="sheet-key">{{key}}</div>
|
|
<div class="sheet-value">{{value}}</div>
|
|
{{/allprops() title subtitle desc color}}
|
|
{{#desc}}<div class="sheet-desc">{{desc}}</div>{{/desc}}
|
|
</div>
|
|
</div>
|
|
</rolltemplate>
|
|
|
|
<!-- --------------------------------------------------------------------------------- -->
|
|
<!-- --------------------------- Sheet workers --------------------------------------- -->
|
|
<!-- --------------------------------------------------------------------------------- -->
|
|
|
|
<input name="attr_str_mod" type="hidden" value="+0">
|
|
<input name="attr_dex_mod" type="hidden" value="+0">
|
|
<input name="attr_con_mod" type="hidden" value="+0">
|
|
<input name="attr_wis_mod" type="hidden" value="+0">
|
|
<input name="attr_int_mod" type="hidden" value="+0">
|
|
<input name="attr_cha_mod" type="hidden" value="+0">
|
|
|
|
|
|
<script type="text/worker">
|
|
|
|
const int = score => parseInt(score, 10) || 0;
|
|
|
|
const stats = ["str", "dex", "con", "wis", "int", "cha"];
|
|
const skillslist = ["acrobatics", "animalhandling", "athletics", "culture", "deception", "engineering", "history", "insight", "intimidation", "investigation", "medicine", "nature", "perception", "performance", "persuasion", "pilot", "science", "sleight", "stealth", "survival"];
|
|
const statmods = ["str_mod", "dex_mod", "con_mod", "wis_mod", "int_mod", "cha_mod", "prof"];
|
|
|
|
|
|
// Calculate Stat modifier
|
|
|
|
stats.forEach(stat => {
|
|
on(`change:${stat}`, () => {
|
|
getAttrs([stat], values => {
|
|
const stat_base = int(values[stat]);
|
|
console.log("stat changed");
|
|
console.log(stat_base);
|
|
let stat_mod = 0;
|
|
if (stat_base >= 30) stat_mod = "+10";
|
|
else if (stat_base >= 28) stat_mod = "+9";
|
|
else if (stat_base >= 26) stat_mod = "+8";
|
|
else if (stat_base >= 24) stat_mod = "+7";
|
|
else if (stat_base >= 22) stat_mod = "+6";
|
|
else if (stat_base >= 20) stat_mod = "+5";
|
|
else if (stat_base >= 18) stat_mod = "+4";
|
|
else if (stat_base >= 16) stat_mod = "+3";
|
|
else if (stat_base >= 14) stat_mod = "+2";
|
|
else if (stat_base >= 12) stat_mod = "+1";
|
|
else if (stat_base >= 10) stat_mod = "+0";
|
|
else if (stat_base >= 8) stat_mod = "-1";
|
|
else if (stat_base >= 6) stat_mod = "-2";
|
|
else if (stat_base >= 4) stat_mod = "-3";
|
|
else if (stat_base >= 2) stat_mod = "-4";
|
|
else if (stat_base <= 1) stat_mod = "-5";
|
|
else stat_mod = "+0";
|
|
|
|
setAttrs({
|
|
[`${stat}_mod`]: stat_mod
|
|
});
|
|
});
|
|
});
|
|
});
|
|
|
|
|
|
// skill prof check/uncheck
|
|
|
|
skillslist.forEach(skillcheckbox => {
|
|
on(`change:${skillcheckbox}_c`, (eventInfo) => {
|
|
console.log("skill prof toggle");
|
|
console.log(skillcheckbox);
|
|
let xbox = skillcheckbox + "_c";
|
|
|
|
console.log("xbox defined");
|
|
console.log("xbox is " + xbox);
|
|
|
|
let getlist = [ xbox, "acrobatics", "animalhandling", "athletics", "culture", "deception", "engineering", "history", "insight", "intimidation", "investigation", "medicine", "nature", "perception", "performance", "persuasion", "pilot", "science", "sleight", "stealth", "survival", "acrobatics_c", "animalhandling_c", "athletics_c", "culture_c", "deception_c", "engineering_c", "history_c", "insight_c", "intimidation_c", "investigation_c", "medicine_c", "nature_c", "perception_c", "performance_c", "persuasion_c", "pilot_c", "science_c", "sleight_c", "stealth_c", "survival_c", "prof"];
|
|
console.log("def getlist");
|
|
|
|
getAttrs(getlist, values => {
|
|
console.log("getatt done");
|
|
let checkbox = int(values[xbox]);
|
|
let skillnow = int(values[skillcheckbox]);
|
|
let profval = int(values["prof"]);
|
|
let skillnew = 0;
|
|
console.log("checkbox " + checkbox + "skillnow " + skillnow);
|
|
|
|
if (checkbox === 1){
|
|
skillnew = skillnow + profval;
|
|
}
|
|
else{
|
|
skillnew = skillnow - profval;
|
|
}
|
|
console.log("skillew " + skillnew);
|
|
|
|
setAttrs({
|
|
[`${skillcheckbox}`]: skillnew
|
|
});
|
|
console.log("setAttr done");
|
|
});
|
|
});
|
|
});
|
|
|
|
|
|
// save prof check/uncheck
|
|
|
|
stats.forEach(savecheckbox => {
|
|
on(`change:${savecheckbox}_save_c`, (eventInfo) => {
|
|
console.log("save prof toggle");
|
|
console.log(savecheckbox);
|
|
let xbox = savecheckbox + "_save_c";
|
|
|
|
console.log("xbox defined");
|
|
console.log("xbox is " + xbox);
|
|
|
|
let getlist = [ xbox, "str_save", "dex_save", "con_save", "wis_save", "int_save", "cha_save","str_save_c", "dex_save_c", "con_save_c", "wis_save_c", "int_save_c", "cha_save_c", "prof"];
|
|
console.log("def getlist");
|
|
|
|
getAttrs(getlist, values => {
|
|
console.log("getatt done");
|
|
let checkbox = int(values[xbox]);
|
|
let savenow = int(values[`${savecheckbox}_save`]);
|
|
let profval = int(values["prof"]);
|
|
let savenew = 0;
|
|
console.log("checkbox " + checkbox + "savenow " + savenow);
|
|
|
|
if (checkbox === 1){
|
|
savenew = savenow + profval;
|
|
}
|
|
else{
|
|
savenew = savenow - profval;
|
|
}
|
|
console.log("skillew " + savenew);
|
|
|
|
setAttrs({
|
|
[`${savecheckbox}_save`]: savenew
|
|
});
|
|
console.log("setAttr done");
|
|
});
|
|
});
|
|
});
|
|
|
|
// proficiency changed, updates skills/saves
|
|
|
|
on(`change:prof`, eventInfo => {
|
|
console.log("prof change");
|
|
let profold = int(eventInfo.previousValue);
|
|
console.log("eventinfo: " + eventInfo.previousValue);
|
|
let getlist = ["acrobatics", "animalhandling", "athletics", "culture", "deception", "engineering", "history", "insight", "intimidation", "investigation", "medicine", "nature", "perception", "performance", "persuasion", "pilot", "science", "sleight", "stealth", "survival", "acrobatics_c", "animalhandling_c", "athletics_c", "culture_c", "deception_c", "engineering_c", "history_c", "insight_c", "intimidation_c", "investigation_c", "medicine_c", "nature_c", "perception_c", "performance_c", "persuasion_c", "pilot_c", "science_c", "sleight_c", "stealth_c", "survival_c", "str_save", "dex_save", "con_save", "wis_save", "int_save", "cha_save","str_save_c", "dex_save_c", "con_save_c", "wis_save_c", "int_save_c", "cha_save_c", "prof", "determination", "determination_max"];
|
|
|
|
getAttrs(getlist, values => {
|
|
|
|
var update = {};
|
|
let profnew = int(values["prof"]);
|
|
let profdiff = profnew - profold;
|
|
let determination = int(values["determination"]) + profdiff;
|
|
let determination_max = int(values["determination_max"]) + profdiff;
|
|
|
|
//manual fix for when you change proficiency for first time
|
|
if (profnew === 3 && profold ===3)( profdiff = 1);
|
|
|
|
determination = int(values["determination"]) + profdiff;
|
|
determination_max = int(values["determination_max"]) + profdiff;
|
|
update["determination"] = determination;
|
|
console.log("det worked");
|
|
update["determination_max"] = determination_max;
|
|
console.log("det max worked");
|
|
|
|
console.log("profold:" + profold + " profnew:" + profnew + " proffdiff: " + profdiff);
|
|
|
|
let xboxlist = ["acrobatics", "animalhandling", "athletics", "culture", "deception", "engineering", "history", "insight", "intimidation", "investigation", "medicine", "nature", "perception", "performance", "persuasion", "pilot", "science", "sleight", "stealth", "survival","str_save", "dex_save", "con_save", "wis_save", "int_save", "cha_save"];
|
|
|
|
xboxlist.forEach(number => {
|
|
|
|
let checkbox = int(values[`${number}_c`]);
|
|
|
|
if (checkbox === 1) {
|
|
let oldval = int(values[`${number}`]);
|
|
let newval = oldval + profdiff;
|
|
|
|
update[number] = newval;
|
|
}
|
|
|
|
});
|
|
|
|
console.log(update);
|
|
|
|
|
|
setAttrs(update);
|
|
|
|
});
|
|
});
|
|
|
|
// update skills & saves when attr mod changes
|
|
|
|
statmods.forEach(statmod => {
|
|
on(`change:${statmod}`, eventInfo => {
|
|
console.log("attr mod change");
|
|
console.log("old mod: " + eventInfo.previousValue);
|
|
let temp = eventInfo.previousValue;
|
|
if (temp === undefined){
|
|
temp = 0;
|
|
}else{
|
|
temp = temp.replace('+', '');
|
|
}
|
|
|
|
let oldstatmod = int(temp);
|
|
|
|
console.log("old mod: " + oldstatmod);
|
|
|
|
let getlist = ["str_mod", "dex_mod", "con_mod", "wis_mod", "int_mod", "cha_mod", "acrobatics", "animalhandling", "athletics", "culture", "deception", "engineering", "history", "insight", "intimidation", "investigation", "medicine", "nature", "perception", "performance", "persuasion", "pilot", "science", "sleight", "stealth", "survival", "str_save", "dex_save", "con_save", "wis_save", "int_save", "cha_save", "prof", "init", "moxie", "ac", "ac_extra", "determination","determination_max"];
|
|
|
|
getAttrs(getlist, values => {
|
|
|
|
var update = {};
|
|
|
|
let modnew = int(values[`${statmod}`]);
|
|
let moddiff = modnew - oldstatmod;
|
|
|
|
switch (`${statmod}`) {
|
|
case "str_mod":
|
|
console.log("oldstatmod: " + oldstatmod + " modnew:" + modnew + " moddiff: " + moddiff);
|
|
update["athletics"] = int(values["athletics"]) + moddiff;
|
|
update["str_save"] = int(values["str_save"]) + moddiff;
|
|
update["bulk"] = 8 + modnew;
|
|
|
|
setAttrs(update);
|
|
break;
|
|
case "con_mod":
|
|
//let modnew = int(values[`${statmod}`]);
|
|
//let moddiff = modnew - oldstatmod;
|
|
update["con_save"] = int(values["con_save"]) + moddiff;
|
|
|
|
setAttrs(update);
|
|
break;
|
|
case "dex_mod":
|
|
update["acrobatics"] = int(values["acrobatics"]) + moddiff;
|
|
update["pilot"] = int(values["pilot"]) + moddiff;
|
|
update["sleight"] = int(values["sleight"]) + moddiff;
|
|
update["stealth"] = int(values["stealth"]) + moddiff;
|
|
update["ac"] = int(values["ac"]) + moddiff;
|
|
update["ac_extra"] = int(values["ac_extra"]) + moddiff;
|
|
update["init"] = int(values["init"]) + moddiff;
|
|
update["dex_save"] = int(values["dex_save"]) + moddiff;
|
|
|
|
setAttrs(update);
|
|
break;
|
|
case "int_mod":
|
|
update["engineering"] = int(values["engineering"]) + moddiff;
|
|
update["history"] = int(values["history"]) + moddiff;
|
|
update["investigation"] = int(values["investigation"]) + moddiff;
|
|
update["nature"] = int(values["nature"]) + moddiff;
|
|
update["science"] = int(values["science"]) + moddiff;
|
|
update["int_save"] = int(values["int_save"]) + moddiff;
|
|
|
|
setAttrs(update);
|
|
break;
|
|
case "wis_mod":
|
|
update["animalhandling"] = int(values["animalhandling"]) + moddiff;
|
|
update["culture"] = int(values["culture"]) + moddiff;
|
|
update["insight"] = int(values["insight"]) + moddiff;
|
|
update["medicine"] = int(values["medicine"]) + moddiff;
|
|
update["perception"] = int(values["perception"]) + moddiff;
|
|
update["survival"] = int(values["survival"]) + moddiff;
|
|
update["wis_save"] = int(values["wis_save"]) + moddiff;
|
|
|
|
setAttrs(update);
|
|
break;
|
|
case "cha_mod":
|
|
update["deception"] = int(values["deception"]) + moddiff;
|
|
update["intimidation"] = int(values["intimidation"]) + moddiff;
|
|
update["performance"] = int(values["performance"]) + moddiff;
|
|
update["persuasion"] = int(values["persuasion"]) + moddiff;
|
|
update["moxie"] = int(values["moxie"]) + moddiff;
|
|
update["cha_save"] = int(values["cha_save"]) + moddiff;
|
|
|
|
setAttrs(update);
|
|
break;
|
|
default:
|
|
false;
|
|
}
|
|
console.log(update);
|
|
|
|
});
|
|
});
|
|
});
|
|
|
|
</script> |