Do I actually need a Gizmo? - Skill Specialties
Still working on Planet Mercenary. I'm back to the Skill Specializations. Almost every skill has a series of Specializations that can be bootstrapped, bought by the user at creation, or bought during advancement. There's some overlap in specializations (Beam can be applied to six of the gun skills. Projectile applies to five of them, for example). A user may buy as many specialties associated with a skill as he has ranks in that skill (so someone with Pistols 2 could buy Beam and Projectile, but not also Non-Lethal). Most specialties are unique, but a few (which require one to apply a custom domain) repeat.
Initially, based on TCArknight's work on Doctor Who, I assumed that I'd need Gizmos, with the Specialties associated with the Skills, but the Specialties are really on the Hero, right? Or do I still need the Gizmo, since I want to be able to click on a button on the Skill and bring up the dialog to add specialties particular to that Skill? What I have right now brings up a list of all specialties with the button (with an error message of "Attempt to retrieve candidate tagexpr from non-existent pick 'SpecHelp'" every time I bring up the form or confirm a choice), but it does add the specialty to the Hero such that I can display it in the listing. And I am able to bootstrap the specialty as part of the various Background choices. Still, I'd like to restrict the list to only specialties associated with the skill, not display the dialog if there are no choices that can be made, and at least flag if there are more specialties than ranks. Here is what I believe is the relevant code: Procedures.dat Code:
<!-- Script used to set up Specialty selection Code:
<!-- Skill component Code:
<document signature="Hero Lab Data"> Code:
<!-- Carbine Skill --> Code:
<!-- Carbine Beam Skill Specialty --> |
I know I have a wall of text here, but I really wasn't certain what to leave off. Right now, I'm displaying specialties in two places, a separate Specialties tab and on the Skills panel. The edit is a form invoke on the Skills tab. If you'd like, I can provide the code for that.
I'm fairly certain I'm missing some small step here, but I can't seem to make the leap on my own. |
I think this is where missing something:
You've got: Quote:
Quote:
|
I tried that. I was getting the error you posted about in your thread with the quadruple checkmark to which Matthias suggested the empty string.
|
Quote:
Make sure on your helper object you define a candidate tag expression field, thats the purpose of candidatefield="". You have to define the candidate field if you use this. This will come in handy for many things later on. Make sure the headerpick is on there too. |
I worked on some other bits while trying to wrap my head around this. I'm still getting the "Attempt to retrieve candidate tagexpr from non-existent pick 'SpecHelp'" message even though I added an addpick expression:
Code:
<portal Possibly relevant, I was trying to add the code to assign a "User.HasSpec" tag to the parent skill, as per the Doctor Who code, but I get an error saying that I'm trying to access a non-existent parent pick for a top-level container on that "assign" bit, which makes me think that I'm still not adding this in the right place. Code:
<!-- Track the ability on the actor --> |
OK, I figured out part of what I was doing wrong. I was using the "Form" action instead of "Edit". Now I'm just down to
Quote:
|
Oh, and I "fixed" the "headertitle" error by removing the heading of the table until I understand that correctly. CP charging works.
Now, I've got the trickier bit. A character can have only as many specialties as they have ranks in the skill. I plan to add that to the validation logic, because it's useful for the user to be able to edit it to remove items or change the domain of the two skills. The condition for not showing the Edit button for the Specialties are if the user has no ranks in the skill, and no specialties, which I know how to check for, and whether there exist Specialties that correspond to the skill (there are a handful where you can't get a Specialty currently) and I just can't seem to wrap my brain how to write the condition. I know how to iterate through the values and display the matching items, but is there a way to just get a count of matching items? Or the existence thereof? Code:
var myId as string |
Currently, the following code works in the Skill Component, but seems slightly wasteful:
Code:
<!-- Set the value for whether to display the specialty button --> |
All times are GMT -8. The time now is 07:58 AM. |
Powered by vBulletin® - Copyright ©2000 - 2024, vBulletin Solutions, Inc.
wolflair.com copyright ©1998-2016 Lone Wolf Development, Inc. View our Privacy Policy here.