Character Sheet Phase 2 (Savage): Difference between revisions
Line 70: | Line 70: | ||
===Skills=== | ===Skills=== | ||
Now that the swap is completed, we can resume with the next section on the left side, which happens to be skills. We'll handle skills the same way that we did attributes, using a two-column table and showing the die-type and adjustment for each skill. However, there is an | Now that the swap is completed, we can resume with the next section on the left side, which happens to be skills. We'll handle skills the same way that we did attributes, using a two-column table and showing the die-type and adjustment for each skill. However, there is an important wrinkle with skills. We have to handle the knowledge skills specially, since we need to show the domain for those skills, and that means we can't use a two-column format for those skills. | ||
We start by modifying the existing "oSkills" portal to | The simplest solution is to create a second table portal that is the same as the standard portal for skills, with the key difference being a one-column format. Obviously, we also need to use a different List tag expression in each, with one table listing the non-knowledge skills and the other listing only the knowledge skills. | ||
We'll start by modifying the existing "oSkills" portal to properly display all skills in the two-column format. We can copy the portal for use with knowledge skills and give it the id "oKnowledge". This portal then specifies a single column. Now we need to figure out how to differentiate between the knowledge skills and non-knowledge skills. | |||
For the "oSkills" portal, the only thing we need to change for | |||
===Racial Abilities=== | ===Racial Abilities=== |
Revision as of 23:11, 16 January 2009
Context: HL Kit … Authoring Examples … Savage Worlds Walk-Through
Overview
Our character sheet is starting to come together. We've got some of the most basic sections in place and we've got some momentum going, so we'll keep on rolling.
Swapping Sections Around
At this point, we need to make some structural adjustments to the sheet provided with the Skeleton files. We want to use the skills and special abilities sections, but they are currently shown in the righthand column. Similarly, armor and weapons are on the left, but we want to show them on the right. So the next thing we'll do is move these sections around, after which we can resume editing the individual sections.
Armor and weapons are both encapsulated by the "oArmory" layout, so we can move both of those at the same time by moving the layout. There are some interesting wrinkles associated with this layout that we'll need to deal with at some point, but we don't need to worry about them now. The "oArmory" layout is managed directly by the sheet, so we can move it to the right column within the Position script of the sheet. We'll have to fix this later, but for now we'll just move it to the bottom on the right side of the sheet. This is accomplished by moving the code that positions the layout to the end of the script and revising it properly for being at the bottom on the right. The new code should look like below.
~position the armory layout within the remaining space on the right layout[oArmory].width = colwidth layout[oArmory].top = layout[oRightSide].bottom + global[sectiongap] layout[oArmory].left = layout[oLogos].left layout[oArmory].height = extent - global[sectiongap] - layout[oArmory].top perform layout[oArmory].render
The next thing we need to do is move the skills and abilities sections from the right side to the left side. Fortunately, doing this is extremely easy. The skills and abilities are both handled via separate table portals. Both of these portals are currently managed within the "oRightSide" layout and positioned via the "autoplace" mechanism. Consequently, all we need to do is move them into the "oLeftSide" layout and place them properly within the new Position script.
Within the "oRightSide" layout, delete the two "portalref" elements for the "oAbility" and "oSkills" portals. Now go to the "oLeftSide" layout and add the elements there. Return to the "oRightSide" layout and delete the two "autoplace" operations on the portals we just removed. Then go to the "oLeftSide" layout and insert the two lines of code into the Position script there. When you're done, the two revised layouts should look like the below.
<layout id="oLeftSide"> <portalref portal="oHeroName"/> <portalref portal="oHeroInfo"/> <portalref portal="oAttribute"/> <portalref portal="oDerived"/> <portalref portal="oSkills"/> <portalref portal="oAbility"/> <position><![CDATA[ ~position the hero name at the top with the hero details beneath the name perform portal[oHeroName].autoplace[0] perform portal[oHeroInfo].autoplace[15] ~position the tables next perform portal[oAttribute].autoplace perform portal[oDerived].autoplace perform portal[oSkills].autoplace perform portal[oAbility].autoplace ~our layout height is the extent of the elements within height = autotop ]]></position> </layout>
<layout id="oRightSide"> <portalref portal="oGear"/> <templateref template="oPortrait" thing="actor"/> <position><![CDATA[ ~position the character portrait at the top and the various tables beneath perform template[oPortrait].autoplace perform portal[oGear].autoplace ~our layout height is the extent of the elements within height = autotop ]]></position> </layout>
That's all there is to it. Reload the data files and preview the character. Everything has now been swapped the way we intended.
Skills
Now that the swap is completed, we can resume with the next section on the left side, which happens to be skills. We'll handle skills the same way that we did attributes, using a two-column table and showing the die-type and adjustment for each skill. However, there is an important wrinkle with skills. We have to handle the knowledge skills specially, since we need to show the domain for those skills, and that means we can't use a two-column format for those skills.
The simplest solution is to create a second table portal that is the same as the standard portal for skills, with the key difference being a one-column format. Obviously, we also need to use a different List tag expression in each, with one table listing the non-knowledge skills and the other listing only the knowledge skills.
We'll start by modifying the existing "oSkills" portal to properly display all skills in the two-column format. We can copy the portal for use with knowledge skills and give it the id "oKnowledge". This portal then specifies a single column. Now we need to figure out how to differentiate between the knowledge skills and non-knowledge skills.
For the "oSkills" portal, the only thing we need to change for