View Single Post
Duggan
Senior Member
Volunteer Data File Contributor
 
Join Date: Nov 2009
Posts: 1,502

Old January 31st, 2018, 07:47 PM
I'm still wrapping my head around a lot of things. In Planet Mercenary, each player has three fireteam members, basically a squad that follows him and takes orders. Each fireteam member has a role, something like "Specialist" or "Officer-in-Training" and five skills, Combat, Physical, Mental, Social, and Damage. The role is partly cosmetic and partly determines which skills can be chosen for that fireteam member (for example, a Specialist gets +1 Mental and +1 to another skill that isn't Damage). The skills chose can be doubled up, so a Specialist might have +2 Mental, or an Officer-in-Training might have +2 Social.

Currently, each fireteam member has fields that contain the values for those five skills, and a field for their name. I would like to be able to edit those Fireteam members to set a role, and then the two skills that they can pick based on that role (although I'm currently ignoring the role and working toward letting the user select two skills. I figure I can then refine it to the role setup), and then be able to edit additional details for players who want more info on their Fireteam members (race, biography, etc).

First off, I'm finding myself going back and forth on how to handle the skill bonuses. Since they're user-selected, I'm considering setting each member up with a Gizmo, creating a component/compset for the skills, and then "things" for each of the five skills, and letting a Chooser Table add them to the Fireteam member, either on the Fireteam Tab (which would show the aggregate value of adding up the skill values for each of the team members, then have individual entries below) or using a separate Form (so that the user would use the name and skill values in a table, then could click on a Configure button to actually set details).

Right now, my approach is to set up an FTSkill component/autocompset, and then have "thing" entries for the five skills which have an "eval" to increment the relevant fields on their parent, if present. I'm still trying to set that up, so I don't have code. But that seems kind of ugly and hacky for something working on a set list of skills, which also exist as fields on another thing. I also find myself trying to think through how to set things up so that a particular role has two sets of choices that can be set up.

*wry grin* And, I guess, after that, the user interface for it? Long story short, my brain is just not twisting the direction I need on this. Does it make sense to just add instances onto that Fireteam member representing the Skill Bonus and then total them up instead of storing a Field? Or should the field do that count maybe?

Under assumptions that I feel are safe:
  • The list of skills won't change for the Fireteam members
  • It's reasonably safe to go with there only ever being a fixed number of Fireteam members (in the game, it is possible to have more of them with certain cards, or for some of them to be "Probies" that offer no bonus)
  • Every "role" only offers the ability to boost two skills, and the two skills don't inter-connect such that we need to worry about them being distinct from each other, although they might have different rules

Anyhow, I'm going to keep plugging away, and I'll provide what code I have as I refine my idea, but I want to put it out here.

Code:
<component 
  id="FTMember"
  name="Fireteam Member"
  autocompset="no"
  panellink="ftPanel">
  
  <!-- In-play bonuses applied to the trait -->
  <field
    id="ftName"
    name="Fireteam member name"
    type="user"
    maxlength="200">
    </field>
 
  <field
    id="ftPhysical"
    name="Fireteam physical skill"
    type="derived">
    </field>
  
  <field
    id="ftMental"
    name="Fireteam mental skill"
    type="derived">
    </field>
    
  <field
    id="ftSocial"
    name="Fireteam social skill"
    type="derived">
    </field>
    
  <field
    id="ftCombat"
    name="Fireteam combat skill"
    type="derived">
    </field>
  
  <field
    id="ftDamage"
    name="Fireteam damage"
    type="derived"
    defvalue="1">
    </field>
    
  <field
    id="ftComDam"
    name="Combat and Damage"
    type="static"
    maxfinal="10">
    <finalize><![CDATA[
      ~Displays name
      @text = field[ftCombat].value & " (" & field[ftDamage].value & "d6)"
      ]]></finalize>
    </field>
  
  <field
    id="ftNotes"
    name="Fireteam notes"
    type="user">
    </field>    
  </component>
Code:
<!-- Fireteam -->
<compset
  id="FTMember">
  <compref component="FTMember"/>
  </compset>
Code:
<!-- Fireteam Thing -->
<thing
  id="Fireteam"
  name="Fireteam member"
  compset="FTMember"
  isunique="no"
  description="This is a fireteam entry.">
  <child entity="ftDetails"/>
  </thing>
Duggan is offline   #1 Reply With Quote