Note: LucasForums Archive Project
The content here was reconstructed by scraping the Wayback Machine in an effort to restore some of what was lost when LF went down. The LucasForums Archive Project claims no ownership over the content or assets that were archived on archive.org.

This project is meant for research purposes only.

Adding New Heros?

Page: 1 of 1
 Bob Lion54
02-25-2006, 5:49 AM
#1
Hi all. I've been trying to add a new space hero squadron. Delta Squad is what I'm calling it at the moment. Basically, I have it appearing in game as a new unit, but with a few problems.

Firstly, I can't get the name to show up. I tried to add an entry in the mastertext.dat file, but that didn't seem to do the trick. I also tried to add an insane amount of health to see if that would work. They are just as vulnerable as a regular X-Wing squad.

Well, heres the code, maybe someone can see what I did wrong. I tried pretty much all day yesterday and couldn't get it to work. Thanks!

NOTE- some of the variable as a bit extreme, that was done for experimentation. The final version will be more realistic.
<UniqueUnit Name="Delta_Squadron">
<Text_ID>TEXT_Delta_Squadron</Text_ID>
<Variant_Of_Existing_Type>X_WING_SQUADRON</Variant_Of_Existing_Type>
<Encyclopedia_Good_Against> TIE_Fighter TIE_Bomber TIE_Prototype </Encyclopedia_Good_Against>
<Encyclopedia_Vulnerable_To> Tartan_Patrol_Cruiser Broadside_Class_Cruiser IPV1_System_Patrol_Craft </Encyclopedia_Vulnerable_To>
<Is_Named_Hero>Yes</Is_Named_Hero>
<Respawn_Whole_Team_When_Killed>Yes</Respawn_Whole_Team_When_Killed>
<GUI_Row> 1 </GUI_Row>
<Is_Dummy>Yes</Is_Dummy>
<Formation_Priority>1</Formation_Priority>
<Is_Escort>Yes</Is_Escort>
<Is_Bomber>no</Is_Bomber>
<Autoresolve_Health>3000</Autoresolve_Health>
<Tactical_Health>99999</Tactical_Health>
<Damage>200</Damage>
<Affiliation>Rebel</Affiliation>
<Political_Control>0</Political_Control>
<Build_Cost_Credits>2000</Build_Cost_Credits>
<Build_Time_Seconds>10</Build_Time_Seconds>
<Build_Tab_Space_Units>Yes</Build_Tab_Space_Units>
<Build_Initially_Locked>No</Build_Initially_Locked>
<Build_Can_Be_Unlocked_By_Slicer>No</Build_Can_Be_Unlocked_By_Slicer>
<Tech_Level>3</Tech_Level>
<Required_Timeline />
<Required_Star_Base_Level>1</Required_Star_Base_Level>
<Required_Special_Structures />
<Behavior>DUMMY_SPACE_FIGHTER_SQUADRON</Behavior>
<Squadron_Units>X-Wing, X-Wing</Squadron_Units>
<Squadron_Units>X-Wing, X-Wing</Squadron_Units>
<Squadron_Units>X-Wing, X-Wing</Squadron_Units>
<Squadron_Offsets>30.0,0.0,0.0</Squadron_Offsets>
<Squadron_Offsets>0.0,15.0,0.0</Squadron_Offsets>
<Squadron_Offsets>0.0,-15.0,0.0</Squadron_Offsets>
<Squadron_Offsets>-30.0,30.0,0.0</Squadron_Offsets>
<Squadron_Offsets>-30.0,-30.0,0.0</Squadron_Offsets>
<Squadron_Offsets>30.0,-30.0,0.0</Squadron_Offsets>
<Icon_Name>i_button_x_wing.tga</Icon_Name>
<GUI_Model_Name>RV_xwing.ALO</GUI_Model_Name>
<GUI_Distance>95</GUI_Distance>
<GUI_Offset>0 0 0</GUI_Offset>
<GUI_Velocity>45</GUI_Velocity>

<SFXEvent_Build_Started>RHD_Build_Vehicle</SFXEvent_Build_Started>
<SFXEvent_Build_Cancelled>RHD_Unit_Canceled</SFXEvent_Build_Cancelled>
<SFXEvent_Build_Complete>Unit_Complete_X_Wing</SFXEvent_Build_Complete>

<FormationOrder>2</FormationOrder>
<Squadron_Formation_Error_Tolerance>25.0</Squadron_Formation_Error_Tolerance>
<Guard_Chase_Range>1000.0</Guard_Chase_Range>
<Idle_Chase_Range>200.0</Idle_Chase_Range>
<Attack_Move_Response_Range>300.0</Attack_Move_Response_Range>
<Property_Flags> SmallShip </Property_Flags>
<Autonomous_Move_Extension_Vs_Attacker>500.0</Autonomous_Move_Extension_Vs_Attacker>

<Unit_Abilities_Data SubObjectList="Yes">
<!-- Primary ability -->
<Unit_Ability>
<Type>SPOILER_LOCK</Type>

<Mod_Multiplier>WEAPON_DELAY_MULTIPLIER, 3.0f</Mod_Multiplier>
<Mod_Multiplier>SHIELD_REGEN_MULTIPLIER, 1.0f</Mod_Multiplier>
<Mod_Multiplier>ENERGY_REGEN_MULTIPLIER, 1.0f</Mod_Multiplier>
<Mod_Multiplier>SPEED_MULTIPLIER, 2</Mod_Multiplier>
</Unit_Ability>
</Unit_Abilities_Data>

<Encyclopedia_Text>TEXT_TOOLTIP_X_WING</Encyclopedia_Text>
<Encyclopedia_Unit_Class> TEXT_ENCYCLOPEDIA_CLASS_FIGHTER </Encyclopedia_Unit_Class>

<!--<MULTIPLAYER SKIRMISH VALUES BEGIN>-->
<Tactical_Build_Cost_Multiplayer>500</Tactical_Build_Cost_Multiplayer>
<Tactical_Build_Time_Seconds>15</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>-->
<Population_Value>1</Population_Value>
<Score_Cost_Credits> 600</Score_Cost_Credits>
</UniqueUnit>

EDIT: I got the text ID to work. I think it has to be all capital letters for the game to read it. I still have yet to figure out how to get the damage/health to work, though. They should be invincible (or close to it) how I have it set, but Delta Squad is getting blown to bits...

Oh well, now to see if I can figure out how to give Delta Squad its own texture.

EDIT 2: I feel dumb. I just relized that I was trying to make up DS using regular X-Wings. I made a new variant called Delta_X in the SPACEUNITFIGHTERS XML. IT WORKED!

Now I still have one problem. Textures. I can't seem to figure out how to point the game to a different texture. Aslo, where are the icon buttons? I can't seem to find them.
 Darth_Extas
02-26-2006, 10:06 PM
#2
Do you have any idea what the Text Id is?
 swindle
02-26-2006, 10:36 PM
#3
for setting up a squadron you should make each unit, say 5 x-wings, each one unique(or you could just make a squadron using duplicates), and have those in the uniqueunits.xml. then make a squadron in teh squadrons.xml using the units that you just created.

I am not really sure on how to have them show up as heroes

look at how red squadron is set up as individual units(luke skywalker, biggs, porkins, etc.) in the uniqueunits.xml, then look at how they are added the the "Red_Squadron" squadron in the squadrons.xml

sorry if that isn't as helpful as it sounds to me.. i am half awake :D

oh yeah, and as for text ids, you'll need to use a dat editor to view and edit Mastertextfile in the text folder. so that your unique units have unique names
Page: 1 of 1