Having some trouble figuring this one out.
I'm doing a ruleset for Qin the Warring States. Weapon skills can have combat techniques associated with them, but they are not required.
So, I have an entity defined that I attach to weapon skills as gizmos, and the pick template in the skills tab has an edit action button associated with it. I also have a form which includes the Combat Technique compset. Everything is working as it should except for the fact that when the a skill is added to the skill tab, the form to choose a combat technique automatically pops up. If I cancel out of the form without picking a combat technique, the Skill pick is deleted after the combat technique form closes.
If I select a combat technique, everything works fine. My question is: can I change the behavior whereby the Combat Technique form appears automatically when the Skill pick (which has the gizmo) is picked? Ideally, I'd like to be able to add a Skill pick without the combat technique form coming up automatically.
Thanks in advance!
I'm doing a ruleset for Qin the Warring States. Weapon skills can have combat techniques associated with them, but they are not required.
So, I have an entity defined that I attach to weapon skills as gizmos, and the pick template in the skills tab has an edit action button associated with it. I also have a form which includes the Combat Technique compset. Everything is working as it should except for the fact that when the a skill is added to the skill tab, the form to choose a combat technique automatically pops up. If I cancel out of the form without picking a combat technique, the Skill pick is deleted after the combat technique form closes.
If I select a combat technique, everything works fine. My question is: can I change the behavior whereby the Combat Technique form appears automatically when the Skill pick (which has the gizmo) is picked? Ideally, I'd like to be able to add a Skill pick without the combat technique form coming up automatically.
Thanks in advance!
Code:
<!-- Entity for weapon skills and combat techniques -->
<entity
id="entWpnCT"
form="frmCT"
defaultthing="ctHelper">
<bootstrap thing="ctHelper"/>
<bootstrap thing="ctInfo"/>
</entity>
Code:
<!-- Bangshu Skill -->
<thing
id="skBangshu"
name="Bangshu"
compset="Skill"
isunique="yes"
description="This Skill enables a character to use a long or short stick as a weapon.">
<fieldval field="trtAbbrev" value="Bsu"/>
<fieldval field="sklAlias" value="stick"/>
<!-- Tags -->
<tag group="User" tag="WpnSkill"/>
<!-- Specify the attribute to which this skill is linked -->
<link linkage="attribute" thing="attrMetal"/>
<child entity="entWpnCT"/>
</thing>
Code:
<portal
id="ctCombTech"
style="tblNormal">
<table_dynamic
component="CombTech"
showtemplate="SimpleItem"
choosetemplate="SimpleItem"
showfixedlast="yes"
showsortset="CombTech"
addpick="ctHelper"
headerpick="ctInfo">
<candidate>!Hide.CombTech</candidate>
<titlebar><![CDATA[
@text = "Add a Combat Technique - " & hero.child[resAbility].field[resSummary].text
]]></titlebar>
<description/>
<headertitle><![CDATA[
@text = "Combat Techniques: " & hero.child[resAbility].field[resSummary].text
]]></headertitle>
<additem><![CDATA[
~if we're in advancement mode, we've been frozen, so display accordingly
if (state.iscreate = 0) then
@text = "{text clrgrey}Add Combat Techniques Via Advances Tab"
done
endif
~set the color based on whether the proper number of slots are allocated
if (hero.child[resAbility].field[resLeft].value = 0) then
@text = "{text clrgrey}"
elseif (hero.child[resAbility].field[resLeft].value < 0) then
@text = "{text clrwarning}"
endif
@text &= "Add New Combat Technique"
]]></additem>
</table_dynamic>
</portal>
<layout
id="ctLayout"
marginvert="4">
<portalref portal="ctCombTech" taborder="20"/>
<position><![CDATA[
~position and size the table to span the full layout
portal[ctCombTech].left = 0
portal[ctCombTech].width = width
]]></position>
</layout>
<form
id="ctForm"
name="Combat Technique"
marginhorz="10"
marginvert="5"
entity="entWpnCT">
<layoutref layout="ctLayout"/>
<position><![CDATA[
layout[ctLayout].width = 250
perform layout[ctLayout].render
width = layout[ctLayout].width
height = 200
]]></position>
</form>