Spaceboy
  • Spaceboy
  • 50.25% (Neutral)
  • Captain Topic Starter
12 years ago
I try some hours, get a superweapon working but the shortcut is missing.

Finaly i copied everything i found, hope it works but it doesn´t. I will post you my code, hope you´ll find my mistake.

UnitAbilityButtonTemplate.xml

Id="Command_FactionIonCannonControlFireIonCannon"
RadiusCursor="TargetingDecal04">
Image="Button_PlayerPowerIonCannon"
Title="NAME:PlayerPowerIonCannon"
Description="DESC:PlayerPowerIonCannon" />


PlayerSpellBook.xml

id="ModuleTag_PlayerPowerManager_IonCannonNew"
SpecialPowerTemplate="SpecialPowerFactionIonCannon"
/>



LogicCommand.xml

Options="NEED_TARGET_POS"
Type="SPECIAL_POWER"
id="Command_FactionIonCannonSuperweapon">
SpecialPowerFactionIonCannon

Options="NEED_TARGET_POS"
Type="SPECIAL_POWER"
id="Command_FactionIonCannonControlFireIonCannon">
SpecialPowerFactionIonCannon



LogicCommandSet.xml


id="FactionIonCannonCommandSet">
Command_FactionIonCannonSuperweapon
Command_TogglePower
Command_SelfRepair
Command_Sell

........

id="PlayerSpellBookCommandSet">
Command_FactionIonCannonSuperweapon
Command_LaunchCatalystMissile
Command_ComputerCounterMeasures
Command_CommandPostCallAirborne
Command_CommandPostCallBloodhound
Command_CommandPostCallHunterKiller
Command_SpaceCommandGDIDropPods
Command_SpaceCommandGDIShockwave
Command_CommandPostRadarScan
Command_CommandPostBombingRun
Command_IonCannonSuperweapon
Command_TempleOfNodNuclearMissile
Command_SelectObjectsForClone
Command_SpawnObjectsForClone
Command_FireRadarJammingMissile
Command_NODBurrowMines
Command_TiberiumFacilitySeedTiberium
Command_TiberiumFacilityAirDispersion
Command_RedShadowStrikeTeam
Command_CloakingField
Command_AlienRepairDrones
Command_TiberiumVibrationScan
Command_LightningSpike
Command_SummonMothership
Command_RiftGeneratorSuperweapon
Command_SpecialPowerCrystalField
Command_SpecialPowerSwarm
Command_SpecialPowerPhaseField
Command_EMPControlCenterEMP




SpecialPowerTemplates.xml

id="SpecialPowerFactionIonCannon"
DisplayName="NAME:SuperweaponTimerIonCannon"
Description="DESC:SuperweaponTimerIonCannon"
Flags="HAS_PUBLIC_TIMER IS_PLAYER_POWER FOGGED_SHROUDED_CELLS_OK WATER_OK IGNORE_MAP_EXTENTS SHARED_SYNC"
ReloadTime="300s"
TargetType="LOCATION"
RadiusCursorRadius="300"
RestrictionType="1"
EvaEventToPlayWhenSelectingTarget="SelectSpecialPowerTarget"
EvaEventToPlayOnInitiateOwner="OwnIonCannonActivated"
EvaEventToPlayOnInitiateAlly="AlliedIonCannonActivated"
EvaEventToPlayOnInitiateEnemy="EnemyIonCannonActivated"
TimerImage="Button_PlayerPowerIonCannon"/>



PlayerPowerButtonTemplates.xml

RadiusCursor="TargetingDecalIonCannon"
id="SpecialPowerFactionIonCannon">
Image="Button_PlayerPowerIonCannon"
Title="NAME:PlayerPowerIonCannon"
TypeDescription="TYPE:PlayerPowerIonCannon"
Description="DESC:PlayerPowerIonCannon" />




FactionIonCannon.xml (CommandSet is correct)

id="ModuleTag_IonCannonNew"
SpecialPowerTemplate="SpecialPowerFactionIonCannon"
UpdateModuleStartsAttack="true"
AvailableAtStart="false"
OCL="OCL_SuperweaponDestroyCiviliansHumanelyObject"
CreateLocation="CREATE_AT_LOCATION"
/>
id="ModuleTag_IonCannonUpdateNew"
SpecialPowerTemplate="SpecialPowerFactionIonCannon"
SpecialWeapon="IonCannonWeapon"
UnpackTime="0s"
PackTime="3s"
WhichSpecialWeapon="1"
/>
id="ModuleTag_IonCannonSpecialPowerNew"
CommandButtonName="Command_FactionIonCannonSuperweapon"
SpecialPowerRadius="999999.0"
SpecialPowerAIType="SPECIAL_POWER_SUPERWEAPON"
UnitKindOf="STRUCTURE"
/>


id="ModuleTag_IonCannonReadyToFireUpdateNew"
SpecialPowerTemplate="SpecialPowerFaction"
ReadyCondition="SPECIALPOWER1_READY"
/>
Sponsor
Spaceboy
  • Spaceboy
  • 50.25% (Neutral)
  • Captain Topic Starter
12 years ago
renamed PlayerPowerButtonTemplates.xml into NewPlayerPowerButtonTemplates.xml and working fine