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

2021 lines
89 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<rolltemplate class="sheet-rolltemplate-attack">
<div class="sheet-swn-template-container">
<div class="sheet-swn sheet-swn-template-title">
<div class="sheet-swn-template-title-character">
{{characterName}}
</div>
<div class="sheet-swn-template-title-action">
{{#name}}
Attack using {{name}}
{{/name}}
{{#attackType}}
{{attackType}} Attack
{{/attackType}}
</div>
</div>
<div class="sheet-swn sheet-swn-template-results-row">
{{#rollGreater() rollValue 19}}
<span class="sheet-swn sheet-results-element sheet-roll-status sheet-success">
Rolls <span class="black-text">{{rollValue}}</span>, Hit!
</span>
{{/rollGreater() rollValue 19}}
{{#rollLess() rollValue 20}}
<span class="sheet-swn sheet-results-element sheet-roll-status sheet-fail">
Rolls <span class="black-text">{{rollValue}}</span>, Miss!
</span>
{{/rollLess() rollValue 20}}
{{#damage}}
{{#rollGreater() rollValue 19}}
<span class="sheet-swn sheet-results-element sheet-roll-output">
<span class="black-text">{{damage}}</span> damage!
</span>
{{/rollGreater() rollValue 19}}
{{#rollLess() rollValue 20}}
<span class="sheet-swn sheet-results-element sheet-roll-output">
Roll damage!
</span>
{{/rollLess() rollValue 20}}
{{/damage}}
</div>
</rolltemplate>
<rolltemplate class="sheet-rolltemplate-save">
<div class="sheet-swn-template-container">
<div class="sheet-swn sheet-swn-template-title">
{{type}} Save
</div>
<div class="sheet-swn sheet-swn-template-results-row">
{{#^rollLess() rollValue save}}
<span class="sheet-swn sheet-results-element sheet-roll-status sheet-success">
Success!
</span>
{{/^rollLess() rollValue save}}
{{#rollLess() rollValue save}}
<span class="sheet-swn sheet-results-element sheet-roll-status sheet-fail">
Fail!
</span>
{{/rollLess() rollValue save}}
<span class="sheet-swn sheet-results-element sheet-roll-output">
{{rollValue}} vs {{save}}
</span>
</div>
</div>
</rolltemplate>
<rolltemplate class="sheet-rolltemplate-morale">
<div class="sheet-swn-template-container">
<div class="sheet-swn sheet-swn-template-title">
{{type}} Morale
</div>
<div class="sheet-swn sheet-swn-template-results-row">
{{#rollLess() rollValue morale}}
<span class="sheet-swn sheet-results-element sheet-roll-status sheet-success">
Success!
</span>
{{/rollLess() rollValue morale}}
{{#rollGreater() rollValue morale}}
<span class="sheet-swn sheet-results-element sheet-roll-status sheet-fail">
Fail!
</span>
{{/rollGreater() rollValue morale}}
<span class="sheet-swn sheet-results-element sheet-roll-output">
{{rollValue}} vs {{morale}}
</span>
</div>
</div>
</rolltemplate>
<rolltemplate class="sheet-rolltemplate-skill">
<div class="sheet-swn-template-container">
<div class="sheet-swn sheet-swn-template-title">
{{type}} Skillcheck
</div>
<div class="sheet-swn sheet-swn-template-results-row">
<span class="sheet-swn sheet-results-element sheet-roll-status sheet-roll-neutral">
Check result:
</span>
<span class="sheet-swn sheet-results-element sheet-roll-output">
{{rollValue}}
</span>
</div>
</div>
</rolltemplate>
<input type="radio" name="attr_tab" class="sheet-tab sheet-tab-character" value="1" title="Character" checked="checked" />
<input type="radio" name="attr_tab" class="sheet-tab sheet-tab-ship" value="2" title="Ship" />
<div class="sheet-tab-content sheet-tab-ship">
<div class="sheet-wrapper">
<div class="sheet-row">
<div class="sheet-col sheet-swn-min"><input type="text" name="attr_sheet_version" class="sheet-version" readonly></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-logo">
<img src="http://i.imgur.com/3U3Ibb7.png" alt="Stars Without Number">
</div>
</div>
<h3>Core Stats</h3>
<div class="sheet-2colrow sheet-stats">
<div class="sheet-col">
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_name">Name</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_name"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_hulltype">Hull Type</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_hulltype"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_speed">Speed</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_speed"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_ac">Armor Class</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_ac"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_armor">Armor</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_armor"></div>
</div>
<div class="sheet-row sheet-stats-ship-min-max">
<div class="sheet-col sheet-stats-label">
<label for="attr_ship_crew_min">Crew Min/Max</label>
</div>
<div class="sheet-col sheet-stats-ship-value">
<input type="text" name="attr_ship_crew_min">
</div>
<div class="sheet-col sheet-stats-label sheet-stats-label-separator">
<label for="attr_ship_crew_max">/</label>
</div>
<div class="sheet-col sheet-stats-ship-value">
<input type="text" name="attr_ship_crew_max">
</div>
</div>
<div class="sheet-row sheet-stats-ship-min-max">
<div class="sheet-col sheet-stats-label">
<label for="attr_ship_hp_min">Hit Points</label>
</div>
<div class="sheet-col sheet-stats-ship-value">
<input type="text" name="attr_ship_hp_min">
</div>
<div class="sheet-col sheet-stats-label sheet-stats-label-separator">
<label for="attr_ship_hp_max">/</label>
</div>
<div class="sheet-col sheet-stats-ship-value">
<input type="text" name="attr_ship_hp_max">
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-row">
<textarea name="attr_ship_notes"></textarea>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-stats">
<div class="sheet-col">
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_free_power">Free Power</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_free_power"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_free_mass">Free Mass</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_free_mass"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_free_hardpoints">Free Hardpoints</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_free_hardpoints"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_cargo_tonnage">Cargo Tonnage</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_cargo_tonnage"></div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_current_crew">Current Crew</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_current_crew"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_operating_cost">Operating Cost</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_operating_cost"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_maintenance_cost">Maintenance Cost</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_maintenance_cost"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_last_maintenance_cost">Last Maintenance Date</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_last_maintenance_cost"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_ship_home_port">Home Port</label></div>
<div class="sheet-col"><input type="text" name="attr_ship_home_port"></div>
</div>
</div>
</div>
<h3>Weapons</h3>
<div class="sheet-col sheet-ship-repeating-headers">
<div class="sheet-ship-weapons sheet-7colrow">
<div class="sheet-col sheet-ship-weapon"><label for="attr_ship_weapon_name">Name</label></div>
<div class="sheet-col sheet-ship-weapon"><label>Power</label></div>
<div class="sheet-col sheet-ship-weapon"><label>Attack Bonus</label></div>
<div class="sheet-col sheet-ship-weapon"><label>Damage</label></div>
<div class="sheet-col sheet-ship-weapon"><label>Ammo</label></div>
<div class="sheet-col sheet-ship-weapon"><label>Special Effects</label></div>
<div class="sheet-col sheet-ship-weapon"><label class="sheet-ship-item-halfsize">Broken?</label></div>
</div>
<fieldset class="repeating_weapons repeating repeating-ship-weapons">
<div class="sheet-ship-weapons sheet-7colrow">
<div class="sheet-col sheet-ship-weapon"><input type="text" name="attr_ship_weapon_name"></div>
<div class="sheet-col sheet-ship-weapon"><input type="number" name="attr_ship_weapon_power"></div>
<div class="sheet-col sheet-ship-weapon"><input class="sheet-ship-item-halfsize" type="number" name="attr_ship_weapon_ab"></div>
<div class="sheet-col sheet-ship-weapon"><input type="text" name="attr_ship_weapon_damage"></div>
<div class="sheet-col sheet-ship-weapon"><input class="sheet-ship-item-halfsize" type="number" min="0" name="attr_ship_weapon_ammo"></div>
<div class="sheet-col sheet-ship-weapon"><input type="text" min="0" name="attr_ship_weapon_special_effects"></div>
<div class="sheet-col sheet-ship-weapon"><input class="sheet-ship-item-halfsize" type="checkbox" min="0" name="attr_ship_weapon_broken"></div>
</div>
</fieldset>
</div>
<h3>Defenses</h3>
<div class="sheet-col sheet-ship-repeating-headers">
<div class="sheet-ship-weapons sheet-3colrow">
<div class="sheet-col sheet-ship-defense"><label>Name</label></div>
<div class="sheet-col sheet-ship-defense"><label>Special Effects</label></div>
<div class="sheet-col sheet-ship-defense"><label class="sheet-ship-item-halfsize">Broken?</label></div>
</div>
<fieldset class="repeating_defenses repeating repeating-ship-defenses">
<div class="sheet-ship-weapons sheet-3colrow">
<div class="sheet-col sheet-ship-defense"><input type="text" name="attr_ship_defense_name"></div>
<div class="sheet-col sheet-ship-defense"><input type="text" name="attr_ship_defense_special_effects"></div>
<div class="sheet-col sheet-ship-defense"><input class="sheet-ship-item-halfsize" type="checkbox" name="attr_ship_defense_broken"></div>
</div>
</fieldset>
</div>
<h3>Fittings</h3>
<div class="sheet-col sheet-ship-repeating-headers">
<div class="sheet-ship-weapons sheet-3colrow">
<div class="sheet-col sheet-ship-fitting"><label>Name</label></div>
<div class="sheet-col sheet-ship-fitting"><label>Special Effects</label></div>
<div class="sheet-col sheet-ship-fitting"><label class="sheet-ship-item-halfsize">Broken?</label></div>
</div>
<fieldset class="repeating_fittings repeating repeating-ship-fittings">
<div class="sheet-ship-weapons sheet-3colrow">
<div class="sheet-col sheet-ship-fitting"><input type="text" name="attr_ship_fitting_name"></div>
<div class="sheet-col sheet-ship-fitting"><input type="text" name="attr_ship_fitting_special_effects"></div>
<div class="sheet-col sheet-ship-fitting"><input class="sheet-ship-item-halfsize" type="checkbox" name="attr_ship_fitting_broken"></div>
</div>
</fieldset>
</div>
<h3>Other Notes</h3>
<div class="sheet-col sheet-ship-other-notes">
<textarea name="attr_ship_other_notes"></textarea>
</div>
</div>
</div>
<div class="sheet-tab-content sheet-tab-character">
<div class="sheet-wrapper">
<div class="sheet-row">
<div class="sheet-col sheet-swn-min"><input type="text" name="attr_sheet_version" class="sheet-version" readonly></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-logo">
<img src="http://i.imgur.com/3U3Ibb7.png" alt="Stars Without Number">
</div>
</div>
<h3>Core Stats</h3>
<div class="sheet-row sheet-stats">
<div class="sheet-col">
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_name">Name</label></div>
<div class="sheet-col"><input type="text" name="attr_name"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_gender">Gender</label></div>
<div class="sheet-col"><input type="text" name="attr_gender"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_class">Class</label></div>
<div class="sheet-col"><input type="text" name="attr_class"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_level">Level</label></div>
<div class="sheet-col"><input type="number" min="1" name="attr_level"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_xp">XP</label></div>
<div class="sheet-col"><input type="number" min="0" name="attr_xp" class="sheet-stats-half"></div>
<div class="sheet-col"><label for="attr_xp_max">Next Level</label></div>
<div class="sheet-col"><input type="number" min="0" name="attr_xp_max" class="sheet-stats-half"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_homeworld">Homeworld</label></div>
<div class="sheet-col"><input type="text" name="attr_homeworld"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_background">Background</label></div>
<div class="sheet-col"><input type="text" name="attr_background"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_training">Training</label></div>
<div class="sheet-col"><input type="text" name="attr_training"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-stats-label"><label for="attr_faction">Faction</label></div>
<div class="sheet-col"><input type="text" name="attr_faction"></div>
</div>
</div>
<div class="sheet-col" class="sheet-col-whitespace">&nbsp;</div>
<div class="sheet-col">
<div class="sheet-row">
<div class="sheet-col sheet-attribute-label"><label for="attr_str">STR</label></div>
<div class="sheet-col">
<input type="number" min="3" name="attr_str" class="sheet-stats-half">
<input type="number" name="attr_strBonus" class="sheet-stats-half sheet-stat-bonus" readonly>
</div>
<div class="sheet-col sheet-attribute-label"><label for="attr_int">INT</label></div>
<div class="sheet-col">
<input type="number" name="attr_int" class="sheet-stats-half">
<input type="number" name="attr_intBonus" class="sheet-stats-half sheet-stat-bonus" readonly>
</div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-attribute-label"><label for="attr_dex">DEX</label></div>
<div class="sheet-col">
<input type="number" name="attr_dex" class="sheet-stats-half">
<input type="number" name="attr_dexBonus" class="sheet-stats-half sheet-stat-bonus" readonly>
</div>
<div class="sheet-col sheet-attribute-label"><label for="attr_wis">WIS</label></div>
<div class="sheet-col">
<input type="number" name="attr_wis" class="sheet-stats-half">
<input type="number" name="attr_wisBonus" class="sheet-stats-half sheet-stat-bonus" readonly>
</div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-attribute-label"><label for="attr_con">CON</label></div>
<div class="sheet-col">
<input type="number" name="attr_con" class="sheet-stats-half">
<input type="number" name="attr_conBonus" class="sheet-stats-half sheet-stat-bonus" readonly>
</div>
<div class="sheet-col sheet-attribute-label"><label for="attr_cha">CHA</label></div>
<div class="sheet-col">
<input type="number" name="attr_cha" class="sheet-stats-half">
<input type="number" name="attr_chaBonus" class="sheet-stats-half sheet-stat-bonus" readonly>
</div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-attribute-ext-label">
<label for="attr_strain">System Strain</label>
</div>
<div class="sheet-col">
<input type="number" name="attr_strain" class="sheet-stats-half">
</div>
<div class="sheet-col sheet-attribute-label">
<label for="attr_strain_max">Max</label>
</div>
<div class="sheet-col">
<input type="number" value="@{Con}" name="attr_strain_max" class="sheet-stats-half">
</div>
<div class="sheet-col sheet-attribute-label">
<label for="attr_strain_perm">Perm</label>
</div>
<div class="sheet-col">
<input type="number" name="attr_strain_perm" class="sheet-stats-half">
</div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-attribute-ext-label"><label for="attr_hp">Hit Points</label></div>
<div class="sheet-col"><input type="number" name="attr_hp" class="sheet-stats-half"></div>
<div class="sheet-col sheet-attribute-ext-label"><label for="attr_strain_max">Max HP</label></div>
<div class="sheet-col"><input type="number" name="attr_hp_max" class="sheet-stats-half"></div>
</div>
<div class="sheet-row">
<div class="sheet-col sheet-attribute-ext-label"><label for="attr_attack_bonus">Attack Bonus</label></div>
<div class="sheet-col"><input type="number" name="attr_attack_bonus" class="sheet-stats-half" value="0"></div>
<div class="sheet-col sheet-attribute-ext-label"><label for="attr_AC">AC</label></div>
<div class="sheet-col"><input type="number" name="attr_AC" class="sheet-stats-half"></div>
</div>
</div>
</div>
<h3>Common Rolls:</h3>
<div class="sheet-5colrow">
<div class="sheet-col">
<label for="roll_initiative">Roll Initiative (Select your token first)</label>
<button type="roll" name="roll_initiative" value="/me rolls initiative: [[1d8+@{dexBonus} &{tracker}]]" ></button>
</div>
<div class="sheet-col">
<label for="roll_basic_melee_attack">Basic Melee Attack Roll</label>
<button type="roll" name="roll_basic_melee_attack" value="&{template:attack} {{characterName=@{name}}} {{attackType=Melee}} {{rollValue=[[1d20 + ?{AC|0} + ?{Combat Skill Bonus|0} + @{strBonus} + @{attack_bonus}]]}}" ></button>
</div>
<div class="sheet-col">
<label for="roll_basic_ranged_attack">Basic Ranged Attack Roll</label>
<button type="roll" name="roll_basic_ranged_attack" value="&{template:attack} {{characterName=@{name}}} {{attackType=Ranged}} {{rollValue=[[1d20 + ?{AC|0} + ?{Combat Skill Bonus|0} + @{dexBonus} + @{attack_bonus}]]}}" ></button>
</div>
</div>
<h3>Saving Throws</h3>
<div class="sheet-5colrow sheet-saves">
<div class="sheet-col">
<label for="attr_save_physical">Physical Save</label>
</div>
<div class="sheet-col">
<label for="attr_save_mental">Mental Save</label>
</div>
<div class="sheet-col">
<label for="attr_save_evasion">Evasion Save</label>
</div>
<div class="sheet-col">
<label for="attr_save_tech">Tech Save</label>
</div>
<div class="sheet-col">
<label for="attr_save_luck">Luck Save</label>
</div>
</div>
<div class="sheet-5colrow sheet-saves">
<div class="sheet-col">
<input type="number" min="0" name="attr_save_physical" class="sheet-stats-save">
<button name="roll_save_physical" type="roll" value="/me &{template:save} {{rollValue=[[1d20]]}} {{save=[[@{save_physical}]]}} {{type=Physical}}"></button>
</div>
<div class="sheet-col">
<input type="number" min="0" name="attr_save_mental" class="sheet-stats-save">
<button name="roll_save_mental" type="roll" value="/me &{template:save} {{rollValue=[[1d20]]}} {{save=[[@{save_mental}]]}} {{type=Mental}}"></button>
</div>
<div class="sheet-col">
<input type="number" min="0" name="attr_save_evasion" class="sheet-stats-save">
<button name="roll_save_evasion" type="roll" value="/me &{template:save} {{rollValue=[[1d20]]}} {{save=[[@{save_evasion}]]}} {{type=Evasion}}"></button>
</div>
<div class="sheet-col">
<input type="number" min="0" name="attr_save_tech" class="sheet-stats-save">
<button name="roll_save_tech" type="roll" value="/me &{template:save} {{rollValue=[[1d20]]}} {{save=[[@{save_tech}]]}} {{type=Tech}}"></button>
</div>
<div class="sheet-col">
<input type="number" min="0" name="attr_save_luck" class="sheet-stats-save">
<button name="roll_save_luck" type="roll" value="/me &{template:save} {{rollValue=[[1d20]]}} {{save=[[@{save_luck}]]}} {{type=Luck}}"></button>
</div>
</div>
<h3>Skills</h3>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_artist">Artist</label>
</div>
<div class="sheet-col">
<input type="number" min="-1" value="-1" name="attr_skill_artist">
<button name="roll_skill_artist" type="roll" value="/me &{template:skill} {{type=Artist}} {{rollValue=[[2d6 + @{skill_artist} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0}]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_navigation">Navigation</label>
</div>
<div class="sheet-col">
<input type="number" min="-1" value="-1" name="attr_skill_navigation">
<button name="roll_skill_navigation" type="roll" value="/me &{template:skill} {{type=Navigation}} {{rollValue=[[ 2d6+@{skill_navigation} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_athletics">Athletics</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_athletics">
<button name="roll_skill_athletics" type="roll" value="/me &{template:skill} {{type=Athletics}} {{rollValue=[[ 2d6+@{skill_athletics} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_perception">Perception</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_perception">
<button name="roll_skill_perception" type="roll" value="/me &{template:skill} {{type=Perception}} {{rollValue=[[ 2d6+@{skill_perception} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_bureaucracy">Bureaucracy</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_bureaucracy">
<button name="roll_skill_bureaucracy" type="roll" value="/me &{template:skill} {{type=Bureaucracy}} {{rollValue=[[ 2d6+@{skill_bureaucracy} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_persuade">Persuade</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_persuade">
<button name="roll_skill_persuade" type="roll" value="/me &{template:skill} {{type=Persuade}} {{rollValue=[[ 2d6+@{skill_persuade} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_business">Business</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_business">
<button name="roll_skill_business" type="roll" value="/me &{template:skill} {{type=Business}} {{rollValue=[[ 2d6+@{skill_business} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_profession">Profession/</label><input type="text" name="attr_profession_type" class="sheet-skills-custom">
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_profession">
<button name="roll_skill_profession" type="roll" value="/me &{template:skill} {{type=Profession}} {{rollValue=[[ 2d6+@{skill_profession} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_combat_energy">Combat/Energy Weapons</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_combat_energy">
<button name="roll_skill_combat_energy" type="roll" value="/me &{template:skill} {{type=Combat_energy}} {{rollValue=[[ 2d6+@{skill_combat_energy} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_religion">Religion</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_religion">
<button name="roll_skill_religion" type="roll" value="/me &{template:skill} {{type=Religion}} {{rollValue=[[ 2d6+@{skill_religion} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_combat_gunnery">Combat/Gunnery</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_combat_gunnery">
<button name="roll_skill_combat_gunnery" type="roll" value="/me &{template:skill} {{type=Combat_gunnery}} {{rollValue=[[ 2d6+@{skill_combat_gunnery} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_science">Science</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_science">
<button name="roll_skill_science" type="roll" value="/me &{template:skill} {{type=Science}} {{rollValue=[[ 2d6+@{skill_science} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_combat_primitive">Combat/Primitive Weapons</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_primitive">
<button name="roll_skill_primitive" type="roll" value="/me &{template:skill} {{type=Primitive}} {{rollValue=[[ 2d6+@{skill_primitive} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_security">Security</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_security">
<button name="roll_skill_security" type="roll" value="/me &{template:skill} {{type=Security}} {{rollValue=[[ 2d6+@{skill_security} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_combat_projectile">Combat/Projectile Weapons</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_projectile">
<button name="roll_skill_projectile" type="roll" value="/me &{template:skill} {{type=Projectile}} {{rollValue=[[ 2d6+@{skill_projectile} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_stealth">Stealth</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_stealth">
<button name="roll_skill_stealth" type="roll" value="/me &{template:skill} {{type=Stealth}} {{rollValue=[[ 2d6+@{skill_stealth} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_combat_psitech">Combat/Psitech</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_psitech">
<button name="roll_skill_psitech" type="roll" value="/me &{template:skill} {{type=Psitech}} {{rollValue=[[ 2d6+@{skill_psitech} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_steward">Steward</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_steward">
<button name="roll_skill_steward" type="roll" value="/me &{template:skill} {{type=Steward}} {{rollValue=[[ 2d6+@{skill_steward} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_combat_unarmed">Combat/Unarmed</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_unarmed">
<button name="roll_skill_unarmed" type="roll" value="/me &{template:skill} {{type=Unarmed}} {{rollValue=[[ 2d6+@{skill_unarmed} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_survival">Survival</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_survival">
<button name="roll_skill_survival" type="roll" value="/me &{template:skill} {{type=Survival}} {{rollValue=[[ 2d6+@{skill_survival} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_computer">Computer</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_computer">
<button name="roll_skill_computer" type="roll" value="/me &{template:skill} {{type=Computer}} {{rollValue=[[ 2d6+@{skill_computer} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_tactics">Tactics</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_tactics">
<button name="roll_skill_tactics" type="roll" value="/me &{template:skill} {{type=Tactics}} {{rollValue=[[ 2d6+@{skill_tactics} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_culture_alien">Culture/Alien/</label><input type="text" name="attr_culture_alien_type" class="sheet-skills-custom">
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_culture_alien">
<button name="roll_skill_culture_alien" type="roll" value="/me &{template:skill} {{type=Culture/Alien}} {{rollValue=[[ 2d6+@{skill_culture_alien} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_tech_astronautic">Tech/Astronautic</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_tech_astronautic">
<button name="roll_skill_tech_astronautic" type="roll" value="/me &{template:skill} {{type=Tech/Astronautic}} {{rollValue=[[ 2d6+@{skill_tech_astronautic} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"> </button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_culture_crivalue="-1" minal">Culture/Criminal</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_culture_criminal">
<button name="roll_skill_culture_criminal" type="roll" value="/me &{template:skill} {{type=Culture/Criminal}} {{rollValue=[[ 2d6+@{skill_culture_criminal} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"> </button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_tech_maltech">Tech/Maltech</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_tech_maltech">
<button name="roll_skill_tech_maltech" type="roll" value="/me &{template:skill} {{type=Tech/Maltech}} {{rollValue=[[ 2d6+@{skill_tech_maltech} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_culture_spacer">Culture/Spacer</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_culture_spacer">
<button name="roll_skill_culture_spacer" type="roll" value="/me &{template:skill} {{type=Culture/Spacer}} {{rollValue=[[ 2d6+@{skill_culture_spacer} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_tech_medical">Tech/Medical</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_tech_medical">
<button name="roll_skill_tech_medical" type="roll" value="/me &{template:skill} {{type=Tech/Medical}} {{rollValue=[[ 2d6+@{skill_tech_medical} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_culture_traveller">Culture/Traveller</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_culture_traveller">
<button name="roll_skill_culture_traveller" type="roll" value="/me &{template:skill} {{type=Culture/Traveller}} {{rollValue=[[ 2d6+@{skill_culture_traveller} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_tech_postech">Tech/Postech</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_tech_postech">
<button name="roll_skill_tech_postech" type="roll" value="/me &{template:skill} {{type=Tech/Postech}} {{rollValue=[[ 2d6+@{skill_tech_postech} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_culture_one">Culture/</label><input type="text" name="attr_skill_culture_one_value" class="sheet-skills-custom">
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_culture_one">
<button name="roll_skill_culture_one" type="roll" value="/me &{template:skill} {{type=Culture}} {{rollValue=[[ 2d6+@{skill_culture_one} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_tech_pretech">Tech/Pretech</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_tech_pretech">
<button name="roll_skill_tech_pretech" type="roll" value="/me &{template:skill} {{type=Tech/Pretech}} {{rollValue=[[ 2d6+@{skill_tech_pretech} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_culture_two">Culture/</label><input type="text" name="attr_skill_culture_two_value" class="sheet-skills-custom">
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_culture_two">
<button name="roll_skill_culture_two" type="roll" value="/me &{template:skill} {{type=Culture}} {{rollValue=[[ 2d6+@{skill_culture_two} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_tech_psitech">Tech/Psitech</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_tech_psitech">
<button name="roll_skill_tech_psitech" type="roll" value="/me &{template:skill} {{type=Tech/Psitech}} {{rollValue=[[ 2d6+@{skill_tech_psitech} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_culture_three">Culture/</label><input type="text" name="attr_skill_culture_three_value" class="sheet-skills-custom">
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_culture_three">
<button name="roll_skill_culture_three" type="roll" value="/me &{template:skill} {{type=Culture}} {{rollValue=[[ 2d6+@{skill_culture_three} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_vehicle_air">Vehicle/Air</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_vehicle_air">
<button name="roll_skill_vehicle_air" type="roll" value="/me &{template:skill} {{type=Vehicle/Air}} {{rollValue=[[ 2d6+@{skill_vehicle_air} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_exosuit">Exosuit</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_exosuit">
<button name="roll_skill_exosuit" type="roll" value="/me &{template:skill} {{type=Exosuit}} {{rollValue=[[ 2d6+@{skill_exosuit} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_vehicle_grav">Vehicle/Grav</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_vehicle_grav">
<button name="roll_skill_vehicle_grav" type="roll" value="/me &{template:skill} {{type=Vehicle_grav}} {{rollValue=[[ 2d6+@{skill_vehicle_grav} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_gambling">Gambling</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_gambling">
<button name="roll_skill_gambling" type="roll" value="/me &{template:skill} {{type=Gambling}} {{rollValue=[[ 2d6+@{skill_gambling} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_vehicle_land">Vehicle/Land</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_vehicle_land">
<button name="roll_skill_vehicle_land" type="roll" value="/me &{template:skill} {{type=Vehicle_land}} {{rollValue=[[ 2d6+@{skill_vehicle_land} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_history">History</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_history">
<button name="roll_skill_history" type="roll" value="/me &{template:skill} {{type=History}} {{rollValue=[[ 2d6+@{skill_history} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_vehicle_space">Vehicle/Space</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_vehicle_space">
<button name="roll_skill_vehicle_space" type="roll" value="/me &{template:skill} {{type=Vehicle_space}} {{rollValue=[[ 2d6+@{skill_vehicle_space} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_instructor">Instructor</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_instructor">
<button name="roll_skill_instructor" type="roll" value="/me &{template:skill} {{type=Instructor}} {{rollValue=[[ 2d6+@{skill_instructor} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_vehicle_water">Vehicle/Water</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_vehicle_water">
<button name="roll_skill_vehicle_water" type="roll" value="/me &{template:skill} {{type=Vehicle_water}} {{rollValue=[[ 2d6+@{skill_vehicle_water} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_language">Language</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_language">
<button name="roll_skill_language" type="roll" value="/me &{template:skill} {{type=Language}} {{rollValue=[[ 2d6+@{skill_language} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
&nbsp;
</div>
<div class="sheet-col">
&nbsp;
</div>
</div>
</div>
</div>
<div class="sheet-2colrow sheet-skills">
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_leadership">Leadership</label>
</div>
<div class="sheet-col">
<input type="number" value="-1" min="-1" name="attr_skill_leadership">
<button name="roll_skill_leadership" type="roll" value="/me &{template:skill} {{type=Leadership}} {{rollValue=[[ 2d6+@{skill_leadership} + ?{Attribute|Str,@{strBonus}|Int,@{intBonus}|Dex,@{dexBonus}|Wis,@{wisBonus}|Con,@{conBonus}|Cha,@{chaBonus}|None,0} + ?{Assisted?|0} ]]}}"></button>
</div>
</div>
</div>
<div class="sheet-col">
<div class="sheet-2colrow">
<div class="sheet-col">
<label for="attr_skill_points" class="sheet-skill-points-unspent">Unspent Skill Points</label>
</div>
<div class="sheet-col">
<input type="number" min="-1" name="attr_skill_points">
</div>
</div>
</div>
</div>
<div class="sheet-row">
Cost to raise by 1: Class Skill = New Level +1, Other = New level + 2
</div>
<h3>Gear</h3>
<div class="sheet-row">
<div class="sheet-col">
<div class="sheet-row sheet-gear-credits">
<div class="sheet-col"><label for="attr_credits">Credits</label></div>
<div class="sheet-col"><input type="number" min="0" name="attr_credits" class="sheet-gear-credits"></div>
<div class="sheet-col"><label for="attr_credits_owed">Credits Owed</label></div>
<div class="sheet-col"><input type="number" min="0" name="attr_credits_owed" class="sheet-gear-credits"></div>
</div>
<div class="sheet-row sheet-gear">
<div class="sheet-col"><label for="attr_gear_readied_current">Current Readied</label></div>
<div class="sheet-col"><input type="number" name="attr_gear_readied_current" value="0" readonly></div>
<div class="sheet-col"><label for="attr_gear_readied_max">Max Readied</label></div>
<div class="sheet-col"><input type="number" name="attr_gear_readied_max"></div>
<div class="sheet-col"><label for="attr_gear_stowed_current">Current Stowed</label></div>
<div class="sheet-col"><input type="number" name="attr_gear_stowed_current" value="0" readonly></div>
<div class="sheet-col"><label for="attr_gear_stowed_max">Max Stowed</label></div>
<div class="sheet-col"><input type="number" name="attr_gear_stowed_max"></div>
</div>
<div class="sheet-row sheet-gear" style="border-bottom: 1px solid black;">
<div class="sheet-col" style="width: 210px;"><label for="attr_gear_readied_current">Item(s)</label></div>
<div class="sheet-col" style="width: 150px"><label for="attr_gear_readied_max">Encumbrance</label></div>
<div class="sheet-col"><label for="attr_gear_stowed_current">Status</label></div>
</div>
<fieldset class="repeating_gear">
<div class="sheet-row sheet-gear">
<div class="sheet-col" style="width: 210px"><input type="text" name="attr_gear_name" placeholder="Item"></div>
<div class="sheet-col" style="width: 150px"><input type="number" min="0" name="attr_gear_encumbrance"></div>
<div class="sheet-col">
Readied <input type="radio" name="attr_gear_readied" value="1">
Stowed <input type="radio" name="attr_gear_readied" value="2">
Other <input type="radio" name="attr_gear_readied" value="0" checked>
</div>
</div>
</fieldset>
<div class="sheet-row sheet-gear">
<div class="sheet-col"><label>Cyberware</label></div>
</div>
<div class="sheet-row sheet-gear-cyberware">
<div class="sheet-col"><input type="text" name="attr_cyberware_1"></div>
</div>
<div class="sheet-row sheet-gear-cyberware">
<div class="sheet-col"><input type="text" name="attr_cyberware_2"></div>
</div>
<div class="sheet-row sheet-gear-cyberware">
<div class="sheet-col"><input type="text" name="attr_cyberware_3"></div>
</div>
<div class="sheet-row sheet-gear-cyberware">
<div class="sheet-col"><input type="text" name="attr_cyberware_4"></div>
</div>
<div class="sheet-row sheet-gear">
<div class="sheet-col"><label>Other Equipment</label></div>
</div>
<div class="sheet-row sheet-gear-other">
<textarea name="attr_gear_other"></textarea>
</div>
</div>
</div>
<div class="sheet-weapons-wrapper">
<label>Weapon</label>
<label class="sheet-weapons-short">Weapon AB</label>
<label class="sheet-weapons-short">Skill</label>
<label class="sheet-weapons-short">Attribute</label>
<label class="sheet-weapons-short">Damage</label>
<label>Range</label>
<label class="sheet-weapons-short">Ammo</label>
<br>
<fieldset class="repeating_weapons">
<input type="text" name="attr_weapon_name" style="width: 140px">
<input type="number" name="attr_weapon_attack" value="0" style="width: 95px">
<select class="inputbox" name="attr_weapon_skill_bonus" style="width: 95px; height: 25px">
<option value="@{skill_combat_energy}">Energy</option>
<option value="@{skill_combat_gunnery}">Gunnery</option>
<option value="@{skill_primitive}">Primitive</option>
<option value="@{skill_projectile}">Projectile</option>
<option value="@{skill_psitech}">Psitech</option>
<option value="@{skill_unarmed}">Unarmed</option>
</select>
<select class="inputbox" name="attr_attribute_mod" style="width: 95px; height: 25px">
<option value="@{strBonus}">STR</option>
<option value="@{dexBonus}">DEX</option>
<option value="@{conBonus}">CON</option>
<option value="@{intBonus}">INT</option>
<option value="@{wisBonus}">WIS</option>
<option value="@{chaBonus}">CHA</option>
</select>
<input type="text" name="attr_weapon_damage" style="width: 95px">
<input type="text" name="attr_weapon_range" style="width: 140px">
<input type="number" name="attr_weapon_ammo" style="width: 95px">
<button type="roll" name="roll_weapon_to_hit" value="/me &{template:attack} {{name=@{weapon_name}}} {{rollValue=[[1d20 + ?{AC|0}[AC] + @{attack_bonus}[AB] + @{weapon_attack}[Weapon AB] + @{weapon_skill_bonus}[Skill] + @{attribute_mod}[Attribute] + ?{Other Modifier|0}[Modifier]]]}} {{damage=[[@{weapon_damage} + @{attribute_mod}]]}}" ></button>
</fieldset>
</div>
<h3>Psionics</h3>
<div class="sheet-2colrow">
<div class="sheet-col">
<div class="sheet-row sheet-psionics-discipline"><label>Psionic Disciplines</label></div>
</div>
<div class="sheet-col">
<div class="sheet-row sheet-psionics-level"><label>Level</label></div>
</div>
</div>
<div class="sheet-2colrow">
<div class="sheet-col">
<div class="sheet-row sheet-psionics-discipline"><input type="text" name="attr_psionics_discipline_1"></div>
</div>
<div class="sheet-col">
<div class="sheet-row sheet-psionics-level"><input type="number" min="0" name="attr_psionics_level_1"></div>
</div>
</div>
<div class="sheet-2colrow">
<div class="sheet-col">
<div class="sheet-row sheet-psionics-discipline"><input type="text" name="attr_psionics_discipline_2"></div>
</div>
<div class="sheet-col">
<div class="sheet-row sheet-psionics-level"><input type="number" min="0" name="attr_psionics_level_2"></div>
</div>
</div>
<div class="sheet-2colrow">
<div class="sheet-col">
<div class="sheet-row sheet-psionics-discipline"><input type="text" name="attr_psionics_discipline_3"></div>
</div>
<div class="sheet-col">
<div class="sheet-row sheet-psionics-level"><input type="number" min="0" name="attr_psionics_level_3"></div>
</div>
</div>
<div class="sheet-2colrow">
<div class="sheet-col">
<div class="sheet-row sheet-psionics-discipline"><input type="text" name="attr_psionics_discipline_4"></div>
</div>
<div class="sheet-col">
<div class="sheet-row sheet-psionics-level"><input type="number" min="0" name="attr_psionics_level_4"></div>
</div>
</div>
<div class="sheet-2colrow">
<div class="sheet-col">
<div class="sheet-row sheet-psionics-discipline"><input type="text" name="attr_psionics_discipline_5"></div>
</div>
<div class="sheet-col">
<div class="sheet-row sheet-psionics-level"><input type="number" min="0" name="attr_psionics_level_5"></div>
</div>
</div>
<div class="sheet-2colrow">
<div class="sheet-col">
<div class="sheet-row sheet-psionics-discipline"><input type="text" name="attr_psionics_discipline_6"></div>
</div>
<div class="sheet-col">
<div class="sheet-row sheet-psionics-level"><input type="number" min="0" name="attr_psionics_level_6"></div>
</div>
</div>
<br>
<div class="sheet-2colrow">
<div class="sheet-col">
<div class="sheet-row sheet-psionics-power"><label>Psionic Powers Mastered</label></div>
</div>
<div class="sheet-col">
<div class="sheet-4colrow sheet-psionics-pp">
<div class="sheet-col"><label>PP</label></div>
<div class="sheet-col"><input type="number" min="0" name="attr_psionics_pp"></div>
<div class="sheet-col"><label>Max PP</label></div>
<div class="sheet-col"><input type="number" min="0" name="attr_psionics_pp_max"></div>
</div>
</div>
</div>
<div class="sheet-colrow">
<div class="sheet-col">
<div class="sheet-row sheet-psionics-mastered"><input type="text" name="attr_psionics_mastered_1"></div>
<div class="sheet-row sheet-psionics-mastered"><input type="text" name="attr_psionics_mastered_2"></div>
<div class="sheet-row sheet-psionics-mastered"><input type="text" name="attr_psionics_mastered_3"></div>
<div class="sheet-row sheet-psionics-mastered"><input type="text" name="attr_psionics_mastered_4"></div>
</div>
<div class="sheet-col">
<div class="sheet-row sheet-psionics-mastered"><input type="text" name="attr_psionics_mastered_5"></div>
<div class="sheet-row sheet-psionics-mastered"><input type="text" name="attr_psionics_mastered_6"></div>
<div class="sheet-row sheet-psionics-mastered"><input type="text" name="attr_psionics_mastered_7"></div>
<div class="sheet-row sheet-psionics-mastered"><input type="text" name="attr_psionics_mastered_8"></div>
</div>
</div>
<h3>Miscellaneous</h3>
<div class="sheet-2colrow">
<div class="sheet-col">
<div class="sheet-row sheet-misc-goal"><label>Current Goals</label></div>
</div>
<div class="sheet-col">
<div class="sheet-row sheet-misc-goal-xp"><label>XP</label></div>
</div>
</div>
<fieldset class="repeating_goals">
<div class="sheet-2colrow">
<div class="sheet-col">
<div class="sheet-row sheet-misc-goal"><input type="text" name="attr_misc_goal"></div>
</div>
<div class="sheet-col">
<div class="sheet-row sheet-misc-goal-xp"><input type="number" min="0" name="attr_misc_goal_xp"></div>
</div>
</div>
</fieldset>
<div class="sheet-row">
<label for="attr_languages" class="sheet-languages">Languages</label>
</div>
<div class="sheet-row">
<textarea name="attr_languages" class="sheet-textarea-wide"></textarea>
</div>
<div class="sheet-row">
<label for="attr_notes">Notes</label>
</div>
<div class="sheet-row">
<textarea name="attr_notes" class="sheet-textarea-wide"></textarea>
</div>
</div>
</div>
<script type="text/worker">
/* ---- BEGIN: TheAaronSheet.js ---- */
// Github: https://github.com/shdwjk/TheAaronSheet/blob/master/TheAaronSheet.js
// By: The Aaron, Arcane Scriptomancer
// Contact: https://app.roll20.net/users/104025/the-aaron
var TAS = TAS || (function(){
'use strict';
var version = '0.2.4',
lastUpdate = 1457098091,
loggingSettings = {
debug: {
key: 'debug',
title: 'DEBUG',
color: {
bgLabel: '#7732A2',
label: '#F2EF40',
bgText: '#FFFEB7',
text: '#7732A2'
}
},
error: {
key: 'error',
title: 'Error',
color: {
bgLabel: '#C11713',
label: 'white',
bgText: '#C11713',
text: 'white'
}
},
warn: {
key: 'warn',
title: 'Warning',
color: {
bgLabel: '#F29140',
label: 'white',
bgText: '#FFD8B7',
text: 'black'
}
},
info: {
key: 'info',
title: 'Info',
color: {
bgLabel: '#413FA9',
label: 'white',
bgText: '#B3B2EB',
text: 'black'
}
},
notice: {
key: 'notice',
title: 'Notice',
color: {
bgLabel: '#33C133',
label: 'white',
bgText: '#ADF1AD',
text: 'black'
}
},
log: {
key: 'log',
title: 'Log',
color: {
bgLabel: '#f2f240',
label: 'black',
bgText: '#ffff90',
text: 'black'
}
},
callstack: {
key: 'TAS',
title: 'function',
color: {
bgLabel: '#413FA9',
label: 'white',
bgText: '#B3B2EB',
text: 'black'
}
},
callstack_async: {
key: 'TAS',
title: 'ASYNC CALL',
color: {
bgLabel: '#413FA9',
label: 'white',
bgText: '#413FA9',
text: 'white'
}
},
TAS: {
key: 'TAS',
title: 'TAS',
color: {
bgLabel: 'grey',
label: 'black;background:linear-gradient(#304352,#d7d2cc,#d7d2cc,#d7d2cc,#304352)',
bgText: 'grey',
text: 'black;background:linear-gradient(#304352,#d7d2cc,#d7d2cc,#d7d2cc,#304352)'
}
}
},
config = {
debugMode: false,
logging: {
log: true,
notice: true,
info: true,
warn: true,
error: true,
debug: false
}
},
callstackRegistry = [],
queuedUpdates = {}, //< Used for delaying saves till the last momment.
complexType = function(o){
switch(typeof o){
case 'string':
return 'string';
case 'boolean':
return 'boolean';
case 'number':
return (_.isNaN(o) ? 'NaN' : (o.toString().match(/\./) ? 'decimal' : 'integer'));
case 'function':
return 'function: '+(o.name ? o.name+'()' : '(anonymous)');
case 'object':
return (_.isArray(o) ? 'array' : (_.isArguments(o) ? 'arguments' : ( _.isNull(o) ? 'null' : 'object')));
default:
return typeof o;
}
},
dataLogger = function(primaryLogger,secondaryLogger,data){
_.each(data,function(m){
var type = complexType(m);
switch(type){
case 'string':
primaryLogger(m);
break;
case 'undefined':
case 'null':
case 'NaN':
primaryLogger('['+type+']');
break;
case 'number':
case 'not a number':
case 'integer':
case 'decimal':
case 'boolean':
primaryLogger('['+type+']: '+m);
break;
default:
primaryLogger('['+type+']:=========================================');
secondaryLogger(m);
primaryLogger('=========================================================');
break;
}
});
},
colorLog = function(options){
var coloredLoggerFunction,
key = options.key,
label = options.title || 'TAS',
lBGColor = (options.color && options.color.bgLabel) || 'blue',
lTxtColor = (options.color && options.color.label) || 'white',
mBGColor = (options.color && options.color.bgText) || 'blue',
mTxtColor = (options.color && options.color.text) || 'white';
coloredLoggerFunction = function(message){
console.log(
'%c '+label+': %c '+message + ' ',
'background-color: '+lBGColor+';color: '+lTxtColor+'; font-weight:bold;',
'background-color: '+mBGColor+';color: '+mTxtColor+';'
);
};
return function(){
if('TAS'===key || config.logging[key]){
dataLogger(coloredLoggerFunction,function(m){console.log(m);},_.toArray(arguments));
}
};
},
logDebug = colorLog(loggingSettings.debug),
logError = colorLog(loggingSettings.error),
logWarn = colorLog(loggingSettings.warn),
logInfo = colorLog(loggingSettings.info),
logNotice = colorLog(loggingSettings.notice),
logLog = colorLog(loggingSettings.log),
log = colorLog(loggingSettings.TAS),
logCS = colorLog(loggingSettings.callstack),
logCSA = colorLog(loggingSettings.callstack_async),
registerCallstack = function(callstack,label){
var idx=_.findIndex(callstackRegistry,function(o){
return (_.difference(o.stack,callstack).length === _.difference(callstack,o.stack).length) &&
_.difference(o.stack,callstack).length === 0 &&
o.label === label;
});
if(-1 === idx){
idx=callstackRegistry.length;
callstackRegistry.push({
stack: callstack,
label: label
});
}
return idx;
},
setConfigOption = function(options){
var newconf =_.defaults(options,config);
newconf.logging=_.defaults(
(options && options.logging)||{},
config.logging
);
config=newconf;
},
debugMode = function(){
config.logging.debug=true;
config.debugMode = true;
},
getCallstack = function(){
var e = new Error('dummy'),
stack = _.map(_.rest(e.stack.replace(/^[^\(]+?[\n$]/gm, '')
.replace(/^\s+at\s+/gm, '')
.replace(/^Object.<anonymous>\s*\(/gm, '{anonymous}()@')
.split('\n')),function(l){
return l.replace(/\s+.*$/,'');
});
return stack;
},
logCallstackSub = function(cs){
var matches, csa;
_.find(cs,function(line){
matches = line.match(/TAS_CALLSTACK_(\d+)/);
if(matches){
csa=callstackRegistry[matches[1]];
logCSA( '===================='+(csa.label ? '> '+csa.label+' <' : '')+'====================');
logCallstackSub(csa.stack);
return true;
}
logCS(line);
return false;
});
},
logCallstack = function(){
var cs;
if(config.debugMode){
cs = getCallstack();
cs.shift();
log('==============================> CALLSTACK <==============================');
logCallstackSub(cs);
log('=========================================================================');
}
},
wrapCallback = function (label, callback, context){
var callstack;
if('function' === typeof label){
context=callback;
callback=label;
label=undefined;
}
if(!config.debugMode){
return (function(cb,ctx){
return function(){
cb.apply(ctx||{},arguments);
};
}(callback,context));
}
callstack = getCallstack();
callstack.shift();
return (function(cb,ctx,cs,lbl){
var ctxref=registerCallstack(cs,lbl);
/*jshint -W054 */
return new Function('cb','ctx','TASlog',
"return function TAS_CALLSTACK_"+ctxref+"(){"+
"TASlog('Entering: '+(cb.name||'(anonymous function)'));"+
"cb.apply(ctx||{},arguments);"+
"TASlog('Exiting: '+(cb.name||'(anonymous function)'));"+
"};")(cb,ctx,log);
/*jshint +W054 */
}(callback,context,callstack,label));
},
prepareUpdate = function( attribute, value ){
queuedUpdates[attribute]=value;
},
applyQueuedUpdates = function() {
setAttrs(queuedUpdates);
queuedUpdates = {};
},
namesFromArgs = function(args,base){
return _.chain(args)
.reduce(function(memo,attr){
if('string' === typeof attr) {
memo.push(attr);
} else if(_.isArray(args) || _.isArguments(args)){
memo = namesFromArgs(attr,memo);
}
return memo;
},(_.isArray(base) && base) || [])
.uniq()
.value();
},
addId = function(obj,value){
Object.defineProperty(obj,'id',{
value: value,
writeable: false,
enumerable: false
});
},
addProp = function(obj,prop,value,fullname){
(function(){
var pname=(_.contains(['S','F','I','D'],prop) ? '_'+prop : prop),
full_pname = fullname || prop,
pvalue=value;
_.each(['S','I','F'],function(p){
if( !_.has(obj,p)){
Object.defineProperty(obj, p, {
value: {},
enumerable: false,
readonly: true
});
}
});
if( !_.has(obj,'D')){
Object.defineProperty(obj, 'D', {
value: _.reduce(_.range(10),function(m,d){
Object.defineProperty(m, d, {
value: {},
enumerable: true,
readonly: true
});
return m;
},{}),
enumerable: false,
readonly: true
});
}
// Raw value
Object.defineProperty(obj, pname, {
enumerable: true,
set: function(v){
if(v!==pvalue) {
pvalue=v;
prepareUpdate(full_pname,v);
}
},
get: function(){
return pvalue;
}
});
// string value
Object.defineProperty(obj.S, pname, {
enumerable: true,
set: function(v){
var val=v.toString();
if(val !== pvalue) {
pvalue=val;
prepareUpdate(full_pname,val);
}
},
get: function(){
return pvalue.toString();
}
});
// int value
Object.defineProperty(obj.I, pname, {
enumerable: true,
set: function(v){
var val=parseInt(v,10) || 0;
if(val !== pvalue){
pvalue=val;
prepareUpdate(full_pname,val);
}
},
get: function(){
return parseInt(pvalue,10) || 0;
}
});
// float value
Object.defineProperty(obj.F, pname, {
enumerable: true,
set: function(v){
var val=parseFloat(v) || 0;
if(val !== pvalue) {
pvalue=val;
prepareUpdate(full_pname,val);
}
},
get: function(){
return parseFloat(pvalue) || 0;
}
});
_.each(_.range(10),function(d){
Object.defineProperty(obj.D[d], pname, {
enumerable: true,
set: function(v){
var val=(parseFloat(v) || 0).toFixed(d);
if(val !== pvalue){
pvalue=val;
prepareUpdate(full_pname,val);
}
},
get: function(){
return (parseFloat(pvalue) || 0).toFixed(d);
}
});
});
}());
},
repeating = function( section ) {
return (function(s){
var sectionName = s,
attrNames = [],
fieldNames = [],
operations = [],
after = [],
repAttrs = function TAS_Repeating_Attrs(){
attrNames = namesFromArgs(arguments,attrNames);
return this;
},
repFields = function TAS_Repeating_Fields(){
fieldNames = namesFromArgs(arguments,fieldNames);
return this;
},
repReduce = function TAS_Repeating_Reduce(func, initial, final, context) {
operations.push({
type: 'reduce',
func: (func && _.isFunction(func) && func) || _.noop,
memo: (_.isUndefined(initial) && 0) || initial,
final: (final && _.isFunction(final) && final) || _.noop,
context: context || {}
});
return this;
},
repMap = function TAS_Repeating_Map(func, final, context) {
operations.push({
type: 'map',
func: (func && _.isFunction(func) && func) || _.noop,
final: (final && _.isFunction(final) && final) || _.noop,
context: context || {}
});
return this;
},
repEach = function TAS_Repeating_Each(func, final, context) {
operations.push({
type: 'each',
func: (func && _.isFunction(func) && func) || _.noop,
final: (final && _.isFunction(final) && final) || _.noop,
context: context || {}
});
return this;
},
repTap = function TAS_Repeating_Tap(final, context) {
operations.push({
type: 'tap',
final: (final && _.isFunction(final) && final) || _.noop,
context: context || {}
});
return this;
},
repAfter = function TAS_Repeating_After(callback,context) {
after.push({
callback: (callback && _.isFunction(callback) && callback) || _.noop,
context: context || {}
});
return this;
},
repExecute = function TAS_Repeating_Execute(callback,context){
var rowSet = {},
attrSet = {},
fieldIds = [],
fullFieldNames = [];
repAfter(callback,context);
// call each operation per row.
// call each operation's final
getSectionIDs("repeating_"+sectionName,function(ids){
fieldIds = ids;
fullFieldNames = _.reduce(fieldIds,function(memo,id){
return memo.concat(_.map(fieldNames,function(name){
return 'repeating_'+sectionName+'_'+id+'_'+name;
}));
},[]);
getAttrs( _.uniq(attrNames.concat(fullFieldNames)), function(values){
_.each(attrNames,function(aname){
if(values.hasOwnProperty(aname)){
addProp(attrSet,aname,values[aname]);
}
});
rowSet = _.reduce(fieldIds,function(memo,id){
var r={};
addId(r,id);
_.each(fieldNames,function(name){
var fn = 'repeating_'+sectionName+'_'+id+'_'+name;
addProp(r,name,values[fn],fn);
});
memo[id]=r;
return memo;
},{});
_.each(operations,function(op){
var res;
switch(op.type){
case 'tap':
_.bind(op.final,op.context,rowSet,attrSet)();
break;
case 'each':
_.each(rowSet,function(r){
_.bind(op.func,op.context,r,attrSet,r.id,rowSet)();
});
_.bind(op.final,op.context,rowSet,attrSet)();
break;
case 'map':
res = _.map(rowSet,function(r){
return _.bind(op.func,op.context,r,attrSet,r.id,rowSet)();
});
_.bind(op.final,op.context,res,rowSet,attrSet)();
break;
case 'reduce':
res = op.memo;
_.each(rowSet,function(r){
res = _.bind(op.func,op.context,res,r,attrSet,r.id,rowSet)();
});
_.bind(op.final,op.context,res,rowSet,attrSet)();
break;
}
});
// finalize attrs
applyQueuedUpdates();
_.each(after,function(op){
_.bind(op.callback,op.context)();
});
});
});
};
return {
attrs: repAttrs,
attr: repAttrs,
column: repFields,
columns: repFields,
field: repFields,
fields: repFields,
reduce: repReduce,
inject: repReduce,
foldl: repReduce,
map: repMap,
collect: repMap,
each: repEach,
forEach: repEach,
tap: repTap,
'do': repTap,
after: repAfter,
last: repAfter,
done: repAfter,
execute: repExecute,
go: repExecute,
run: repExecute
};
}(section));
},
repeatingSimpleSum = function(section, field, destination){
repeating(section)
.attr(destination)
.field(field)
.reduce(function(m,r){
return m + (r.F[field]);
},0,function(t,r,a){
a.S[destination]=t;
})
.execute();
};
console.log('%c•.¸¸.•*´¨`*•.¸¸.•*´¨`*•.¸ The Aaron Sheet v'+version+' ¸.•*´¨`*•.¸¸.•*´¨`*•.¸¸.•','background: linear-gradient(to right,green,white,white,green); color:black;text-shadow: 0 0 8px white;');
console.log('%c•.¸¸.•*´¨`*•.¸¸.•*´¨`*•.¸ Last update: '+(new Date(lastUpdate*1000))+' ¸.•*´¨`*•.¸¸.•*´¨`*•.¸¸.•','background: linear-gradient(to right,green,white,white,green); color:black;text-shadow: 0 0 8px white;');
return {
/* Repeating Sections */
repeatingSimpleSum: repeatingSimpleSum,
repeating: repeating,
/* Configuration */
config: setConfigOption,
/* Debugging */
callback: wrapCallback,
callstack: logCallstack,
debugMode: debugMode,
_fn: wrapCallback,
/* Logging */
debug: logDebug,
error: logError,
warn: logWarn,
info: logInfo,
notice: logNotice,
log: logLog
};
}());
/* ---- END: TheAaronSheet.js ---- */
on("sheet:opened", function() {
setVersion('0.1.4');
validateAttrMods();
validateStrain();
validateGear();
});
on("change:str change:int change:dex change:wis change:con change:cha", function(e) {
var attr = e.sourceAttribute;
calculateMod([attr]);
});
on("change:strain", function() {
validateStrain();
});
on("change:strain_perm", function() {
validateStrain();
});
on("change:strain_max", function() {
validateStrain();
});
on("change:gear_readied_max", function() {
validateReadiedMax();
});
on("change:repeating_gear", function() {
getAttrs(["gear_readied_current","gear_stowed_current"], function(v) {
setAttrs({gear_readied_current: parseInt(0)});
setAttrs({gear_stowed_current: parseInt(0)});
});
TAS.repeating("gear")
.attrs("gear_readied_current", "gear_stowed_current")
.fields("gear_encumbrance", "gear_readied")
.map(function(row, attrSet, id, rowSet) {
if (parseInt(row.gear_readied) === 1) {
attrSet.gear_readied_current += parseInt(row.gear_encumbrance);
} else if (parseInt(row.gear_readied) === 2){
attrSet.gear_stowed_current += parseInt(row.gear_encumbrance);
}
})
.execute();
});
calculateMod = function(attributes) {
attributes.map(function(attr) {
getAttrs([attr], function(v) {
var attrModName = attr + 'Bonus';
var updatedVal = {};
if (v[attr] >= 18) {
updatedVal[attrModName] = 2;
} else if (v[attr] >= 14 && v[attr] <= 17) {
updatedVal[attrModName] = 1;
} else if (v[attr] >= 4 && v[attr] <= 7) {
updatedVal[attrModName] = -1;
} else if (v[attr] <= 3) {
updatedVal[attrModName] = -2;
} else {
updatedVal[attrModName] = 0
}
setAttrs(updatedVal);
});
});
}
setVersion = function(version) {
getAttrs(["sheet_version"], function(){
setAttrs({sheet_version: 'Version '+version});
})
}
validateAttrMods = function() {
calculateMod(['str', 'int', 'dex', 'wis', 'con', 'cha']);
}
validateStrain = function() {
getAttrs(["strain", "strain_perm", "strain_max"], function(v) {
if (!v.strain || (!v.strain_perm && !v.strain_max)) return false;
v.strain = +v.strain;
if (v.strain_perm) v.strain_perm = +v.strain_perm;
if (v.strain_max) v.strain_max = +v.strain_max;
if (v.strain_perm && v.strain < v.strain_perm) {
setAttrs({strain: v.strain_perm});
} else if (v.strain_max && v.strain > v.strain_max) {
setAttrs({strain: v.strain_max});
}
});
}
validateGear = function() {
validateReadiedMax();
validateStowedMax();
}
validateReadiedMax = function() {
getAttrs(["str","gear_readied_max"], function(v) {
if (!v.str) return false;
v.str = +v.str;
if (v.gear_readied_max) v.gear_readied_max = +v.gear_readied_max;
readied_max = Math.floor(v.str / 2);
if (readied_max === v.gear_readied_max) return false;
setAttrs({gear_readied_max: readied_max});
});
}
validateStowedMax = function() {
getAttrs(["str","gear_stowed_max"], function(v) {
if (!v.str) return false;
v.str = +v.str;
if (v.gear_stowed_max) v.gear_stowed_max = +v.gear_stowed_max;
stowed_max = v.str;
if (stowed_max === v.gear_stowed_max) return false;
setAttrs({gear_stowed_max: stowed_max});
});
}
</script>