Obsidian Portal
Menu
Sign In / Create Account
JavaScript is currently disabled. Obsidian Portal has a lot of really cool features that use JavaScript. You should check them out. We think you'll have a much more enjoyable experience.
Home
Campaigns
Games Nearby
Plans
Community
Help
Resources
Star Wars : L’Ère de la Rébellion
Author:
Edhilion
Slug:
sw_edlr
Type:
GameCharacter
System:
Star Wars: Age of Rebellion
DST Source Code
HTML Template
<!-- Star Wars: L'Ere de la Rébellion, Dynamic Style Sheet --> <div class="wrapper base"> <!-- Start --> <div class="tab_bar"> <img alt="BIO" src="https://chainsawxiv.github.io/DST/common/images/fluff.png" class="tab bio_tab" onclick="sw_edlr_tabClick(this,'bio');"/> <img alt="STATS" src="https://chainsawxiv.github.io/DST/common/images/equipment.png" class="tab stats_tab" onclick="sw_edlr_tabClick(this,'sheet');"/> </div> <div class="pagehead"> <div class="line"> <ul> <li> <span>NOM DU PERSONNAGE</span> <span class="dsf dsf_name user_input"></span> </li> <li> <span>JOUEUR/JOUEUSE</span> <span class="dsf dsf_player user_input"></span> </li> </ul> </div> <div class="line"> <ul> <li> <span>ESPÈCE</span> <span class="dsf dsf_species user_input"></span> </li> <li> <span>CARRIÈRE</span> <span class="dsf dsf_career user_input"></span> </li> </ul> </div> <div class="line"> <ul> <li class="span_all"> <span>SPÉCIALITÉS</span> <span class="dsf dsf_specializations user_input"></span> </li> </ul> </div> </div> <div class="main page_sheet" style="display:block;"> <div class="strike"> <div><div class="section_title">ATTRIBUTS</div></div> </div> <div class="attributes"> <!-- VALEUR D’ENCAISSEMENT --> <div class="attribute_box"> <div class="attribute_box_shadow"></div> <div class="type"> <div class="text"> VALEUR D'ENCAISSEMENT </div> </div> <div class="attribute"> <div class="text"> <span class="dsf dsf_soak_w user_input"></span> </div> </div> </div> <!-- BLESSURES --> <div class="attribute_box"> <div class="attribute_box_shadow"></div> <div class="type"> <div class="text"> BLESSURES </div> </div> <div class="attribute"> <div class="text"> <ul> <li><span class="dsf dsf_wound user_input"></span></li> <li class="divider"></li> <li><span class="dsf dsf_wound_current user_input"></span></li> </ul> </div> </div> <div class="split_box"> <div>SEUIL</div> <div>ACTUELLES</div> </div> </div> <!-- Strain --> <div class="attribute_box"> <div class="attribute_box_shadow"></div> <div class="type"> <div class="text"> STRESS </div> </div> <div class="attribute"> <div class="text"> <ul> <li><span class="dsf dsf_strain user_input"></span></li> <li class="divider"></li> <li><span class="dsf dsf_strain_current user_input"></span></li> </ul> </div> </div> <div class="split_box"> <div>SEUIL</div> <div>ACTUEL</div> </div> </div> <!-- Defense --> <div class="attribute_box"> <div class="attribute_box_shadow"></div> <div class="type"> <div class="text"> DÉFENSE </div> </div> <div class="attribute"> <div class="text"> <ul> <li><span class="dsf dsf_ranged_def user_input"></span></li> <li class="divider"></li> <li><span class="dsf dsf_melee_def user_input"></span></li> </ul> </div> </div> <div class="split_box"> <div>DISTANCE</div> <div>CORPS À CORPS</div> </div> </div> <span class="stretch"></span> </div> <div class="strike"> <div><div class="section_title">CARACTÉRISTIQUES</div></div> </div> <div class="stats"> <div class="stat_block" key="BR"> <div class="stat"> <div class="stat_background"></div> <div class="text"> <!-- Value --> <span class="dsf dsf_brawn user_input"></span> </div> </div> <div class='type'> <div class='text'> <!-- Description --> VIGUEUR </div> </div> </div> <div class="stat_block" key="AG"> <div class="stat"> <div class="stat_background"></div> <div class="text"> <!-- Value --> <span class="dsf dsf_aglity user_input"></span> </div> </div> <div class='type'> <div class='text'> <!-- Description --> AGILITÉ </div> </div> </div> <div class="stat_block" key="INT"> <div class="stat"> <div class="stat_background"></div> <div class="text"> <!-- Value --> <span class="dsf dsf_intellect user_input"></span> </div> </div> <div class='type'> <div class='text'> <!-- Description --> INTELLIGENCE </div> </div> </div> <div class="stat_block" key="CUN"> <div class="stat"> <div class="stat_background"></div> <div class="text"> <!-- Value --> <span class="dsf dsf_cunning user_input"></span> </div> </div> <div class='type'> <div class='text'> <!-- Description --> RUSE </div> </div> </div> <div class="stat_block" key="WIL"> <div class="stat"> <div class="stat_background"></div> <div class="text"> <!-- Value --> <span class="dsf dsf_willpower user_input"></span> </div> </div> <div class='type'> <div class='text'> <!-- Description --> VOLONTÉ </div> </div> </div> <div class="stat_block" key="PR"> <div class="stat"> <div class="stat_background"></div> <div class="text"> <!-- Value --> <span class="dsf dsf_presence user_input"></span> </div> </div> <div class='type'> <div class='text'> <!-- Description --> PRÉSENCE </div> </div> </div> <span class="stretch"></span> </div> <div class="strike"> <div><div class="section_title">COMPÉTENCES</div></div> </div> <div class="section"> <div class="half_sheet_column"> <div class="skills_headers type"> <div class="tr"> <div class="td"> <span>COMP. GÉNÉRALES</span> </div> <div class="td"> <span>CARRIÈRE</span> </div> <div class="td"> <span>RANG</span> </div> <div class="td"> <span></span> </div> </div> </div> <div class="skills"> <div class="table genskill skilltable"> </div> </div> </div> <div class="half_sheet_column"> <div class="skills_headers type"> <div class="tr"> <div class="td"> <span>COMP. DE COMBAT</span> </div> <div class="td"> <span>CARRIÈRE</span> </div> <div class="td"> <span>RANG</span> </div> <div class="td"> <span></span> </div> </div> </div> <div class="skills"> <div class="table comskill skilltable"> </div> </div> <div class="skills_headers type"> <div class="tr"> <div class="td"> <span>COMP. DE CONNAISSANCE</span> </div> <div class="td"> <span>CARRIÈRE</span> </div> <div class="td"> <span>RANG</span> </div> <div class="td"> <span></span> </div> </div> </div> <div class="skills"> <div class="table knoskill skilltable"> </div> </div> <div class="skill_additional"> <div class='type'> <div class='text'> COMPÉTENCES MAISON </div> </div> <div class="skill_additional_value"> <span class="dsf dsf_skills_additional skills"></span> </div> </div> </div> </div> <div class="section"> </div> <div class="strike"> <div><div class="section_title">ARMES</div></div> </div> <div class="weapons"> <table class="weapon"> <thead> <tr> <th><a href="javascript:void(0)" title="Ajouter une arme">+</a></th> <th>ARME</th> <th>COMPÉTENCE</th> <th>DÉGÂTS</th> <th>CRITIQUE</th> <th>PORTÉE</th> <th>SPÉCIAL</th> </tr> </thead> <tbody></tbody> </table> </div> </div> <div class="main page_bio" style="display:none;"> <div class="strike"> <div><div class="section_title">EXPÉRIENCE</div></div> </div> <div class="experience"> <div class="attribute_box"> <div class="attribute_box_shadow"></div> <div class="type"> <div class="text"> Total en XP </div> </div> <div class="attribute"> <div class="text"> <span class="dsf dsf_earned_xp user_input"></span> </div> </div> </div> <div class="campaign_box"> <span>Campagne </span><span class="dsf dsf_campaign user_input"></span> </div> <div class="attribute_box"> <div class="attribute_box_shadow"></div> <div class="type"> <div class="text"> XP Disponibles </div> </div> <div class="attribute"> <div class="text"> <span class="dsf dsf_unspent_xp user_input"></span> </div> </div> </div> <span class="stretch"></span> </div> <div class="character_description_container"> <div class="character_description"> <div class="type"> <div class="text"> DESCRIPTION </div> </div> <div> <div class="portrait_holder"> <div class="portrait readonly dsf dsf_avatar_image"></div> </div> <div class="character_descriptions"> <div><span>SEXE</span><span class="dsf dsf_gender user_input"></span></div> <div><span>ÂGE</span><span class="dsf dsf_age user_input"></span></div> <div><span>TAILLE</span><span class="dsf dsf_height user_input"></span></div> <div><span>CARRURE</span><span class="dsf dsf_build user_input"></span></div> <div><span>CHEVEUX</span><span class="dsf dsf_hair user_input"></span></div> <div><span>YEUX</span><span class="dsf dsf_eyes user_input"></span></div> <div><span>SIGNES PARTICULIERS</span><div class="text"><span class="dsf dsf_notable user_input"></span></div></div> </div> </div> </div> </div> <div class="motivations_container"> <div class="motivations"> <div class="type"> <div class="text"> <a href="javascript:void(0)" title="Ajouter une motivation">+</a> MOTIVATIONS </div> </div> <div class="motivation_list"> <ul></ul> </div> </div> </div> <div class="obligations_container"> <div class="obligations"> <div class="type"> <div class="text"> <a href="javascript:void(0)" title="Ajouter un devoir">+</a> DEVOIRS </div> </div> <div class="obligation_list"> <ul></ul> </div> </div> </div> <div class="equipment_container"> <div class="equipment"> <div class="type"> <div class="text"> EQUIPEMENT </div> <div class="credits"> <span>CRÉDITS</span><span class="dsf dsf_credits user_input"></span> </div> </div> <div> <div class="log"> <div><div class="title">ARMES ET ARMURES</div><div class="text"><ul><li class="dsf dsf_weapons_and_armor user_input"></li></ul></div></div> <div><div class="title">MATÉRIEL PERSONNEL</div><div class="text"><ul><li class="dsf dsf_personal_gear user_input"></li></ul></div></div> <span class="stretch"></span> </div> </div> </div> </div> <div class="spacer"></div> <div class="critical_injuries_container"> <div class="critical_injuries"> <div class="type"> <div class="text"> <a href="javascript:void(0)" title="Ajouter une blessure critique">+</a> BLESSURES CRITIQUES </div> </div> <div class="critical_injury_list"> <ul></ul> </div> </div> </div> <div class="talents_container"> <div class="talents"> <div class="type"> <div class="text"> <a href="javascript:void(0)" title="Ajouter un talent">+</a> TALENTS ET CAPACITÉS SPÉCIALES </div> </div> <div class="talent_list"> <table class="talent" cellpadding="2" cellspacing="0"> <thead> <tr> <th> </th> <th>NOM</th> <th>PAGE N°</th> <th>RÉSUMÉ</th> </tr> </thead> <tbody></tbody> </table> </div> </div> </div> <div class="bio_container"> <div class="bio"> <div class="type"> <div class="text"> BIOGRAPHIE </div> </div> <div class="bio_text"> <span class="dsf dsf_bio user_input"></span> </div> </div> </div> <input type="file" class="eote_export_file" /> <a href="javascript:void(0);" class="process_xml_button" title="Future Functionality!">Import XML File</a> <div class="author">Dynamic Style Sheet by <span class="dsf dsf_dst_author"></span> based on the work of BlueEyedFireDragon and barrelv</div> </div> </div> <!-- ds_sw_edlr -->
CSS
/* latin */ @font-face { font-family: 'Share Tech Mono'; font-style: normal; font-weight: 400; src: local('Share Tech Mono'), local('ShareTechMono-Regular'), url(https://fonts.gstatic.com/s/sharetechmono/v6/RQxK-3RA0Lnf3gnnnNrAsYdJ2JT0J65PSe7wdxAnx_I.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215, U+E0FF, U+EFFD, U+F000; } /* latin */ @font-face { font-family: 'Abel'; font-style: normal; font-weight: 400; src: local('Abel'), local('Abel-Regular'), url(https://fonts.gstatic.com/s/abel/v6/brdGGFwqYJxjg2CD1E9o7g.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215, U+E0FF, U+EFFD, U+F000; } /* latin */ @font-face { font-family: 'Shadows Into Light'; font-style: normal; font-weight: 400; src: local('Shadows Into Light'), local('ShadowsIntoLight'), url(https://fonts.gstatic.com/s/shadowsintolight/v6/clhLqOv7MXn459PTh0gXYFK2TSYBz0eNcHnp4YqE4Ts.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215, U+E0FF, U+EFFD, U+F000; } div.ds_sw_edlr .base { font-family: Share Tech Mono, serif; position:relative; background-color:white; z-index: 98; line-height: 1; width:850px; } div.ds_sw_edlr .jeditable_input input { width:100% !important; height:100% !important; } div.ds_sw_edlr .user_input { font-family: Shadows Into Light, cursive; } /* Top Sections *****************************************************/ div.ds_sw_edlr .line span:not(.dsf) { text-transform: uppercase; } div.ds_sw_edlr .line span.dsf { font-size:22px; font-style:italic; } div.ds_sw_edlr .line ul { -webkit-column-count: 2; /* Chrome, Safari, Opera */ -moz-column-count: 2; /* Firefox */ column-count: 2; padding:0; margin:0; } div.ds_sw_edlr .line ul li { border-bottom: solid #000 1px; list-style-type: none; } /*noinspection CssInvalidPropertyValue*/ div.ds_sw_edlr .line ul li .span_all { -webkit-column-span: all; column-span: all; list-style-type: none; } /* Section Headers *****************************************************/ div.ds_sw_edlr .strike { display: block; text-align: center; overflow: hidden; white-space: nowrap; padding-top:10px; } div.ds_sw_edlr .section_title { height:20px; width: 200px; text-transform: uppercase; background: linear-gradient(135deg, transparent 7px, #324356 0) top left, linear-gradient(225deg, transparent 7px, #324356 0) top right, linear-gradient(315deg, transparent 7px, #324356 0) bottom right, linear-gradient(45deg, transparent 7px, #324356 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; color: #968d82; padding-top: 6px; font-weight: bold; } div.ds_sw_edlr .strike > div { position: relative; display: inline-block; } div.ds_sw_edlr .strike > div:before, div.ds_sw_edlr .strike > div:after { content: ""; position: absolute; top: 50%; width: 9999px; height: 3px; background: #761012; } div.ds_sw_edlr .strike > div:before { right: 100%; margin-right: 15px; } div.ds_sw_edlr .strike > div:after { left: 100%; margin-left: 15px; } /* Stats Section *****************************************************/ /*noinspection CssInvalidPropertyValue*/ div.ds_sw_edlr .stats { text-align: justify; -ms-text-justify: distribute-all-lines; text-justify: distribute-all-lines; height:120px; width: 830px } div.ds_sw_edlr .stat_block { width: 120px; text-align:center; display:inline-block; *display: inline; } div.ds_sw_edlr .stat { width: 80px; height: 80px; border-radius: 80px 80px 80px 80px; background: #fff; margin-top: 3px; padding: 0; display:inline-block; *display: inline; border: solid #000 3px; margin-left:auto; margin-right: auto; position:relative; } div.ds_sw_edlr .stat:before { content: ""; position: absolute; top: 0; left: -20px; width: 124px; height: 20px; background: linear-gradient(135deg, transparent 6px, #b96532 0) top left, linear-gradient(225deg, transparent 6px, #b96532 0) top right, linear-gradient(315deg, transparent 6px, #b96532 0) bottom right, linear-gradient(45deg, transparent 6px, #b96532 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; z-index: -1; } div.ds_sw_edlr .stat:after { content: ""; position: absolute; top: 25px; left: -20px; width: 124px; height: 20px; background: linear-gradient(135deg, transparent 6px, #b96532 0) top left, linear-gradient(225deg, transparent 6px, #b96532 0) top right, linear-gradient(315deg, transparent 6px, #b96532 0) bottom right, linear-gradient(45deg, transparent 6px, #b96532 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; z-index: -1; } div.ds_sw_edlr .stat_background { position: absolute; top: 50px; left: -20px; width: 124px; height: 20px; background: linear-gradient(135deg, transparent 6px, #b96532 0) top left, linear-gradient(225deg, transparent 6px, #b96532 0) top right, linear-gradient(315deg, transparent 6px, #b96532 0) bottom right, linear-gradient(45deg, transparent 6px, #b96532 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; z-index: -1; } div.ds_sw_edlr .stat_background:after { content: ""; position: absolute; top: 25px; left: 0; width: 124px; height: 46px; background: linear-gradient(135deg, transparent 6px, #b96532 0) top left, linear-gradient(225deg, transparent 6px, #b96532 0) top right, linear-gradient(315deg, transparent 6px, #b96532 0) bottom right, linear-gradient(45deg, transparent 6px, #b96532 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; z-index: -1; } div.ds_sw_edlr .stat .text { font-family: Share Tech Mono, Arial, serif; text-align: center; font-size: 48pt; padding-top: 7px; } div.ds_sw_edlr .type { /*background: #860000;*/ height: 24px; width: 100%; margin-top: 10px; margin-left: 2px; /*border-radius: 5px 5px 5px 5px;*/ background: linear-gradient(135deg, transparent 5px, #324356 0) top left, linear-gradient(225deg, transparent 5px, #324356 0) top right, linear-gradient(315deg, transparent 5px, #324356 0) bottom right, linear-gradient(45deg, transparent 5px, #324356 0) bottom left; background-size: 51% 50%; background-repeat: no-repeat; } div.ds_sw_edlr .type .text { font-family: Share Tech Mono, Arial, serif; padding-top: 4px; font-size: 12pt; color: #fff; text-transform: uppercase; text-align: center; } /* Attribute Sections *****************************************************/ /*noinspection CssInvalidPropertyValue*/ div.ds_sw_edlr .attributes { padding-top:5px; position:relative; text-align: justify; -ms-text-justify: distribute-all-lines; text-justify: distribute-all-lines; height:80px; width: 830px } div.ds_sw_edlr .attribute_box .attribute_box_shadow { content: ""; position:absolute; top: -3px; height: 66px; width: 193px; left:-3px; background: linear-gradient(135deg, transparent 10px, #000 0) top left, linear-gradient(225deg, transparent 10px, #000 0) top right, linear-gradient(315deg, transparent 10px, #000 0) bottom right, linear-gradient(45deg, transparent 10px, #000 0) bottom left; background-size: 51% 50%; background-repeat: no-repeat; z-index: -1; } div.ds_sw_edlr .attribute_box { display:inline-block; *display: inline; position: relative; width: 187px; height: 60px; background: linear-gradient(135deg, transparent 10px, #fff 0) top left, linear-gradient(225deg, transparent 10px, #fff 0) top right, linear-gradient(315deg, transparent 10px, #fff 0) bottom right, linear-gradient(45deg, transparent 10px, #fff 0) bottom left; background-size: 51% 50%; background-repeat: no-repeat; vertical-align: top; } div.ds_sw_edlr .attribute_box .split_box { left: -10px; position: absolute; top: 50%; width: 210px; height: 50px; background: linear-gradient(135deg, transparent 5px, #761012 0) top left, linear-gradient(225deg, transparent 5px, #70cddc 0) top right, linear-gradient(315deg, transparent 5px, #70cddc 0) bottom right, linear-gradient(45deg, transparent 5px, #761012 0) bottom left; background-size: 51% 50%; background-repeat: no-repeat; z-index: -2; } div.ds_sw_edlr .attribute_box .split_box div:first-child { width: 45%; position: absolute; bottom: 0; text-align: center; text-transform: uppercase; color: #fff; font-size: 11px; right: 50%; padding-right: 5px; padding-bottom: 3px; } div.ds_sw_edlr .attribute_box .split_box div:last-child { width:45%; position:absolute; bottom:0; text-align: center; text-transform:uppercase; font-weight: bold; color:#000; font-size:11px; left: 50%; padding-left:5px; padding-bottom: 3px; } div.ds_sw_edlr .attribute_box .type { position: absolute; margin-left: 5px; width: 170px; height: 18px; /* top: 5px; */ margin-top: 5px; left: 4px; background: linear-gradient(135deg, transparent 5px, #761012 0) top left, linear-gradient(225deg, transparent 5px, #761012 0) top right, linear-gradient(315deg, transparent 5px, #761012 0) bottom right, linear-gradient(45deg, transparent 5px, #761012 0) bottom left; background-size: 51% 50%; background-repeat: no-repeat; z-index: 1; } div.ds_sw_edlr .attribute_box .type .text { text-align: center; padding-top: 2px; font-size: 10pt; } div.ds_sw_edlr .attribute_box .attribute { font-size: 24pt; text-align: center; padding-top: 21px; } div.ds_sw_edlr .attribute_box .attribute .text ul { -webkit-column-count: 2; /* Chrome, Safari, Opera */ -moz-column-count: 2; /* Firefox */ column-count: 2; padding:0; margin:0; list-style:none } div.ds_sw_edlr .attribute_box .attribute .text li:first-child { position:absolute; left:30px; top:25%; list-style:none; } div.ds_sw_edlr .attribute_box .attribute .text li:last-child { position:absolute; right:30px; top:25%; list-style:none; } div.ds_sw_edlr .attribute_box .attribute .text li.divider { width: 2px; height: 99%; background-color: #000; position: absolute; left: 49%; list-style: none; } div.ds_sw_edlr .attribute li { width:36px; height:36px; } /* Skills Sections *****************************************************/ div.ds_sw_edlr .skills { /** height:850px;**/ font-family: Abel, sans-serif; } div.ds_sw_edlr .Genskills { height:850px; } div.ds_sw_edlr .Knoskills { height:650px; } div.ds_sw_edlr .table { display: inline-block; /* required to keep a nice spacing between columns */ /* -webkit-column-count: 2;*/ -webkit-column-gap: 10px; /*-moz-column-count: 2;*/ -moz-column-gap: 10px; /*column-count: 2;*/ column-gap: 10px; /* width:50%*/ } div.ds_sw_edlr .section{ padding:0 0 5px 0; margin:0 0 5px 1px; } div.ds_sw_edlr .half_sheet_column{ width:415px; display:inline-block; vertical-align:top; } div.ds_sw_edlr .skills .tr, .skills_headers .tr { display: inline-block; } div.ds_sw_edlr .skills .td, .skills_headers .td { display: inline-block; /*padding: 5px;*/ text-align: left; } div.ds_sw_edlr .skilltable .tr:nth-child(even){ background-color: #dad7ce; } div.ds_sw_edlr .skilltable .tr:nth-child(odd) { background-color: #f3e8d0; } div.ds_sw_edlr .skilltable .td { padding:0; height: 24px; } div.ds_sw_edlr .skills_headers { height: 24px; font-size: 10pt; padding-top: 4px; } div.ds_sw_edlr .skills_headers .td { height: auto; text-align: center; color: white; text-transform: uppercase; padding-top: 4px; } div.ds_sw_edlr .skills_headers .td:nth-child(1) { width: 180px; } div.ds_sw_edlr .skills_headers .td:nth-child(2) { width: 80px; } div.ds_sw_edlr .skills_headers .td:nth-child(3) { width: 60px; } div.ds_sw_edlr .skills_headers .td:nth-child(4) { width: 82px; } div.ds_sw_edlr .skilltable .td:nth-child(1) { width: 185px; padding-left: 5px; } div.ds_sw_edlr .skilltable .td:nth-child(2) { width: 80px; text-align: center; } div.ds_sw_edlr .skilltable .td:nth-child(3) { width: 60px; text-align:center; } div.ds_sw_edlr .skilltable .td:nth-child(4) { width: 82px; } div.ds_sw_edlr .skill_additional { width: 100%; height: 160px; background: linear-gradient(135deg, transparent 5px, #CECFCB 0) top left, linear-gradient(225deg, transparent 5px, #CECFCB 0) top right, linear-gradient(315deg, transparent 5px, #CECFCB 0) bottom right, linear-gradient(45deg, transparent 5px, #CECFCB 0) bottom left; background-size: 51% 50%; background-repeat: no-repeat; } div.ds_sw_edlr .skill_additional_value { padding: 5px; } /* Misc Sections *****************************************************/ div.ds_sw_edlr .green { width: 16px; height: 18px; background: linear-gradient(135deg, transparent 6px, #2f8237 0) top left, linear-gradient(225deg, transparent 6px, #2f8237 0) top right, linear-gradient(315deg, transparent 6px, #2f8237 0) bottom right, linear-gradient(45deg, transparent 6px, #2f8237 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; float:left; list-style: none; margin-top: 8px; } div.ds_sw_edlr .yellow { width: 16px; height: 16px; background: linear-gradient(135deg, transparent 3px, #ffd923 0) top left, linear-gradient(225deg, transparent 3px, #ffd923 0) top right, linear-gradient(315deg, transparent 3px, #ffd923 0) bottom right, linear-gradient(45deg, transparent 3px, #ffd923 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; float:left; list-style: none; margin-top: 8px; } div.ds_sw_edlr .stretch { width: 100%; display: inline-block; font-size: 0; line-height: 0 } div.ds_sw_edlr .spacer { height: 10px; background: #fff; } div.ds_sw_edlr .eote_export_file { display: none; } div.ds_sw_edlr .base table tr th, .base table tr td { padding:3px; } div.ds_sw_edlr .process_xml_button { display: none; } /* Wespon Sections *****************************************************/ div.ds_sw_edlr .weapon { width:100%; border-collapse: collapse; } div.ds_sw_edlr .weapon th { text-align:left; } div.ds_sw_edlr .weapon th:first-child a { color: #fff; text-decoration: none; width: 20px; background-color: #dad7ce; padding: 2px 5px; } div.ds_sw_edlr .weapon tbody tr:nth-child(even) { background-color: #dad7ce; font-size: 22px; } div.ds_sw_edlr .weapon tbody tr:nth-child(odd) { background-color: #f3e8d0; font-size: 22px; } /* Experience Sections *****************************************************/ /*noinspection CssInvalidPropertyValue*/ div.ds_sw_edlr .experience { text-align: justify; -ms-text-justify: distribute-all-lines; text-justify: distribute-all-lines; min-width: 560px } div.ds_sw_edlr .experience .attribute_box { text-align:center; display:inline-block; *display: inline; } div.ds_sw_edlr .experience .campaign_box { width: 300px; text-align:center; display:inline-block; *display: inline; padding-top: 10px; } div.ds_sw_edlr .experience .campaign_box span:first-child { text-transform:uppercase; } /* Motivation Sections *****************************************************/ div.ds_sw_edlr .motivations_container { width: 66%; background: #CECFCB; } div.ds_sw_edlr .motivations { text-align:right; background: linear-gradient(135deg, #fff 0px, #CECFCB 0) top left, linear-gradient(225deg, #fff 6px, #CECFCB 0) top right, linear-gradient(315deg, #fff 0px, #CECFCB 0) bottom right, linear-gradient(45deg, #fff 6px, #CECFCB 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; min-height: 200px; } div.ds_sw_edlr .motivations .type { background:none; } div.ds_sw_edlr .motivations .type .text { text-align: right; padding-top: 4px; padding-right: 10px; font-size: 12pt; color: #000; } div.ds_sw_edlr .motivations .type .text a { color: #fff; text-decoration: none; width: 20px; background-color: #A79B86; padding: 2px 5px; } div.ds_sw_edlr .motivations .motivation_list ul { margin:0; padding:0; } div.ds_sw_edlr .motivations .motivation_list li div:first-child { border-bottom: 1px solid #000; } div.ds_sw_edlr .motivations .motivation_list li div:first-child a { float:right; } div.ds_sw_edlr .motivations .motivation_list li { list-style:none; text-align:left; padding: 10px; } div.ds_sw_edlr .motivations_container .motivation_list ul div span:first-child { text-transform:uppercase; } div.ds_sw_edlr .motivations_container .motivation_list ul div span:not(:first-child) { font-size:22px; } /* Obligations Sections *****************************************************/ div.ds_sw_edlr .obligations_container { width: 66%; background: #CECFCB; } div.ds_sw_edlr .obligations { text-align:right; background: linear-gradient(135deg, #fff 0px, #CECFCB 0) top left, linear-gradient(225deg, #fff 6px, #CECFCB 0) top right, linear-gradient(315deg, #fff 0px, #CECFCB 0) bottom right, linear-gradient(45deg, #fff 6px, #CECFCB 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; min-height: 200px; } div.ds_sw_edlr .obligations .type { background:none; } div.ds_sw_edlr .obligations .type .text { text-align: right; padding-top: 4px; padding-right: 10px; font-size: 12pt; color: #000; } div.ds_sw_edlr .obligations .type .text a { color: #fff; text-decoration: none; width: 20px; background-color: #A79B86; padding: 2px 5px; } div.ds_sw_edlr .obligations .obligation_list ul { margin:0; padding:0; } div.ds_sw_edlr .obligations .obligation_list li div:nth-child(-n+2) { border-bottom: 1px solid #000; } div.ds_sw_edlr .obligations .obligation_list li div:first-child a { float:right; } div.ds_sw_edlr .obligations .obligation_list li { list-style:none; text-align:left; padding: 10px; } div.ds_sw_edlr .obligations_container .obligation_list ul div span:first-child { text-transform:uppercase; } div.ds_sw_edlr .obligations_container .obligation_list ul div span:not(:first-child) { font-size:22px; } /* Equipment Sections *****************************************************/ div.ds_sw_edlr .equipment_container { width: 66%; background: #CECFCB; } div.ds_sw_edlr .equipment { text-align:right; background: linear-gradient(135deg, #fff 0px, #CECFCB 0) top left, linear-gradient(225deg, #fff 6px, #CECFCB 0) top right, linear-gradient(315deg, #fff 0px, #CECFCB 0) bottom right, linear-gradient(45deg, #fff 6px, #CECFCB 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; } div.ds_sw_edlr .equipment .type { background:none; } div.ds_sw_edlr .equipment .type .text { text-align: right; padding-top: 4px; padding-right: 10px; font-size: 12pt; color: #000; } div.ds_sw_edlr .equipment .type .credits { float: left; margin-left: 10px; background-color: #fff; width: 45%; text-align: left; margin-top: -10px; padding: 3px 0 3px 0; } div.ds_sw_edlr .equipment .type .credits span:first-child { text-transform:uppercase; } div.ds_sw_edlr .equipment .type .credits span { padding-left: 10px; } /*noinspection CssInvalidPropertyValue*/ div.ds_sw_edlr .equipment .log { text-align: justify; -ms-text-justify: distribute-all-lines; text-justify: distribute-all-lines; padding-bottom: 10px; padding-top: 20px; } div.ds_sw_edlr .equipment .log div { vertical-align: top; width: 45%; display:inline-block; *display: inline; margin: 0 10px 0 10px; background-color: #fff; text-align:center; padding: 5px 0 5px 0; } div.ds_sw_edlr .equipment .log .title { width: 80%; border-bottom: 1px solid #000; text-transform:uppercase; } div.ds_sw_edlr .equipment .log .text { width:100%; text-align: left; margin: 0; padding-top: 5px; font-size: 22px; min-height:150px; } div.ds_sw_edlr .equipment .log .text li { padding: 10px; list-style: none; } /* Character Desc Sections *****************************************************/ div.ds_sw_edlr .character_description_container { float:right; width:33%; background: #CECFCB; margin-top:10px; } div.ds_sw_edlr .character_description { text-align:right; background: linear-gradient(135deg, #fff 0px, #CECFCB 0) top left, linear-gradient(225deg, #fff 0px, #CECFCB 0) top right, linear-gradient(315deg, #fff 6px, #CECFCB 0) bottom right, linear-gradient(45deg, #fff 6px, #CECFCB 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; padding: 0 0 5px 0; } div.ds_sw_edlr .character_description .type { background:none; margin: 0; } div.ds_sw_edlr .character_description .type .text { text-align: right; padding-top: 4px; padding-right: 10px; font-size: 12pt; color: #000; } div.ds_sw_edlr .character_descriptions .user_input { float: right; font-size: 22px; } div.ds_sw_edlr .character_descriptions .text .user_input { float: none; font-size: 22px; } div.ds_sw_edlr .character_descriptions div { padding: 10px 0 10px 0; margin: 0 10px 0 10px; text-align: left; border-bottom: 1px solid #000; } div.ds_sw_edlr .character_descriptions div span:first-child { text-transform: uppercase; } div.ds_sw_edlr .character_descriptions div:last-child { border:none; } div.ds_sw_edlr .character_descriptions .text { max-height: 100px; overflow-y:auto; } div.ds_sw_edlr .character_descriptions .text span:first-child { text-transform:none; overflow-y:scroll; } /* Critical Injuries Sections *****************************************************/ div.ds_sw_edlr .critical_injuries_container { min-height: 100px; } div.ds_sw_edlr .critical_injuries .type .text a { color: #fff; text-decoration: none; width: 20px; background-color: #A79B86; padding: 2px 5px; } div.ds_sw_edlr .critical_injuries { text-align:right; background: linear-gradient(135deg, #fff 6px, #CECFCB 0) top left, linear-gradient(225deg, #fff 6px, #CECFCB 0) top right, linear-gradient(315deg, #fff 6px, #CECFCB 0) bottom right, linear-gradient(45deg, #fff 6px, #CECFCB 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; min-height: 200px; padding-bottom: 10px; } div.ds_sw_edlr .critical_injuries .type { background:none; margin: 0; } div.ds_sw_edlr .critical_injuries .type .text { text-align: right; padding-top: 4px; padding-right: 10px; font-size: 12pt; color: #000; } div.ds_sw_edlr .critical_injuries_descriptions div { padding: 10px 0 10px 0; margin: 0 10px 0 10px; text-align: left; border-bottom: 1px solid #000; } div.ds_sw_edlr .critical_injuries_descriptions div span:first-child { text-transform: uppercase; } div.ds_sw_edlr .critical_injuries_descriptions .text, .character_descriptions div:last-child { border:none; } div.ds_sw_edlr .critical_injuries_descriptions .text { max-height: 100px; overflow-y:auto; } div.ds_sw_edlr .critical_injuries_descriptions .text span:first-child { text-transform:none; overflow-y:scroll; } div.ds_sw_edlr .critical_injury_list { overflow:auto; } div.ds_sw_edlr .critical_injuries .critical_injury_list ul { margin:0; padding:0; } div.ds_sw_edlr .critical_injuries .critical_injury_list li div:last-child { border-bottom: 1px solid #000; } div.ds_sw_edlr .critical_injuries .critical_injury_list li div:first-child a { float:right; } div.ds_sw_edlr .critical_injuries .critical_injury_list li { list-style:none; text-align:left; padding: 10px; } div.ds_sw_edlr .critical_injuries_container .critical_injury_list ul div span:first-child { text-transform:uppercase; } div.ds_sw_edlr .critical_injuries_container .critical_injury_list ul div span:not(:first-child) { font-size:1em; } /* Talents Sections *****************************************************/ div.ds_sw_edlr .talents_container { padding-top: 10px; } div.ds_sw_edlr .talents { text-align:right; background: linear-gradient(135deg, #fff 6px, #CECFCB 0) top left, linear-gradient(225deg, #fff 6px, #CECFCB 0) top right, linear-gradient(315deg, #fff 6px, #CECFCB 0) bottom right, linear-gradient(45deg, #fff 6px, #CECFCB 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; min-height: 200px; padding-bottom: 10px; } div.ds_sw_edlr .talents .type .text a { color: #fff; text-decoration: none; width: 20px; background-color: #A79B86; padding: 2px 5px; } div.ds_sw_edlr .talents .type { background:none; margin: 0; } div.ds_sw_edlr .talents .type .text { text-align: right; padding-top: 4px; padding-right: 10px; font-size: 12pt; color: #000; } div.ds_sw_edlr .talents table.talent { margin-left: auto; margin-right: auto; width: inherit; } div.ds_sw_edlr .talents table.talent th, .talents table.talent td{ text-align:left; } div.ds_sw_edlr .talents table.talent thead { background: #CECFCB ; } div.ds_sw_edlr .talents table.talent tbody tr:nth-child(even){ background-color: #dad7ce; font-size: 22px; } div.ds_sw_edlr .talents table.talent tbody tr:nth-child(odd){ background-color: #f3e8d0; font-size: 22px; } div.ds_sw_edlr .talents table.talent th:nth-child(1) { width:25px; } div.ds_sw_edlr .talents table.talent th:nth-child(2) { width:150px; } div.ds_sw_edlr .talents table.talent th:nth-child(3) { width:75px; } div.ds_sw_edlr .talents table.talent th:nth-child(4) { width:600px; } div.ds_sw_edlr .talents .talent_list ul { padding:0; margin:0; } div.ds_sw_edlr .talents .talent_list li { list-style:none; text-align:left; } div.ds_sw_edlr .talents .talent_list li div:not(:first-child) { float:left; } div.ds_sw_edlr .talents .talent_list li div span { vertical-align: top; } /* Biography Sections *****************************************************/ div.ds_sw_edlr .bio_container { padding-top: 10px; } div.ds_sw_edlr .bio { text-align:right; background: linear-gradient(135deg, #fff 6px, #CECFCB 0) top left, linear-gradient(225deg, #fff 6px, #CECFCB 0) top right, linear-gradient(315deg, #fff 6px, #CECFCB 0) bottom right, linear-gradient(45deg, #fff 6px, #CECFCB 0) bottom left; background-size: 50% 50%; background-repeat: no-repeat; min-height: 100px; padding-bottom: 10px; } div.sw_edlr_bio .type .text a { color: #fff; text-decoration: none; width: 20px; background-color: #A79B86; padding: 2px 5px; } div.ds_sw_edlr .bio .type { background:none; margin: 0; } div.ds_sw_edlr .bio .type .text { text-align: right; padding-top: 4px; padding-right: 10px; font-size: 12pt; color: #000; } div.ds_sw_edlr .bio_text { text-align:left; padding: 0 5px; } div.ds_sw_edlr .author { float:right; font-size: 10px; } /* Portrait */ div.ds_sw_edlr .character_descriptions .portrait_holder{ display:inline-block; position:relative; float:right; padding:0 0 0 0; margin:3px 3px 5px 10px; border: 0 solid #554220; } div.ds_sw_edlr .portrait_holder .character_descriptions .portrait .avatar_image { min-height: 140px; min-width: 140px; background-color: white; margin: 0; padding: 0; max-height: 300px; max-width: 240px; } div.ds_sw_edlr .tab_bar{ position: absolute; top: -58px; right: 0; z-index: 3; background: url('https://chainsawxiv.github.io/DST/common/images/misc/switch2.png') no-repeat top center; height: 58px; width: 212px; text-align: center; } div.ds_sw_edlr .bio_tab{ position: absolute; top: 1px; right: 68px; height: 50px; } div.ds_sw_edlr .stats_tab{ position: absolute; top: 1px; right: 116px; height: 50px; } div.ds_sw_edlr .tab{ display: inline-block; float: right; } div.ds_sw_edlr .pagehead{ border: 3px solid #761012; padding: 5px; }
JavaScript
var skills = { "Skills": { "GenSkill": [ { "Key": "ASTRO", "Name": "Astrogation", "CharKey": "INT", "CharName": "Int", "Type": "General" }, { "Key": "ATHL", "Name": "Athlétisme", "CharKey": "BR", "CharName": "Vig", "Type": "General" }, { "Key": "COOL", "Name": "Calme", "CharKey": "PR", "CharName": "Pré", "Type": "General" }, { "Key": "CHARM", "Name": "Charme", "CharKey": "PR", "CharName": "Pré", "Type": "General" }, { "Key": "COERC", "Name": "Coercition", "CharKey": "WIL", "CharName": "Vol", "Type": "General" }, { "Key": "LEAD", "Name": "Commandement", "CharKey": "PR", "CharName": "Pré", "Type": "General" }, { "Key": "COORD", "Name": "Coordination", "CharKey": "AG", "CharName": "Ag", "Type": "General" }, { "Key": "STEAL", "Name": "Discrétion", "CharKey": "AG", "CharName": "Ag", "Type": "General" }, { "Key": "COMP", "Name": "Informatique", "CharKey": "INT", "CharName": "Int", "Type": "General" }, { "Key": "SKUL", "Name": "Magouilles", "CharKey": "CUN", "CharName": "Ru", "Type": "General" }, { "Key": "MECH", "Name": "Mécanique", "CharKey": "INT", "CharName": "Int", "Type": "General" }, { "Key": "MED", "Name": "Médicine", "CharKey": "INT", "CharName": "Int", "Type": "General" }, { "Key": "NEG", "Name": "Négociation", "CharKey": "PR", "CharName": "Pré", "Type": "General" }, { "Key": "PERC", "Name": "Perception", "CharKey": "CUN", "CharName": "Ru", "Type": "General" }, { "Key": "PILOTSP", "Name": "Pilotage (espace)", "CharKey": "AG", "CharName": "Ag", "Type": "General" }, { "Key": "PILOTPL", "Name": "Pilotage (planétaire)", "CharKey": "AG", "CharName": "Ag", "Type": "General" }, { "Key": "RESIL", "Name": "Résistance", "CharKey": "BR", "CharName": "Vig", "Type": "General" }, { "Key": "DISC", "Name": "Sang-froid", "CharKey": "WIL", "CharName": "Vol", "Type": "General" }, { "Key": "SURV", "Name": "Survie", "CharKey": "CUN", "CharName": "Ru", "Type": "General" }, { "Key": "SW", "Name": "Système D", "CharKey": "CUN", "CharName": "Ru", "Type": "General" }, { "Key": "DECEP", "Name": "Tromperie", "CharKey": "CUN", "CharName": "Ru", "Type": "General" }, { "Key": "VIGIL", "Name": "Vigilance", "CharKey": "WIL", "CharName": "Vol", "Type": "General" } ], "ComSkill": [ { "Key": "GUNN", "Name": "Artillerie", "CharKey": "AG", "CharName": "Ag", "Type": "Combat" }, { "Key": "MELEE", "Name": "Corps à corps", "CharKey": "BR", "CharName": "Vig", "Type": "Combat" }, { "Key": "RANGLT", "Name": "Distance - Armes légères", "CharKey": "AG", "CharName": "Ag", "Type": "Combat" }, { "Key": "RANGHVY", "Name": "Distance - Armes lourdes", "CharKey": "AG", "CharName": "Ag", "Type": "Combat" }, { "Key": "BRAWL", "Name": "Pugilat", "CharKey": "BR", "CharName": "Vig", "Type": "Combat" } ], "KnoSkill": [ { "Key": "OUT", "Name": "Bordure extérieure", "CharKey": "INT", "CharName": "Int", "Type": "Knowledge" }, { "Key": "LORE", "Name": "Culture", "CharKey": "INT", "CharName": "Int", "Type": "Knowledge" }, { "Key": "EDU", "Name": "Éducation", "CharKey": "INT", "CharName": "Int", "Type": "Knowledge" }, { "Key": "CORE", "Name": "Mondes du Noyau", "CharKey": "INT", "CharName": "Int", "Type": "Knowledge" }, { "Key": "UND", "Name": "Pègre", "CharKey": "INT", "CharName": "Int", "Type": "Knowledge" }, { "Key": "WARF", "Name": "Stratégie", "Source": "Age of Rebellion Core Rulebook", "CharKey": "INT", "CharName": "Int", "Type": "Knowledge" }, { "Key": "XEN", "Name": "Xénologie", "CharKey": "INT", "CharName": "Int", "Type": "Knowledge" } ] } }; // Data Preload function sw_edlr_dataPreLoad(options) { var i; aisleten.characters.jeditablePlaceholder = "##"; sw_edlr_options = options; var weapons = [], motivations = [], obligations = [], criticals = [], talents = []; // remove add buttons if not editable if (!options.isEditable) { $(".weapon th a").remove(); $(".motivations .type .text a").remove(); $(".obligations .type .text a").remove(); $(".critical_injuries .type .text a").remove(); $(".talents .type .text a").remove(); $(".eote_export_file").remove(); $(".process_xml_button").remove(); } else { $(".bio_container").remove() } // load previously saved values $.each(dynamic_sheet_attrs, function (key) { var id = key.substring(key.lastIndexOf("_") + 1); if (key.substring(0, 5).toLowerCase() === "weapo") { if (weapons.indexOf(id) === -1) { $(".weapons table.weapon tbody").append( "<tr>" + "<td>" + (options.isEditable ? "<a href='javascript:void(0);' title='Supprimer l'arme'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" : "") + "</td>" + "<td>" + "<span class='dsf dsf_weapon_name_" + id + " user_input'>" + "</td>" + "<td>" + "<span class='dsf dsf_weapon_skill_" + id + " user_input'>" + "</td>" + "<td>" + "<span class='dsf dsf_weapon_damage_" + id + " user_input'>" + "</td>" + "<td>" + "<span class='dsf dsf_weapon_range_" + id + " user_input'>" + "</td>" + "<td>" + "<span class='dsf dsf_weapon_crit_" + id + " user_input'>" + "</td>" + "<td>" + "<span class='dsf dsf_weapon_special_" + id + " user_input'>" + "</td></tr>" ); weapons.push(id); } } if (key.substring(0, 5).toLowerCase() === "motiv") { if (motivations.indexOf(id) === -1) { $(".motivations_container .motivation_list ul").append( "<li>" + "<div><span>Type </span><span class='dsf dsf_motivation_type_" + id + " user_input'></span>" + (options.isEditable ? "<a href='javascript:void(0);' title='Supprimer la motivation'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" : "") + "</div>" + "<div><span>Notes </span><span class='dsf dsf_motivation_notes_" + id + " user_input'></span></div>" + "</li>" ); motivations.push(id); } } if (key.substring(0, 5).toLowerCase() === "oblig") { if (obligations.indexOf(id) === -1) { $(".obligations_container .obligation_list ul").append( "<li>" + "<div><span>Type </span><span class='dsf dsf_obligation_type_" + id + " user_input'></span>" + (options.isEditable ? "<a href='javascript:void(0);' title='Supprimer le devoir'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" : "") + "</div>" + "<div><span>Valeur </span><span class='dsf dsf_obligation_magnitude_" + id + " user_input'></span></div>" + "<div><span>Notes </span><span class='dsf dsf_obligation_notes_" + id + " user_input'></span></div>" + "</li>" ); obligations.push(id); } } if (key.substring(0, 5).toLowerCase() === "criti") { if (criticals.indexOf(id) === -1) { $(".critical_injuries_container .critical_injury_list ul").append( "<li>" + "<div><span>Gravité </span><span class='dsf dsf_critical_injury_severity_" + id + " user_input'></span>" + (options.isEditable ? "<a href='javascript:void(0);' title='Supprimer la blessure critique'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" : "") + "</div>" + "<div><span>Résultat </span><span class='dsf dsf_critical_injury_result_" + id + " user_input'></span></div>" + "</li>" ); criticals.push(id); } } if (key.substring(0, 5).toLowerCase() === "talen") { if (talents.indexOf(id) === -1) { $(".talents_container table.talent tbody").append( "<tr>" + "<td>" + (options.isEditable ? "<a href='javascript:void(0);' title='Supprimer le talent ou la capacité spéciale'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" : "") + "</td>" + "<td>" + "<span class='dsf dsf_talent_name_" + id + " user_input'></span></td>" + "<td>" + "<span class='dsf dsf_talent_page_" + id + " user_input'></span></td>" + "<td>" + "<span class='dsf dsf_talent_summary_" + id + " user_input'></span></td></tr>" ); talents.push(id); } } }); for (i = 0; i < skills.Skills.ComSkill.length; i++) { var combatSkill = skills.Skills.ComSkill[i]; $(".skills .table.comskill").append( "<div class='tr' key='" + combatSkill.Key + "' stat='" + combatSkill.CharKey + "'>" + "<div class='td'>" + combatSkill.Name + " (" + combatSkill.CharName + ")" + "</div>" + "<div class='td'><span class='dsf dsf_skills_" + combatSkill.Key + "_career checkbox'></span></div>" + "<div class='td'><span class='dsf dsf_skills_" + combatSkill.Key + "_rank'>0</span></div>" + "<div class='td'><span class='dsf dsf_dicepool_" + combatSkill.Key + " readonly dice_pool_" + combatSkill.Key + "'></span></div>" + "</div>" ); } for (i = 0; i < skills.Skills.GenSkill.length; i++) { var generalSkill = skills.Skills.GenSkill[i]; $(".skills .table.genskill").append( "<div class='tr' key='" + generalSkill.Key + "' stat='" + generalSkill.CharKey + "'>" + "<div class='td'>" + generalSkill.Name + " (" + generalSkill.CharName + ")" + "</div>" + "<div class='td'><span class='dsf dsf_skills_" + generalSkill.Key + "_career checkbox'></span></div>" + "<div class='td'><span class='dsf dsf_skills_" + generalSkill.Key + "_rank'>0</span></div>" + "<div class='td'><span class='dsf dsf_dicepool_" + generalSkill.Key + " readonly dice_pool_" + generalSkill.Key + "'></span></div>" + "</div>" ); } for (i = 0; i < skills.Skills.KnoSkill.length; i++) { var knowlegdeSkill = skills.Skills.KnoSkill[i]; $(".skills .table.knoskill").append( "<div class='tr' key='" + knowlegdeSkill.Key + "' stat='" + knowlegdeSkill.CharKey + "'>" + "<div class='td'>" + knowlegdeSkill.Name + " (" + knowlegdeSkill.CharName + ")" + "</div>" + "<div class='td'><span class='dsf dsf_skills_" + knowlegdeSkill.Key + "_career checkbox'></span></div>" + "<div class='td'><span class='dsf dsf_skills_" + knowlegdeSkill.Key + "_rank'>0</span></div>" + "<div class='td'><span class='dsf dsf_dicepool_" + knowlegdeSkill.Key + " readonly dice_pool_" + knowlegdeSkill.Key + "'></span></div>" + "</div>" ); } if (options.isEditable) { //add new weapon $(".weapon th a").click(function () { var id = $(".weapon tr").length; $(".weapons table.weapon tbody").append( "<tr>" + "<td>" + (options.isEditable ? "<a href='javascript:void(0);' title='Supprimer l'arme'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" : "") + "</td>" + "<td>" + "<span class='dsf dsf_weapon_name_" + id + " user_input'>" + "</td>" + "<td>" + "<span class='dsf dsf_weapon_skill_" + id + " user_input'>" + "</td>" + "<td>" + "<span class='dsf dsf_weapon_damage_" + id + " user_input'>" + "</td>" + "<td>" + "<span class='dsf dsf_weapon_range_" + id + " user_input'>" + "</td>" + "<td>" + "<span class='dsf dsf_weapon_crit_" + id + " user_input'>" + "</td>" + "<td>" + "<span class='dsf dsf_weapon_special_" + id + " user_input'>" + "</td>" + "</tr>"); $(".dsf_weapon_name_" + id).parents("tr").find("a").click(function () { sw_edlr_removeTableListItem(this, options.containerId); }); aisleten.characters.bindAllFields("sw_edlr", options.containerId); }); //remove weapon $(".weapon td a").click(function () { sw_edlr_removeTableListItem(this, options.containerId); }); //add motivation $(".motivations .type .text a").click(function () { var id = $(".motivations_container .motivation_list ul li").length; $(".motivations_container .motivation_list ul").append( "<li>" + "<div><span>Type </span><span class='dsf dsf_motivation_type_" + (id + 1) + " user_input'></span>" + (options.isEditable ? "<a href='javascript:void(0);' title='Supprimer la motivation'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" : "") + "</div>" + "<div><span>Notes </span><span class='dsf dsf_motivation_notes_" + (id + 1) + " user_input'></span></div>" + "</li>"); $(".dsf_motivation_type_" + (id + 1)).parent().find("a").click(function () { sw_edlr_removeListItem(this, options.containerId); }); aisleten.characters.bindAllFields("sw_edlr", options.containerId); }); //remove motivation $(".motivations .motivation_list li div:first-child a").click(function () { sw_edlr_removeListItem(this, options.containerId); }); //add obligation $(".obligations .type .text a").click(function () { var id = $(".obligations_container .obligation_list ul li").length; $(".obligations_container .obligation_list ul").append( "<li>" + "<div><span>Type </span><span class='dsf dsf_obligation_type_" + (id + 1) + " user_input'></span>" + (options.isEditable ? "<a href='javascript:void(0);' title='Supprimer le devoir'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" : "") + "</div>" + "<div><span>Valeur </span><span class='dsf dsf_obligation_magnitude_" + (id + 1) + " user_input'></span></div>" + "<div><span>Notes </span><span class='dsf dsf_obligation_notes_" + (id + 1) + " user_input'></span></div>" + "</li>"); $(".dsf_obligation_type_" + (id + 1)).parent().find("a").click(function () { sw_edlr_removeListItem(this, options.containerId); }); aisleten.characters.bindAllFields("sw_edlr", options.containerId); }); //remove obligation $(".obligations .obligation_list li div:first-child a").click(function () { sw_edlr_removeListItem(this, options.containerId); }); //add criticals $(".critical_injuries .type .text a").click(function () { var id = $(".critical_injuries_container .critical_injury_list ul li").length; $(".critical_injuries_container .critical_injury_list ul").append( "<li>" + "<div><span>Gravité </span><span class='dsf dsf_critical_injury_severity_" + (id + 1) + " user_input'></span>" + (options.isEditable ? "<a href='javascript:void(0);' title='Supprimer la blessure critique'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" : "") + "</div>" + "<div><span>Résultat </span><span class='dsf dsf_critical_injury_result_" + (id + 1) + " user_input'></span></div>" + "</li>" ); $(".dsf_critical_injury_severity_" + (id + 1)).parent().find("a").click(function () { sw_edlr_removeListItem(this, options.containerId); }); aisleten.characters.bindAllFields("sw_edlr", options.containerId); }); //remove criticals $(".critical_injuries .critical_injury_list li div:first-child a").click(function () { sw_edlr_removeListItem(this, options.containerId); }); //add talents $(".talents .type .text a").click(function () { //var id = $(".sw_edlr_talents_container .sw_edlr_talent_list ul li").length; var id = $(".talents_container table.talent tbody tr").length; $(".talents_container table.talent tbody").append( "<tr>" + "<td>" + (options.isEditable ? "<a href='javascript:void(0);' title='Supprimer le talent ou la capacité spéciale'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" : "") + "</td>" + "<td>" + "<span class='dsf dsf_talent_name_" + (id + 1) + " user_input'></span></td>" + "<td>" + "<span class='dsf dsf_talent_page_" + (id + 1) + " user_input'></span></td>" + "<td>" + "<span class='dsf dsf_talent_summary_" + (id + 1) + " user_input'></span></td>" + "</tr>"); $(".dsf_talent_name_" + (id + 1)).parents("tr").find("a").click(function () { sw_edlr_removeTableListItem(this, options.containerId); }); aisleten.characters.bindAllFields("sw_edlr", options.containerId); }); //remove talents $(".talents table.talent tbody tr td:first-child a").click(function () { sw_edlr_removeTableListItem(this, options.containerId); }); } } // Data Change function sw_edlr_dataChange(options) { var i, key, stat_key, rank_raw, rank, stat_raw, stat, green, yellow, skill_key; // Called immediately after a data value is changed. //alert("dataChange. " + options['fieldName'] + " = " + options['fieldValue']); // Here, we use it to help with calculating the ability modifiers if the level or // base ability score changes. var field = options['fieldName']; var val = options['fieldValue']; switch (field.substring(0, 5).toLowerCase()) { case "skill": //calculate dice pool if (field.substring(field.lastIndexOf("_") + 1).toLowerCase() == "rank") { key = $(".dsf_" + field).parents(".tr").attr("key"); stat_key = $(".dsf_" + field).parents(".tr").attr("stat"); rank_raw = $(".dsf_skills_" + key + "_rank").text(); rank = isNaN(rank_raw) | rank_raw == "" ? 0 : parseInt(rank_raw, 10); stat_raw = $("[key='" + stat_key + "'] .dsf").text(); stat = isNaN(stat_raw) | stat_raw == "" ? 0 : parseInt(stat_raw, 10); //alert("key " + key +"stat_key " + stat_key + " rank " + rank_raw); green = stat > rank ? stat - rank : rank - stat; yellow = stat > rank ? rank : stat; $(".dice_pool_" + key).html(""); for (i = 0; i < green; i++) { $(".dice_pool_" + key).append('<li class="green"></li>'); } for (i = 0; i < yellow; i++) { $(".dice_pool_" + key).append('<li class="yellow"></li>'); } } break; default: //Check for stat change to calculate dice pools if ($(".dsf_" + field).parents(".stat_block").length > 0) { stat_key = $(".dsf_" + field).parents(".stat_block").attr("key"); $(".skilltable .tr[stat='" + stat_key + "']").each(function () { skill_key = $(this).attr("key"); //alert("dataChange. " + $(this).attr("sw_edlr_key")); rank_raw = $(".dsf_skills_" + skill_key + "_rank").text(); rank = isNaN(rank_raw) ? 0 : parseInt(rank_raw, 10); stat_raw = val; stat = isNaN(stat_raw) ? 0 : parseInt(stat_raw, 10); green = stat > rank ? stat - rank : rank - stat; yellow = stat > rank ? rank : stat; $(".dice_pool_" + skill_key).html(""); for (i = 0; i < green; i++) { $(".dice_pool_" + skill_key).append('<li class="green"></li>'); } for (i = 0; i < yellow; i++) { $(".dice_pool_" + skill_key).append('<li class="yellow"></li>'); } }); } break; } } // remove li-based items function sw_edlr_removeListItem(i, containerId) { var ul = $(i).parents("ul"); //remove row $(i).parents("li").remove(); //renumber controls $(ul).find("li").each(function (index) { $(this).find(".dsf").each(function () { var css = $(this).attr("class"); $(this).attr("class", css.substring(0, css.lastIndexOf("_") + 1) + (index + 1)); }); }); } // remove table row-based itens function sw_edlr_removeTableListItem(i, containerId) { var table = $(i).parents("table"); //remove row $(i).parents("tr").remove(); //renumber controls $(table).find("tbody tr").each(function (index) { //get original index $(this).find("td .dsf").each(function () { var css = $(this).attr("class"); $(this).attr("class", css.substring(0, css.lastIndexOf("_") + 1) + (index + 1)); }); }); } // Process import select function sw_edlr_processimport(e) { var file = e.target.result, results; if (file && file.length) { results = sw_edlr_x2js.xml_str2json(file); sw_edlr_parseinput(results); } } // Process data from import file function sw_edlr_parseinput(e) { var i; $(".dsf_species").text(e.Character.Species.SpeciesKey); $(".dsf_career").text(e.Character.Career.CareerKey); //$(".dsf_specializations").text(e.Character.Career.StartingSpecKey); $(".dsf_soak_w").text(sw_edlr_calculateValueFromObject(e.Character.Attributes.SoakValue)); $(".dsf_wound").text(sw_edlr_calculateValueFromObject(e.Character.Attributes.WoundThreshold)); $(".dsf_strain").text(sw_edlr_calculateValueFromObject(e.Character.Attributes.StrainThreshold)); $(".dsf_ranged_def").text(sw_edlr_calculateValueFromObject(e.Character.Attributes.DefenseRanged)); $(".dsf_melee_def").text(sw_edlr_calculateValueFromObject(e.Character.Attributes.DefenseMelee)); $(".dsf_brawn").text(sw_edlr_calculateValueFromObject(e.Character.Characteristics.CharCharacteristic[0].Rank)); $(".dsf_aglity").text(sw_edlr_calculateValueFromObject(e.Character.Characteristics.CharCharacteristic[1].Rank)); $(".dsf_intellect").text(sw_edlr_calculateValueFromObject(e.Character.Characteristics.CharCharacteristic[2].Rank)); $(".dsf_cunning").text(sw_edlr_calculateValueFromObject(e.Character.Characteristics.CharCharacteristic[3].Rank)); $(".dsf_willpower").text(sw_edlr_calculateValueFromObject(e.Character.Characteristics.CharCharacteristic[4].Rank)); $(".dsf_presence").text(sw_edlr_calculateValueFromObject(e.Character.Characteristics.CharCharacteristic[5].Rank)); $.each(e.Character.Skills.CharSkill, function (index, skill) { $(".dsf_skills_" + skill.Key + "_career :checkbox").val(skill.isCareer == "true" ? 1 : 0); $(".dsf_skills_" + skill.Key + "_career :checkbox").prop("checked", skill.isCareer == "true" ? true : false); $(".dsf_skills_" + skill.Key + "_rank").text(sw_edlr_calculateValueFromObject(skill.Rank)); }); $(".weapons table.weapon tbody").html(""); $.each(e.Character.Weapons.CharWeapon, function (index, weapon) { var item = $.grep(sw_edlr_weapons.Weapons.Weapon, function (obj) { return obj.Key == weapon.ItemKey; }); var skill = $.grep(skills.Skills.Skill, function (obj) { if (item.length > 0) { return obj.Key == item[0].SkillKey; } }); var qualities = []; if (typeof item[0] != "undefined") { if (typeof item[0].Qualities != "undefined") { $.each(item[0].Qualities.Quality, function (index, quality) { var descriptor = $.grep(sw_edlr_descriptors.ItemDescriptors.ItemDescriptor, function (obj) { if (typeof quality.Key != "undefined") { return obj.Key == quality.Key; } else if (typeof quality != "undefined") { return obj.Key == quality; } }); if (typeof descriptor != "undefined" && descriptor.length > 0) { if (descriptor[0].QualDesc.indexOf("{0}") > -1) { qualities.push(descriptor[0].QualDesc.replace("{0}", quality.Count)); } else { qualities.push(descriptor[0].QualDesc); } } }); } } var id = $(".sw_edlr_weapon tr").length; if (item.length > 0) { $(".sw_edlr_weapons table.sw_edlr_weapon tbody").append( "<tr>" + "<td>" + "<a href='javascript:void(0);' title='Supprimer l'arme'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" + "</td>" + "<td>" + "<span class='dsf dsf_weapon_name_" + id + " user_input'>" + item[0].Name + "</td>" + "<td>" + "<span class='dsf dsf_weapon_skill_" + id + " user_input'>" + skill[0].Name + "</td>" + "<td>" + "<span class='dsf dsf_weapon_damage_" + id + " user_input'>" + item[0].Damage + "</td>" + "<td>" + "<span class='dsf dsf_weapon_range_" + id + " user_input'>" + item[0].Range + "</td>" + "<td>" + "<span class='dsf dsf_weapon_crit_" + id + " user_input'>" + item[0].Crit + "</td>" + "<td>" + "<span class='dsf dsf_weapon_special_" + id + " user_input'>" + qualities.join(", ") + "</td>" + "</tr>"); $(".dsf_weapon_name_" + id).parents("tr").find("a").click(function () { sw_edlr_removeTableListItem(this, sw_edlr_options.containerId); }); } }); var totalXP = sw_edlr_calculateValueFromObject(e.Character.Experience.ExperienceRanks); var usedXP = parseInt(e.Character.Experience.UsedExperience); $(".dsf_earned_xp").text(totalXP); $(".dsf_unspent_xp").text(totalXP - usedXP); $(".sw_edlr_motivations_container .sw_edlr_motivation_list ul").html(""); if ($.isArray(e.Character.Motivations.CharMotivation)) { $.each(e.Character.Motivations.CharMotivation, function (index, motivation) { var id = $(".sw_edlr_motivations_container .sw_edlr_motivation_list ul li").length; var item = motivation; if ($.isArray(motivation)) { item = motivation[0]; } $(".sw_edlr_motivations_container .sw_edlr_motivation_list ul").append( "<li>" + "<div><span>Type </span><span class='dsf dsf_motivation_type_" + (id + 1) + " user_input'>" + item.Name + "</span>" + "<a href='javascript:void(0);' title='Supprimer la motivation'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" + "</div>" + "<div><span>Notes </span><span class='dsf dsf_motivation_notes_" + (id + 1) + " user_input'>" + item.Notes + "</span></div>" + "</li>"); $(".dsf_motivation_type_" + (id + 1)).parent().find("a").click(function () { sw_edlr_removeListItem(this, sw_edlr_options.containerId); }); }); } else { var id = $(".sw_edlr_motivations_container .sw_edlr_motivation_list ul li").length; var item = e.Character.Motivations.CharMotivation; if (typeof item != "undefined") { $(".sw_edlr_motivations_container .sw_edlr_motivation_list ul").append( "<li>" + "<div><span>Type </span><span class='dsf dsf_motivation_type_" + (id + 1) + " user_input'>" + item.Name + "</span>" + "<a href='javascript:void(0);' title='Supprimer la motivation'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" + "</div>" + "<div><span>Notes </span><span class='dsf dsf_motivation_notes_" + (id + 1) + " user_input'>" + item.Notes + "</span></div>" + "</li>"); $(".dsf_motivation_type_" + (id + 1)).parent().find("a").click(function () { sw_edlr_removeListItem(this, sw_edlr_options.containerId); }); } } $(".sw_edlr_obligations_container .sw_edlr_obligation_list ul").html(""); if ($.isArray(e.Character.Obligations.CharObligation)) { $.each(e.Character.Obligations.CharObligation, function (index, obligation) { var id = $(".sw_edlr_obligations_container .sw_edlr_obligation_list ul li").length; var item = obligation; if ($.isArray(obligation)) { item = obligation[0]; } $(".sw_edlr_obligations_container .sw_edlr_obligation_list ul").append( "<li>" + "<div><span>Type </span><span class='dsf dsf_obligation_type_" + (id + 1) + " user_input'>" + item.Name + "</span>" + "<a href='javascript:void(0);' title='Supprimer le devoir'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" + "</div>" + "<div><span>Valeur </span><span class='dsf dsf_obligation_magnitude_" + (id + 1) + " user_input'>" + item.Size + "</span></div>" + "<div><span>Notes </span><span class='dsf dsf_obligation_notes_" + (id + 1) + " user_input'>" + item.Notes + "</span></div>" + "</li>"); $(".dsf_obligation_type_" + (id + 1)).parent().find("a").click(function () { sw_edlr_removeListItem(this, sw_edlr_options.containerId); }); }); } else { var id = $(".sw_edlr_obligations_container .sw_edlr_obligation_list ul li").length; var item = e.Character.Obligations.CharObligation; if (typeof item != "undefined") { $(".sw_edlr_obligations_container .sw_edlr_obligation_list ul").append( "<li>" + "<div><span>Type </span><span class='dsf dsf_obligation_type_" + (id + 1) + " user_input'>" + item.Name + "</span>" + "<a href='javascript:void(0);' title='Supprimer le devoir'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" + "</div>" + "<div><span>Valeur </span><span class='dsf dsf_obligation_magnitude_" + (id + 1) + " user_input'>" + item.Size + "</span></div>" + "<div><span>Notes </span><span class='dsf dsf_obligation_notes_" + (id + 1) + " user_input'>" + item.Notes + "</span></div>" + "</li>"); $(".dsf_obligation_type_" + (id + 1)).parent().find("a").click(function () { sw_edlr_removeListItem(this, sw_edlr_options.containerId); }); } } $(".dsf_gender").text(e.Character.Description.Gender); $(".dsf_age").text(e.Character.Description.Age); $(".dsf_height").text(e.Character.Description.Height); $(".dsf_build").text(e.Character.Description.Build); $(".dsf_hair").text(e.Character.Description.Hair); $(".dsf_eyes").text(e.Character.Description.Eyes); $(".dsf_notable").text(e.Character.Description.OtherFeatures); $(".dsf_credits").text(e.Character.Credits); var armorlist = []; if ($.isArray(e.Character.Armor.CharArmor)) { $.each(e.Character.Armor.CharArmor, function (index, armor) { var item = $.grep(sw_edlr_armors.Armors.Armor, function (obj) { return obj.Key == armor.ItemKey; }); armorlist.push(item.Name); }); } else { if (e.Character.Armor != "") { var item = $.grep(sw_edlr_armors.Armors.Armor, function (obj) { return obj.Key == e.Character.Armor.CharArmor.ItemKey; }); armorlist.push(item.Name); } } $(".dsf_weapons_and_armor").text(armorlist.join(", ")); var gearlist = []; if ($.isArray(e.Character.Gear.CharGear)) { $.each(e.Character.Gear.CharGear, function (index, gear) { var item = $.grep(sw_edlr_gears.Gears.Gear, function (obj) { return obj.Key == gear.ItemKey; }); gearlist.push(item[0].Name); }); } else { if (e.Character.Gear != "") { var item = $.grep(sw_edlr_gears.Gears.Gear, function (obj) { return obj.Key == e.Character.Gear.CharGear.ItemKey; }); gearlist.push(item.Name); } } $(".dsf_personal_gear").text(gearlist.join(", ")); var specializations = []; $(".talents_container table.talent tbody").html(""); if ($.isArray(e.Character.Specializations.CharSpecialization)) { $.each(e.Character.Specializations.CharSpecialization, function (index, chartalent) { specializations.push(chartalent.Name); $.each(chartalent.Talents.CharTalent, function (index, talentobj) { if (talentobj.Free == "true" || talentobj.Purchased == "true") { var item = $.grep(sw_edlr_talents.Talents.Talent, function (obj) { return obj.Key == talentobj.Key; }); if (item.length > 0) { var id = $(".talents_container table.talent tbody tr").length; $(".talents_container table.talent tbody").append( "<tr>" + "<td>" + "<a href='javascript:void(0);' title='Supprimer le talent ou la capacité spéciale'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" + "</td>" + "<td>" + "<span class='dsf dsf_talent_name_" + (id + 1) + " user_input'>" + item[0].Name + "</span></td>" + "<td>" + "<span class='dsf dsf_talent_page_" + (id + 1) + " user_input'></span></td>" + "<td>" + "<span class='dsf dsf_talent_summary_" + (id + 1) + " user_input'>" + item[0].Description + "</span></td>" + "</tr>"); $(".dsf_talent_name_" + (id + 1)).parents("tr").find("a").click(function () { sw_edlr_removeTableListItem(this, sw_edlr_options.containerId); }); } } }); }); } else { var chartalent = e.Character.Specializations.CharSpecialization; specializations.push(chartalent.Name); $.each(chartalent.Talents.CharTalent, function (index, talentobj) { if (talentobj.Free == "true" || talentobj.Purchased == "true") { var item = $.grep(sw_edlr_talents.Talents.Talent, function (obj) { return obj.Key == talentobj.Key; }); if (item.length > 0) { var id = $(".talents_container table.talent tbody tr").length; $(".talents_container table.talent tbody").append( "<tr>" + "<td>" + "<a href='javascript:void(0);' title='Supprimer le talent ou la capacité spéciale'><img src='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAB3RJTUUH3wgeATEhJPwS7AAAAAlwSFlzAAAK8AAACvABQqw0mAAAAx9JREFUeNpj/P//PwM1ARNVTQMCFhjj9o0bem9vXCtiY2JiE9c3nCctL78PKPyPkP6P7965PDh71vvSmdP3fDIyJzGCvHzx7FlNpc/vznJ//8L5/+Uzhr8vnv4/zyOyUSchLZubh+cZNp+9fvo05M3mzY0Pz51h2/PtR3tITs5KMzOzz2AD7965w3Ng5vTJ4SrSMRyf3rD8f3Kf4f/jOwz3/nE8Zm2fFaasqXkCZtKvnz9Vr86aNZ197x77xZ8+z7QuLGx1dXN7zs7ODlEAMhCEv379yrRiwQLjFeH+Wz77m/79ZCb9/6Uq7/+rWtIfzxw86AFUw3T7zOn089aWn3crKbwtT0iIef78OStMPwwzoAt8+vSJeVF/r/duDZlr98XZ/98UYPl/Ulzo857cnB1nuTn/LefleTChrc3u27dvjOh6sRoIw48fP+abGR3ZfZqL5dc5Fsb/pxkZ/i/i472zfPFivd+/f+PUhzPZyMjIfLIvKdv5lUfg258/IMUMDGKMDAKqqqo/WVhYGHACXDad2LIl6jg/3/dTQCWLRIRvrVFTuXaFm/n/cl31Ey9fvuTCpQ+r4N6FC1NPsLH9ARm2jo/32Y4tWwxePH8uttnD8ehzec7/U2IjWv/8+UNcGO5esiTsBAvLnzNMDP+PsjP/XDxlSghM88ePH4UPhHuefqTF+23dsqVGBA08deiQ/iFOji9nmRn/X+Rg+j85Pm7i9+/fUZLGh/fvpc/72txfrKe4F+h1FpwGfvnyhWmlqsrJ82yM/68Cw2qFvualp0+fimBzxZP7963umih96y0pDvj37x92A1fPmuVwTUnm3w0h9v/XJLn/7N261QNXwIPwhW1b6hYoiB9+9OgRC9Zk8/ryJUt+EwNGPiVphn8Swj8NLS3P4ysV9Dy8urQ8fXk2rlihgbX4+svJ+Y7PxJCB31if4ZucwntWVtYf+AxkZGT8odLUnvvzxQtVkLfh4rAC9sSxY8I/N606psPFrLSHT7opNK+glYmJiVDxxfDjxw8WDg6OP1gT9t27d/nPnDql9fPnTzZ84YcPw11ILQAANFSl+WXVtCYAAAAASUVORK5CYII=' /></a>" + "</td>" + "<td>" + "<span class='dsf dsf_talent_name_" + (id + 1) + " user_input'>" + item[0].Name + "</span></td>" + "<td>" + "<span class='dsf dsf_talent_page_" + (id + 1) + " user_input'></span></td>" + "<td>" + "<span class='dsf dsf_talent_summary_" + (id + 1) + " user_input'>" + item[0].Description + "</span></td>" + "<td>" + "<span class='dsf dsf_talent_summary_" + (id + 1) + " user_input'>" + item[0].Description + "</span></td>" + "</tr>"); $(".dsf_talent_name_" + (id + 1)).parents("tr").find("a").click(function () { sw_edlr_removeTableListItem(this, sw_edlr_options.containerId); }); } } }); } $(".dsf_specializations").text(specializations.join(", ")); $(".skills .tr").each(function () { var key = $(this).attr("key"); var stat_key = $(this).attr("stat"); var rank_raw = $(".dsf_skills_" + key + "_rank").text(); var rank = isNaN(rank_raw) | rank_raw == "" ? 0 : parseInt(rank_raw, 10); var stat_raw = $("[key='" + stat_key + "'] .dsf").text(); var stat = isNaN(stat_raw) | stat_raw == "" ? 0 : parseInt(stat_raw, 10); var green = stat > rank ? stat - rank : rank - stat; var yellow = stat > rank ? rank : stat; $(".dice_pool_" + key).html(""); for (i = 0; i < green; i++) { $(".dice_pool_" + key).append('<li class="green"></li>'); } for (i = 0; i < yellow; i++) { $(".dice_pool_" + key).append('<li class="yellow"></li>'); } }); aisleten.characters.bindAllFields("sw_edlr", sw_edlr_options.containerId); } // Calculates value from child objects function sw_edlr_calculateValueFromObject(e) { var rank = 0; $.each(e, function (key, value) { var subrank = isNaN(value) || value == "" ? 0 : parseInt(value, 10); rank += subrank; }); return rank; } // Tab switching function function sw_edlr_tabClick(oTab, sPageClass) { // Abort if already on the selected tab var oPage = sw_edlr_getElementsByClassName('page_' + sPageClass)[0]; if (oPage.style.display != 'none') return; // Set the length of the shorter page to match the longer page var oPages = sw_edlr_getElementsByClassName('main'); var iHeight = 0; for (var i = 0; i < oPages.length; i++) { if (oPages[i].offsetHeight > iHeight) iHeight = oPages[i].offsetHeight; } for (var n = 0; n < oPages.length; n++) { oPages[n].style.minHeight = (iHeight - 140) + 'px'; } // Show the proper pages and tabs if (sPageClass == 'sheet') { oTab.parentNode.style.backgroundImage = "url(https://chainsawxiv.github.io/DST/common/images/misc/switch2.png)"; sw_edlr_getElementsByClassName('page_sheet')[0].style.display = 'block'; sw_edlr_getElementsByClassName('page_bio')[0].style.display = 'none'; } else { oTab.parentNode.style.backgroundImage = "url(https://chainsawxiv.github.io/DST/common/images/misc/switch1.png)"; sw_edlr_getElementsByClassName('page_bio')[0].style.display = 'block'; sw_edlr_getElementsByClassName('page_sheet')[0].style.display = 'none'; } } /////////////////////////////////////////////////// // General Utility Functions ////////////////////// /////////////////////////////////////////////////// // Global Storage sw_edlr_context = {}; // Gets an array of elements with a particular class from the context function sw_edlr_getElementsByClassName(sClassName, sElementType) { // Provide default element type if (!sElementType) sElementType = 'div'; var aList = new Array(); var aDivs = sw_edlr_context.getElementsByTagName(sElementType); for (var i = 0; i < aDivs.length; i++) { if (aDivs[i].className.match(sClassName)) aList[aList.length] = aDivs[i]; } return aList; } // Called immediately after the script fills the Span fields with data, before ateamtable attachement function sw_edlr_dataPostLoad(opts) { // Store global context for search by class name sw_edlr_context = document.getElementById(opts['containerId']); }
Submit Notes
This is a french version of the Star Wars : Age of Rebellion character sheet by BlueEyedFireDragon and barrelv, with some graphical adjustments. Version française de la feuille de personnage pour Star Wars : L’Ère de la Rébellion de BlueEyedFireDragon et barrelv, avec quelques ajustements graphiques.
Back