Important Message

You are browsing the archived Lancers Reactor forums. You cannot register or login.
The content may be outdated and links may not be functional.


To get the latest in Freelancer news, mods, modding and downloads, go to
The-Starport

Problem with adding ship

The general place to discuss MOD''ing Freelancer!

Post Wed Aug 03, 2005 7:29 pm

Problem with adding ship

Hey all,

I'd appreciate any help with a problem I ran into. Kinda stuck and too exausted to sit here figuring it all out, considering I have almost no idea what's causing this problem:

I went through the Drizzt4.0's Ship Creating Tutorial v1.5 and went ahead to add my first new ship into FL. However the only thing I did differently was I didn't make a new model. I just simply used the same Defender ship model but added new strings in the ini files, making a whole new ship that looks just like the Defender but with way better stats. I got the mod to work just fine except now I ran into one nagging problem. When the mod is on, I can't seem to go anywhere to purchase the normal Defender ship in the game (but I can purchase the Uziel on Pittsburg, which is my new ship that looks like the Defender), I went to Battleship Missouri and Battleship Yokton, and when I go to the ship dealer the Defender isn't there, and when I click on the icon to open up the menu with the available ships, the menu suddenly disapears. It's the weirdest thing, and I went over everything and I did just as the tutorial taught.

Would anyone know off the top of their head what could be the problem? I'll gladly send the mod to anyone that might be able to help if they need to look at it to decide what is wrong. I'd really appreciate the help, thanks.

Post Wed Aug 03, 2005 9:54 pm

I've done something very similiar myself recently; here's a copy of the script I used for my Defender variant (the Defender Mk II):

EDIT: anywhere you see a winkey smiley, that's a ) and a ; - sorry

<script>

<data file="DATA\SHIPS\shiparch.ini" method="append">
<source>
[Ship
ids_name = 0 ;GENERATESTRRES("Defender Mk II"
ids_info = 0 ;GENERATEXMLRES("
<xml><RDL><PUSH/><TEXT/><PARA/><TRA data="1" mask="1" def="-2"/><JUST loc="center"/><TEXT>Stats</TEXT><PARA/><TRA data="0" mask="1" def="-1"/><JUST loc="left"/><TEXT/><PARA/><TEXT>Guns/Turrets: 5/1</TEXT><PARA/><TEXT>Armor: 1600</TEXT><PARA/><TEXT>Cargo Holds: </TEXT><PARA/><TEXT>Max Batteries/NanoBots: 20/14</TEXT><PARA/><TEXT>Optimal Weapon Class: 4</TEXT><PARA/><TEXT>Max. Weapon Class: 6</TEXT><PARA/><TEXT>Additional Equipment: M, CM, CD/T</TEXT><PARA/><PARA/><POP/></RDL></xml>"
ids_info1 = 0 ;GENERATEXMLRES("<xml><RDL><PUSH/><TRA data="1" mask="1" def="-2"/><JUST loc="center"/><TEXT>BDR-340 "Defender Mk II" Liberty Heavy Fighter</TEXT><PARA/><TRA data="0" mask="1" def="-1"/><JUST loc="left"/><TEXT></TEXT><PARA/><TEXT>"The best of the best," this heavily outfitted rig represents the pinnacle of Liberty's technological advances and design savoir faire. With its elevated armor and power rating as standard and the additional mount for firepower, it's no wonder that this ship is the number one choice of the Liberty Armed Forces. This is the second version of this fighter.</TEXT><PARA/><POP/></RDL></xml>"
ids_info2 = 66608
ids_info3 = 0 ;GENERATEXMLRES("<xml><RDL><PUSH/><TEXT/><PARA/><TEXT/><PARA/><TEXT>5/1</TEXT><PARA/><TEXT>1600</TEXT><PARA/><TEXT>30</TEXT><PARA/><TEXT>20/14</TEXT><PARA/><TEXT>4</TEXT><PARA/><TEXT>6</TEXT><PARA/><TEXT>M, CM, CD/T</TEXT><PARA/><POP/></RDL></xml>"
ship_class = 1
nickname = lim2_elite
msg_id_prefix = gcs_refer_shiparch_Libhf
mission_property = can_use_berths
LODranges = 0, 75, 150, 1300
type = FIGHTER
DA_archetype = ships\liberty\li_elite\li_elite.cmp
material_library = ships\liberty\li_playerships.mat
material_library = fx\envmapbasic.mat
envmap_material = envmapbasic
cockpit = cockpits\liberty\l_elite.ini
pilot_mesh = generic_pilot
nanobot_limit = 14
shield_battery_limit = 20
mass = 150.000000
hold_size = 30
linear_drag = 1.000000
fuse = intermed_damage_smallship01, 0.000000, 400
fuse = intermed_damage_smallship02, 0.000000, 200
fuse = intermed_damage_smallship03, 0.000000, 133
max_bank_angle = 30
camera_offset = 8, 34
camera_angular_acceleration = 0.050000
camera_horizontal_turn_angle = 17
camera_vertical_turn_up_angle = 5
camera_vertical_turn_down_angle = 25
camera_turn_look_ahead_slerp_amount = 1.000000
hit_pts = 1600
explosion_arch = explosion_li_elite
surface_hit_effects = 0, small_hull_hit_light01, small_hull_hit_light02, small_hull_hit_light03
surface_hit_effects = 150, small_hull_hit_medium01, small_hull_hit_medium02, small_hull_hit_medium03
surface_hit_effects = 300, small_hull_hit_heavy01, small_hull_hit_heavy02, small_hull_hit_heavy03
steering_torque = 50000.000000, 50000.000000, 230000.000000
angular_drag = 40000.000000, 40000.000000, 141000.000000
rotation_inertia = 8400.000000, 8400.000000, 8400.000000
nudge_force = 30000.000000
strafe_force = 20000
strafe_power_usage = 2
bay_door_anim = Sc_open baydoor
bay_doors_open_snd = cargo_doors_open
bay_doors_close_snd = cargo_doors_close
HP_bay_surface = HpBayDoor01
HP_bay_external = HpBayDoor02
HP_tractor_source = HpTractor_Source
num_exhaust_nozzles = 2
shield_link = l_elite_shield01, HpMount, HpShield01
hp_type = hp_gun_special_6, HpWeapon01, HpWeapon02
hp_type = hp_gun_special_5, HpWeapon01, HpWeapon02, HpWeapon03, HpWeapon04, HpWeapon05
hp_type = hp_gun_special_4, HpWeapon01, HpWeapon02, HpWeapon03, HpWeapon04, HpWeapon05
hp_type = hp_gun_special_3, HpWeapon01, HpWeapon02, HpWeapon03, HpWeapon04, HpWeapon05
hp_type = hp_gun_special_2, HpWeapon01, HpWeapon02, HpWeapon03, HpWeapon04, HpWeapon05
hp_type = hp_gun_special_1, HpWeapon01, HpWeapon02, HpWeapon03, HpWeapon04, HpWeapon05
hp_type = hp_elite_shield_special_6, HpShield01
hp_type = hp_elite_shield_special_5, HpShield01
hp_type = hp_elite_shield_special_4, HpShield01
hp_type = hp_elite_shield_special_3, HpShield01
hp_type = hp_elite_shield_special_2, HpShield01
hp_type = hp_elite_shield_special_1, HpShield01
hp_type = hp_thruster, HpThruster01
hp_type = hp_mine_dropper, HpMine01
hp_type = hp_countermeasure_dropper, HpCM01
hp_type = hp_turret_special_6, HpTurret01
hp_type = hp_turret_special_5, HpTurret01
hp_type = hp_turret_special_4, HpTurret01
hp_type = hp_turret_special_3, HpTurret01
hp_type = hp_turret_special_2, HpTurret01
hp_type = hp_turret_special_1, HpTurret01
hp_type = hp_torpedo_special_1, HpTorpedo01
hp_type = hp_torpedo_special_2, HpTorpedo01
</source>
</data>

<data file="DATA\EQUIPMENT\goods.ini" method="append">
<source>
[Good
nickname = lem2_hull
category = shiphull
ship = lim2_elite
price = 52000
ids_name = 0 ;GENERATESTRRES("Defender Mk II Hull"
item_icon = Equipment\models\commodities\nn_icons\li_elite.3db

[Good
nickname = lem2_package
category = ship
hull = lem2_hull
addon = ge_le_engine_01, internal, 1
addon = lim2_elite_power01, internal, 1
addon = ge_s_scanner_01, internal, 1
addon = ge_s_tractor_01, internal, 1
addon = shield01_mark04_hf, HpShield01, 1
addon = LargeWhiteSpecial, HpHeadlight, 1
addon = SlowSmallBlue, HpRunningLight01, 1
addon = SlowSmallBlue, HpRunningLight02, 1
addon = SlowSmallBlue, HpRunningLight03, 1
addon = SlowSmallBlue, HpRunningLight04, 1
addon = contrail01, HpContrail01, 1
addon = contrail01, HpContrail02, 1
addon = DockingLightRedSmall, HpDockLight01, 1
addon = DockingLightRedSmall, HpDockLight02, 1

[CollisionGroup
obj = Li_star_wing_lod1
separable = true
parent_impulse = 240.000000
child_impulse = 7.000000
debris_type = debris_small_ship
dmg_hp = DpStarboardwing
dmg_obj = li_elite_dmg_star_wing_cap
separation_explosion = explosion_small_ship_breakoff
mass = 5.000000
type = Starboard_Wing
hit_pts = 267
root_health_proxy = true

[CollisionGroup
obj = Li_port_wing_lod1
separable = true
parent_impulse = 240.000000
child_impulse = 7.000000
debris_type = debris_small_ship
dmg_hp = DpPortwing
dmg_obj = li_elite_dmg_port_wing_cap
separation_explosion = explosion_small_ship_breakoff
mass = 5.000000
type = Port_Wing
hit_pts = 267
root_health_proxy = true

[CollisionGroup
obj = li_Spoiler_lod1
separable = true
parent_impulse = 240.000000
child_impulse = 7.000000
debris_type = debris_small_ship
dmg_hp = DpSpoiler
dmg_obj = li_elite_dmg_Spoiler_cap
separation_explosion = explosion_small_ship_breakoff
mass = 5.000000
type = Spoiler
hit_pts = 400
root_health_proxy = true

[Simple
nickname = lim2_elite_dmg_star_wing_cap
DA_archetype = ships\liberty\li_elite\li_elite_dmg_starboardwing.3db
material_library = ships\liberty\li_playerships.mat
mass = 5.000000
LODranges = 0, 100, 1300

[Simple
nickname = lim2_elite_dmg_port_wing_cap
DA_archetype = ships\liberty\li_elite\li_elite_dmg_portwing.3db
material_library = ships\liberty\li_playerships.mat
mass = 5.000000
LODranges = 0, 100, 1300

[Simple
nickname = lim2_elite_dmg_Spoiler_cap
DA_archetype = ships\liberty\li_elite\li_elite_dmg_spoiler.3db
material_library = ships\liberty\li_playerships.mat
mass = 5.000000
LODranges = 0, 100, 700

[Simple
nickname = lim2_elite2_dmg_Spoiler_cap
DA_archetype = ships\liberty\li_elite2\li_elite2_dmg_spoiler.3db
material_library = ships\liberty\li_playerships.mat
mass = 5.000000
LODranges = 0, 100, 1300

[Simple
nickname = lim2_elite_dmg_Engine01_cap
DA_archetype = ships\liberty\li_elite\li_elite_dmg_engine01.3db
material_library = ships\liberty\li_playerships.mat
mass = 5.000000
LODranges = 0, 100, 1300

[Simple
nickname = lim2_elite_dmg_Engine02_cap
DA_archetype = ships\liberty\li_elite\li_elite_dmg_engine02.3db
material_library = ships\liberty\li_playerships.mat
mass = 5.000000
LODranges = 0, 100, 1300
</source>
</data>

<data file="data\equipment\market_ships.ini" method="sectionreplace">
<section>
[BaseGood
base = Li03_02_base
</section>
<dest>
marketgood = le_package, 2, -1, 1, 1, 0, 1, 1
</dest>
<source>
marketgood = lem2_package, 13, -1, 1, 1, 0, 1, 1
</source>
</data>

<data file="DATA\EQUIPMENT\misc_equip.ini" method="append">
<source>
[Power
nickname = lim2_elite_power01
ids_name = 0 ;GENERATESTRRES("Defender Mk II Power Plant"
ids_info = 0 ;GENERATEXMLRES("<?xml version="1.0" encoding="UTF-16"?><RDL><PUSH/><TEXT>Defender Mk II Power Plant</TEXT><PARA/><TEXT> </TEXT><PARA/><TEXT> Energy Capacity: 2323</TEXT><PARA/><TEXT> Regeneration Rate / sec: 243</TEXT><PARA/><PARA/><POP/></RDL>"
volume = 0.000000
mass = 10
DA_archetype = equipment\models\hardware\li_fusion_reactor.3db
material_library = equipment\models\hardware.mat
capacity = 2323
charge_rate = 243
thrust_capacity = 1000
thrust_charge_rate = 100
lootable = false
</source>
</data>
</script>

You can put that in a file with a .xml extension and put it in your mod. Obviously, you can modify the stats however you want to. This particular mod changes the defender at Battleship Rio Grande to an Mk II. If you wanted to add the ship to another base, for example on Planet Pittsburg, you'd change the section where it says:

<data file="data\equipment\market_ships.ini" method="sectionreplace">
<section>
[BaseGood
base = Li03_02_base
</section>
<dest>
marketgood = le_package, 2, -1, 1, 1, 0, 1, 1
</dest>
<source>
marketgood = lem2_package, 13, -1, 1, 1, 0, 1, 1
</source>
</data>

to:

<data file="data\equipment\market_ships.ini" method="append">
<section>
[BaseGood
base = Li01_02_base
</section>
<source>
marketgood = lem2_package, 13, -1, 1, 1, 0, 1, 1
</source>
</data>

Post again if any of that was confusing or you have any other problems

I have become one with my computer. It is a feeling of ecstasy...the perfect blend of logic and emotion. I have reached...Nerdvana!

Edited by - Overkill on 8/3/2005 10:55:29 PM

Post Thu Aug 04, 2005 8:52 am

Hey, I just figured out the problem. Under the goods.ini I accidently had one of the [Good tags deleted. And it so happened to be right under the Defender package so it was trying to read both packages as the Defender package lol. I gave it a shot and now it works fine. Thank you so much and I'm sorry to have bothered you over a stupid mistake on my part lol.


Edited by - RaphMyst on 8/4/2005 10:33:36 AM

Return to Freelancer General Editing Forum