Lonecat Nekophrodite
Deity
- Joined
- Jan 10, 2019
- Messages
- 2,833
Is it possible to code a new kind of ranged attack that combines benefits of BOTH RangedAttack (By ranged class) and Bombardment (by siege class)? Personally I want to make an Artillery unit that can now do full damage to land units by default.
This is what i'm trying to do rightnow.
UnitGameplay.xml
A tag class added to units rather than replacing
UnitAbilitiesGameplay.xml
UnitAbilitiesText.xml
Is it possible to assign separate ranged attack types that allows a land unit to deal full damage against BOTH cities and units?
And without the need to write texts describing that such debuffs are now fully negated.
This is what i'm trying to do rightnow.
UnitGameplay.xml
Code:
<GameData>
...
<Tags>
...
<Row Tag="CLASS_ARTILLERY" Vocabulary="ABILITY_CLASS"/> <!--Siege class default attack boosts-->
...
</Tags>
<TypeTags>
<Row Type="UNIT_ARTILLERY" Tag="CLASS_ARTILLERY"/>
</TypeTags>
...
</GameData>
UnitAbilitiesGameplay.xml
Code:
<GameData>
<Types>
...
<Row Type="ABILITY_HE_SHELLS" Kind="KIND_ABILITY"/>
...
</Types>
</TypeTags>
<Row Type="ABILITY_HE_SHELLS" Tag="CLASS_ARTILLERY"/>
</TypeTags>
<UnitAbilities>
<Row UnitAbilityType="ABILITY_HE_SHELLS" Name="LOC_ABILITY_HE_SHELLS_NAME" Description="LOC_ABILITY_HE_SHELLS_DESCRIPTION"/>
</UnitAbilities>
<UnitAbilityModifiers>
<Row> <UnitPromotionType>ABILITY_HE_SHELLS</UnitPromotionType> <ModifierId>HE_SHELLS_BONUS_VS_UNITS</ModifierId>
</Row>
</UnitAbilityModifiers>
<Modifiers>
<Row>
<ModifierId>HE_SHELLS_BONUS_VS_UNITS</ModifierId>
<ModifierType>MODIFIER_UNIT_ADJUST_COMBAT_STRENGTH</ModifierType>
<SubjectRequirementSetId>SHRAPNEL_REQUIREMENTS</SubjectRequirementSetId>
</Row>
</Modifiers>
<ModifierArguments>
<Row> <ModifierId>HE_SHELLS_BONUS_VS_UNITS</ModifierId> <Name>Amount</Name> <Value>17</Value> </Row>
</ModifierArguments>
<ModifierStrings>
<Row ModifierId="HE_SHELLS_BONUS_VS_UNITS" Context="Preview" Text="LOC_ABILITY_HE_SHELLS_FULL_DAMAGE_VS_UNITS_MODIFIER_DESCRIPTION"/>
</ModifierStrings>
</GameData>
UnitAbilitiesText.xml
Code:
<GameData>
<BaseGameText>
<Row Tag="LOC_ABILITY_HE_SHELLS_NAME"> <Text>High Explosive Shells</Text> </Row>
<Row Tag="LOC_ABILITY_HE_SHELLS_DESCRIPTION"> <Text>[COLOR_GREEN] Full [ICON_Bombard] [ENDCOLOR] Bombard Strength vs. units.</Text> </Row>
<Row Tag="LOC_ABILITY_HE_SHELLS_FULL_DAMAGE_VS_UNITS_MODIFIER_DESCRIPTION"> <Text>[COLOR_GREEN]FULLY Negates -17 [ICON_Bombard] [ENDCOLOR]Bombard Strength vs. units.</Text> </Row>
</BaseGameText>
</GameData>
Is it possible to assign separate ranged attack types that allows a land unit to deal full damage against BOTH cities and units?
And without the need to write texts describing that such debuffs are now fully negated.