Hovercraft Units: Difference between revisions
(Created page with "'''Hovercraft Units'''<nowiki/>' stats and properties can be modified as a whole, by using the '''GameEnums.UnitType_Hovercraft''' enumeration variable. For instance: <syntaxhighlight lang="javascript"> this.getOffensiveBonus = function (co, attacker, atkPosX, atkPosY, defender, defPosX, defPosY, isDefender, action, luckmode, map) { if (co.getIsCO0() === true) { if (co.getPowerMode() === GameEnums.PowerMode_Power) { if (attacker.g...") |
|||
Line 24: | Line 24: | ||
Possible values are: | Possible values are: | ||
{| class="wikitable" | {| class="wikitable" style="margin:auto;text-align: center" | ||
|+ Hovercraft Units and their weapon strings | |||
|- | |||
!Hovercraft Units !!Primary Weapon String!! Secondary Weapon String | |||
|- | |||
|'''HOVERCRAFT'''||N/A||N/A | |||
|- | |||
|'''ARTILLERYCRAFT'''||N/A||N/A | |||
|- | |||
|'''HOVERFLAK'''||N/A||N/A | |||
|- | |||
|'''HEAVY_HOVERCRAFT'''||N/A||N/A | |||
|- | |- | ||
|} | |} | ||
[[Category:Units]] | [[Category:Units]] | ||
[[Category:UnitIDs]] | [[Category:UnitIDs]] |
Revision as of 23:02, 5 October 2023
Hovercraft Units' stats and properties can be modified as a whole, by using the GameEnums.UnitType_Hovercraft enumeration variable. For instance:
this.getOffensiveBonus = function (co, attacker, atkPosX, atkPosY,
defender, defPosX, defPosY, isDefender, action, luckmode, map)
{
if (co.getIsCO0() === true)
{
if (co.getPowerMode() === GameEnums.PowerMode_Power)
{
if (attacker.getUnitType() === GameEnums.UnitType_Hovercraft)
{
return 30;
}
}
}
return 0;
};
Increases the firepower of hovercraft units by 30% during the CO Power.
Modifying stats or properties of specific Units
Each unit can be modified through a comparison of the Unit ID. The Unit ID can be obtained through unit.getUnitID(), and it's of a string type.
Possible values are:
Hovercraft Units | Primary Weapon String | Secondary Weapon String |
---|---|---|
HOVERCRAFT | N/A | N/A |
ARTILLERYCRAFT | N/A | N/A |
HOVERFLAK | N/A | N/A |
HEAVY_HOVERCRAFT | N/A | N/A |