Jump to content

Home

How do I make my own hero unit?


Fenix Darkblaze

Recommended Posts

I want to make a new hero unit, but I'm relatively new to modding. I have all of the XML data files downloaded, and the EAW editor at the ready. Now I just need to know how to make my own hero, add what special abilities I want, health, armor, description, just about everything for a new unit. Can anyone instruct me, or at least direct me somewhere I can learn to do this? Also, I'd like to be able to garrison fighters or something inside of it, so please make sure to tell me how to do that as well.

Link to comment
Share on other sites

I want to make a new hero unit, but I'm relatively new to modding. I have all of the XML data files downloaded, and the EAW editor at the ready. Now I just need to know how to make my own hero, add what special abilities I want, health, armor, description, just about everything for a new unit. Can anyone instruct me, or at least direct me somewhere I can learn to do this? Also, I'd like to be able to garrison fighters or something inside of it, so please make sure to tell me how to do that as well.

 

I've delved into making other units, but I'm not entirely sure how to go about unique heroes...

 

However, say you're making a unique ISD based off Piett. Open up SPACEUNITSCAPITAL.XML and search for Generic_Star_Destroyer. Copy all of this...

 

<SpaceUnit Name="Generic_Star_Destroyer">
	<Text_ID>TEXT_UNIT_STAR_DESTROYER</Text_ID>
	<Encyclopedia_Good_Against> Corellian_Corvette Corellian_Gunboat Nebulon_B_Frigate </Encyclopedia_Good_Against>
	<Encyclopedia_Vulnerable_To> Y-wing Calamari_Cruiser </Encyclopedia_Vulnerable_To>
	<GUI_Row> 1 </GUI_Row>
	<Space_Model_Name>EV_StarDestroyer.ALO</Space_Model_Name>

	<Ranking_In_Category>5</Ranking_In_Category>

   <GUI_Bracket_Height>500</GUI_Bracket_Height>
	<GUI_Bracket_Size>2</GUI_Bracket_Size>

	<Select_Box_Scale>800</Select_Box_Scale>
	<Select_Box_Z_Adjust>-50</Select_Box_Z_Adjust>

	<Scale_Factor>1.0</Scale_Factor>
	<Mass>0.999</Mass>
	<Dense_FOW_Reveal_Range_Multiplier>0.24</Dense_FOW_Reveal_Range_Multiplier>
	<Multisample_FOW_Check>Yes</Multisample_FOW_Check>

	<Visible_On_Radar_When_Fogged>true</Visible_On_Radar_When_Fogged>
	<Armor_Type> Armor_Star_Destroyer </Armor_Type>
	<Shield_Armor_Type>Shield_Capital</Shield_Armor_Type>

	<Max_Speed>1.4</Max_Speed>
	<Max_Rate_Of_Turn>0.3</Max_Rate_Of_Turn>
	<MovementClass> Space </MovementClass>
	<Space_Layer> Capital </Space_Layer>
	<Layer_Z_Adjust>-330.0</Layer_Z_Adjust>
	<Max_Rate_Of_Roll>0.1</Max_Rate_Of_Roll>
	<Bank_Turn_Angle>5</Bank_Turn_Angle>
	<OverrideAcceleration> .02 </OverrideAcceleration>
	<OverrideDeceleration> .02 </OverrideDeceleration>

	<Max_Thrust>0.1</Max_Thrust>
	<Hyperspace>Yes</Hyperspace>
	<Hyperspace_Speed>1</Hyperspace_Speed>
	<Maintenance_Cost>0.3</Maintenance_Cost>

	<Affiliation>Empire</Affiliation>
	<Tech_Level>99</Tech_Level>
	<Required_Timeline>0</Required_Timeline>
	<Required_Ground_Base_Level>0</Required_Ground_Base_Level>
	<Required_Star_Base_Level>4</Required_Star_Base_Level>
	<Required_Special_Structures />
	<Required_Planets>MonCalimari, Kuat, Fondor, Sullust</Required_Planets>
	<Damage>70</Damage>
	<Autoresolve_Health>7500</Autoresolve_Health>
	<Shield_Points>2000</Shield_Points>
	<Tactical_Health>7500</Tactical_Health> <!-- was 6000 -->
	<Shield_Refresh_Rate>50</Shield_Refresh_Rate>
	<Energy_Capacity>8000</Energy_Capacity>
	<Energy_Refresh_Rate>800</Energy_Refresh_Rate>
	<Ship_Class>capital</Ship_Class>
	<Surface_Bombardment_Capable>yes</Surface_Bombardment_Capable>
	<!--<Political_Control>1</Political_Control>-->
	<Political_Faction>Empire</Political_Faction>
	<Squadron_Capacity>40</Squadron_Capacity>
	<Build_Cost_Credits>5900</Build_Cost_Credits>
	<AI_Combat_Power>5900</AI_Combat_Power>
	<Build_Time_Seconds>90</Build_Time_Seconds>
	<Build_Tab_Space_Units>Yes</Build_Tab_Space_Units>
	<Size_Value>8</Size_Value>

	<!-- Set to spawn all units once and then not continue - no reserves -->
	<Starting_Spawned_Units_Tech_0>TIE_Fighter_Squadron, 2</Starting_Spawned_Units_Tech_0>
	<Starting_Spawned_Units_Tech_0>TIE_Bomber_Squadron, 1</Starting_Spawned_Units_Tech_0>
	<Spawned_Squadron_Delay_Seconds>5</Spawned_Squadron_Delay_Seconds>
	<Reserve_Spawned_Units_Tech_0>TIE_Fighter_Squadron, 8</Reserve_Spawned_Units_Tech_0> 
	<Reserve_Spawned_Units_Tech_0>TIE_Bomber_Squadron, 4</Reserve_Spawned_Units_Tech_0>


	<Behavior> SELECTABLE, DUMMY_STARSHIP </Behavior>
	<SpaceBehavior>ABILITY_COUNTDOWN, SIMPLE_SPACE_LOCOMOTOR, POWERED, SHIELDED, HIDE_WHEN_FOGGED, REVEAL, TARGETING, UNIT_AI, ASTEROID_FIELD_DAMAGE, SPAWN_SQUADRON, DAMAGE_TRACKING, ION_STUN_EFFECT, NEBULA </SpaceBehavior>

	<Collidable_By_Projectile_Living>Yes</Collidable_By_Projectile_Living>
	<Death_Explosions>Large_Explosion_Space_Empire</Death_Explosions>
	<Asteroid_Damage_Hit_Particles>Large_Damage_Space</Asteroid_Damage_Hit_Particles>

	<Death_Clone>Damage_Normal, Star_Destroyer_Death_Clone</Death_Clone>
	<Space_FOW_Reveal_Range>1200.0</Space_FOW_Reveal_Range>
	<Targeting_Max_Attack_Distance>2000.0</Targeting_Max_Attack_Distance>

	<HardPoints> 
		HP_Star_Destroyer_Weapon_FL, HP_Star_Destroyer_Weapon_FR, HP_Star_Destroyer_Weapon_BL, HP_Star_Destroyer_Weapon_BR,
		HP_Star_Destroyer_Weapon_ML, HP_Star_Destroyer_Weapon_MR, HP_Star_Destroyer_Shield_Generator, HP_Star_Destroyer_Engines,
		HP_Star_Destroyer_Tractor_Beam, HP_Star_Destroyer_Fighter_Bay
	</HardPoints>

	<SFXEvent_Select>Unit_Select_Star_Destroyer</SFXEvent_Select>
	<SFXEvent_Move>Unit_Move_Star_Destroyer</SFXEvent_Move>
	<SFXEvent_Fleet_Move>Unit_Fleet_Move_Star_Destroyer</SFXEvent_Fleet_Move>
	<SFXEvent_Attack>Unit_Attack_Star_Destroyer</SFXEvent_Attack>
	<SFXEvent_Guard>Unit_Guard_Star_Destroyer</SFXEvent_Guard>
	<SFXEvent_Move_Opposite>Unit_Move_Opposite_Star_Destroyer</SFXEvent_Move_Opposite>
	<SFXEvent_Barrage>Unit_Barrage_Star_Destroyer</SFXEvent_Barrage>
	<SFXEvent_Stop>Unit_Stop_Star_Destroyer</SFXEvent_Stop>
	<SFXEvent_Move_Into_Asteroid_Field> Unit_Asteroids_Star_Destroyer </SFXEvent_Move_Into_Asteroid_Field>
	<SFXEvent_Move_Into_Nebula> Unit_Nebula_Star_Destroyer </SFXEvent_Move_Into_Nebula>
	<SFXEvent_Damaged_By_Asteroid> SFX_Asteroid_Detonation </SFXEvent_Damaged_By_Asteroid>

	<SFXEvent_Attack_Hardpoint> HARD_POINT_WEAPON_LASER, Unit_HP_LASER_Star_Destroyer </SFXEvent_Attack_Hardpoint>
	<SFXEvent_Attack_Hardpoint> HARD_POINT_WEAPON_MISSILE, Unit_HP_MISSILE_Star_Destroyer </SFXEvent_Attack_Hardpoint>
	<SFXEvent_Attack_Hardpoint> HARD_POINT_WEAPON_TORPEDO, Unit_HP_TORP_Star_Destroyer </SFXEvent_Attack_Hardpoint>
	<SFXEvent_Attack_Hardpoint> HARD_POINT_WEAPON_ION_CANNON, Unit_HP_ION_Star_Destroyer </SFXEvent_Attack_Hardpoint>
	<SFXEvent_Attack_Hardpoint> HARD_POINT_SHIELD_GENERATOR, Unit_HP_SHIELDS_Star_Destroyer </SFXEvent_Attack_Hardpoint>
	<SFXEvent_Attack_Hardpoint> HARD_POINT_ENGINE, Unit_HP_ENGINES_Star_Destroyer </SFXEvent_Attack_Hardpoint>

	<SFXEvent_Ambient_Loop>Unit_Star_Destroyer_Idle_Engine_Loop</SFXEvent_Ambient_Loop>

	<SFXEvent_Hardpoint_Destroyed> HARD_POINT_WEAPON_LASER, Unit_Lost_Laser_Star_Destroyer </SFXEvent_Hardpoint_Destroyed>
	<SFXEvent_Hardpoint_Destroyed> HARD_POINT_WEAPON_MISSILE,  </SFXEvent_Hardpoint_Destroyed>
	<SFXEvent_Hardpoint_Destroyed> HARD_POINT_WEAPON_TORPEDO,  </SFXEvent_Hardpoint_Destroyed>
	<SFXEvent_Hardpoint_Destroyed> HARD_POINT_WEAPON_ION_CANNON, Unit_Lost_Ion_Star_Destroyer </SFXEvent_Hardpoint_Destroyed>
	<SFXEvent_Hardpoint_Destroyed> HARD_POINT_SHIELD_GENERATOR, Unit_Lost_Shields_Star_Destroyer </SFXEvent_Hardpoint_Destroyed>
	<SFXEvent_Hardpoint_Destroyed> HARD_POINT_ENGINE, Unit_Lost_Engines_Star_Destroyer </SFXEvent_Hardpoint_Destroyed>
	<SFXEvent_Hardpoint_Destroyed> HARD_POINT_GRAVITY_WELL, </SFXEvent_Hardpoint_Destroyed>
	<SFXEvent_Hardpoint_Destroyed> HARD_POINT_FIGHTER_BAY, Unit_Lost_Bay_Star_Destroyer </SFXEvent_Hardpoint_Destroyed>
	<SFXEvent_Hardpoint_Destroyed> HARD_POINT_TRACTOR_BEAM, </SFXEvent_Hardpoint_Destroyed>
	<SFXEvent_Hardpoint_Destroyed> HARD_POINT_ENABLE_SPECIAL_ABILITY, </SFXEvent_Hardpoint_Destroyed>

	<Death_SFXEvent_Start_Die>Unit_Star_Destroyer_Death_SFX</Death_SFXEvent_Start_Die>

	<SFXEvent_Build_Started>EHD_Build_Vehicle</SFXEvent_Build_Started>
	<SFXEvent_Build_Cancelled>EHD_Unit_Canceled</SFXEvent_Build_Cancelled>
	<SFXEvent_Build_Complete>Unit_Complete_Star_Destroyer</SFXEvent_Build_Complete>

	<SFXEvent_Engine_Idle_Loop> Unit_Star_Destroyer_Idle_Engine_Loop </SFXEvent_Engine_Idle_Loop>
	<SFXEvent_Engine_Moving_Loop> Unit_Star_Destroyer_Moving_Engine_Loop </SFXEvent_Engine_Moving_Loop>
	<SFXEvent_Engine_Cinematic_Focus_Loop> Unit_Star_Destroyer_Cinematic_Engine_Loop </SFXEvent_Engine_Cinematic_Focus_Loop>

	<CategoryMask> Capital | AntiFrigate </CategoryMask>
	<Icon_Name>i_button_imperator.tga</Icon_Name>
	<GUI_Model_Name>EV_StarDestroyer_hulk.ALO</GUI_Model_Name>
	<GUI_Distance>2300</GUI_Distance>
	<GUI_Offset>0 0 0</GUI_Offset>
	<GUI_Velocity>45</GUI_Velocity>
	<Victory_Relevant>yes</Victory_Relevant>
	<Space_Full_Stop_Command> Yes </Space_Full_Stop_Command>
	<Has_Space_Evaluator>True</Has_Space_Evaluator>

	<Guard_Chase_Range>1000.0</Guard_Chase_Range>
	<Idle_Chase_Range>0.0</Idle_Chase_Range>
	<Attack_Move_Response_Range>400.0</Attack_Move_Response_Range>
	<Targeting_Stickiness_Time_Threshold>5.0</Targeting_Stickiness_Time_Threshold>
	<Targeting_Priority_Set>Capital</Targeting_Priority_Set>

	<Is_Visible_On_Radar>Yes</Is_Visible_On_Radar>
	<Radar_Icon_Name>i_radar_capital_ship_empire.tga</Radar_Icon_Name>
	<Radar_Icon_Scale_Land>1.0</Radar_Icon_Scale_Land>
	<Radar_Icon_Scale_Space>1.0</Radar_Icon_Scale_Space>

	<!-- Non-Hero unit abilities description -->
   <Unit_Abilities_Data SubObjectList="Yes">
      <!-- Primary ability -->
      <Unit_Ability>
            <Type>TRACTOR_BEAM</Type>
            <Mod_Multiplier>SPEED_MULTIPLIER, 0.8f</Mod_Multiplier>
            <GUI_Activated_Ability_Name> SD_Tractor_Beam_Attack_Ability </GUI_Activated_Ability_Name> <!-- GUI Command Bar support -->
            <Recharge_Seconds>20</Recharge_Seconds>
            <SFXEvent_GUI_Unit_Ability_Activated>Unit_Tractor_Beam_Star_Destroyer</SFXEvent_GUI_Unit_Ability_Activated>
				<SFXEvent_Special_Ability_Loop> Unit_Star_Destroyer_Tractor_Beam </SFXEvent_Special_Ability_Loop>
      </Unit_Ability>
   </Unit_Abilities_Data>

   <Abilities SubObjectList="Yes">
      <Tractor_Beam_Attack_Ability Name="SD_Tractor_Beam_Attack_Ability">
            <Activation_Style> User_Input </Activation_Style>
            <Applicable_Unit_Categories>Transport | Corvette | Frigate</Applicable_Unit_Categories>
            <Applicable_Unit_Types>Millennium_Falcon</Applicable_Unit_Types>

            <Activation_Min_Range>10</Activation_Min_Range>
            <Activation_Max_Range>1000</Activation_Max_Range>


            <!-- Modifiers. If 0 - no modifier is applied, 1 - "100% increase or decrease" -->
            <Target_Speed_Decrease_Percent>0.45</Target_Speed_Decrease_Percent>
            <Stacking_Category>0</Stacking_Category>            
      </Tractor_Beam_Attack_Ability>

   </Abilities>

	<Encyclopedia_Text> TEXT_TOOLTIP_STAR_DESTROYER TEXT_TOOLTIP_REQUIRED_PLANETS_CAPITAL_SHIPS</Encyclopedia_Text>
	<Encyclopedia_Unit_Class> TEXT_ENCYCLOPEDIA_CLASS_CAPITAL </Encyclopedia_Unit_Class>
	<Score_Cost_Credits> 45000</Score_Cost_Credits>

	<!--<MULTIPLAYER SKIRMISH VALUES BEGIN>-->
	<Tactical_Build_Cost_Multiplayer>5200</Tactical_Build_Cost_Multiplayer>
	<Tactical_Build_Time_Seconds>35</Tactical_Build_Time_Seconds>
	<Tactical_Build_Prerequisites />
	<Tactical_Production_Queue>Tactical_Units</Tactical_Production_Queue>
	<!--<Build_Limit_Current_Per_Player>0</Build_Limit_Current_Per_Player>-->
	<!--<Build_Limit_Lifetime_Per_Player>0</Build_Limit_Lifetime_Per_Player>-->  
	<!--<MULTIPLAYER SKIRMISH VALUES END>-->
</SpaceUnit>



<SpaceUnit Name="Star_Destroyer">
	<Variant_Of_Existing_Type>Generic_Star_Destroyer</Variant_Of_Existing_Type>
	<Tech_Level>4</Tech_Level>

	<HardPoints> 
		HP_Star_Destroyer_Weapon_FL, HP_Star_Destroyer_Weapon_FR, HP_Star_Destroyer_Weapon_BL, 
		HP_Star_Destroyer_Weapon_BR, HP_Star_Destroyer_Weapon_ML, HP_Star_Destroyer_Weapon_MR, 
		HP_Star_Destroyer_Shield_Generator, HP_Star_Destroyer_Engines,
		HP_Star_Destroyer_Tractor_Beam, HP_Star_Destroyer_Fighter_Bay
	</HardPoints>
	<Population_Value>4</Population_Value>
</SpaceUnit>

<SpaceUnit Name="Star_Destroyer_Death_Clone">
	<Text_ID>TEXT_UNIT_STAR_DESTROYER</Text_ID>
	<Space_Model_Name>EV_StarDestroyer_D.ALO</Space_Model_Name>
	<xxxSpace_Model_Name>EV_StarDestroyer_Dead.ALO</xxxSpace_Model_Name>
	<Death_SFXEvent_Start_Die>Unit_Star_Destroyer_Death_SFX</Death_SFXEvent_Start_Die>
	<Scale_Factor>1</Scale_Factor>
	<Layer_Z_Adjust>-330.0</Layer_Z_Adjust>
	<Max_Speed>0.25</Max_Speed>
	<Max_Rate_Of_Turn>0.4</Max_Rate_Of_Turn>
	<Max_Thrust>0.05</Max_Thrust>
	<Max_Rate_Of_Roll>0.02</Max_Rate_Of_Roll>
	<Bank_Turn_Angle>5</Bank_Turn_Angle>
	<Affiliation>Empire</Affiliation>
	<Ship_Class>capital_ship</Ship_Class>
	<Glory_Cinematics>CAM_SDestroyer_Glory01.tec</Glory_Cinematics>
	<Remove_Upon_Death>true</Remove_Upon_Death>

</SpaceUnit>

 

and paste it AFTER </spaceunit>. Then edit <SpaceUnit Name=Generic_Star_Destroyer> to the name of the ship class. This doesn't really matter, it won't show up anyway.

 

Then open up UNIQUEUNITS.XML - copy Piett(the first set of lines) like you did the ISD and paste it below the real Piett. Change <UniqueUnit Name="Accuser_Star_Destroyer"> so that it equals the name of your choice...EG, <UniqueUnit Name="Tarkin_Has_Smelly_Feet">. Change the <Variant_Of_Existing_Type>Generic_Star_Destroyer</Variant_Of_Existing_Type>

line to

<Variant_Of_Existing_Type>(insert your spaceunit name here)</Variant_Of_Existing_Type>

 

Then go back to SPACEUNITSCAPITAL and edit the details of your new ship, which SHOULD reflect into your hero.

 

<Scale_Factor>1.0</Scale_Factor> = Changes ship size - experiment

<Max_Speed>1.4</Max_Speed> = Self explanitory

<Max_Rate_Of_Turn>0.3</Max_Rate_Of_Turn> = How fast it turns

<Affiliation>Empire</Affiliation> = Empire or Rebel ship(?)

<Damage>70</Damage> = The amount of damage dealt

<Autoresolve_Health>7500</Autoresolve_Health> = Autoresolve health

<Shield_Points>2000</Shield_Points> = How strong the shields are

<Tactical_Health>7500</Tactical_Health> = Health

<Shield_Refresh_Rate>50</Shield_Refresh_Rate> = How fast shields replenish

 

To change the fighters it spawns...replace...

 

<Starting_Spawned_Units_Tech_0>TIE_Fighter_Squadron, 2</Starting_Spawned_Units_Tech_0>

and

<Starting_Spawned_Units_Tech_0>TIE_Bomber_Squadron, 1</Starting_Spawned_Units_Tech_0>

 

Replace the 2 and 1 with the numbers you want it to launch. 8 TIEs and 4 Bombers is usually good.

 

I am not certain if this works, merely assuming. If anyone knows for certain how to make a hero, feel free to use this as a reference to quote from if I've got any of it right.

 

If it DOES work, add it as a starting unit to the GC map of your choice.

Link to comment
Share on other sites

Im trying to make a YT-1300 buildable for the rebels, but I cannot figure out the one line of code to make it buildable and have a clickable tab like every other unit. I took the millenium falcon and edited some parts in the XML and im trying to make it now buildable.

 

Someone please help me

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...