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

Sleeper Ship mod has me stumped

The general place to discuss MOD''ing Freelancer!

Post Sun Jul 24, 2005 6:54 pm

Sleeper Ship mod has me stumped

Alright, im on the final testing of my Sleeper Ship Mod(add the Sleeper Ship to Manhattan) but theres one problem.

Using my mod and OpenSP v1.1, i start at manhattan, go to ship dealer, hit ship dealer icon to buy my wonderful creation and
CRASH

Wort wort wort.

Anyways, whe n I run FLSpit theres no error. Heres the entry:

[7/24/2005 10:34:21 PM
WARNING:General:set_gamma_function() called outside of create_buffers/destroy_buffers
WARNING: Failed to get start location
WARNING: StarSystem::enter(): CLI(1) System(FP7_system)
WARNING: StarSystem::exit(): CLI(1) System(FP7_system)

I assume the last two are due to OpenSP. Second one maybe. First no clue. But no error.

Any idea whats going on?

Post Sun Jul 24, 2005 7:37 pm

Well, canys post the shiparch and goods entries for the ship? Including any specialist equipment like powerplants and engines..

Post Mon Jul 25, 2005 12:17 am

I'm going to repeat myself for the millionth time: if you do not know how to code a ship yet, go get my H-Fuel Tanker Mod. It is a complete XML-based set of scripts that will integrate your ship into the FL game engine with minimal pain, including DLL entries for the name and description strings, a template to use for a custom Icon, etc., etc., etc.

I will be releasing an "uber newbie" version of this sometime after I release version 1.3 of the Toolkit Mod, to make this even easier to understand/use/modify, but it's really not that hard, if you just look at the entries and change where appropriate

Post Mon Jul 25, 2005 7:47 am

Ill try that.

Post Mon Jul 25, 2005 7:52 am

And if you haven't already... go read How to Skin, very carefully... especially the part where it talks about unique naming conventions. If you don't name your objects right, you can cause crash bugs or worse

Post Mon Jul 25, 2005 8:02 am

Argh, the Sleeper Ship has one part. The whole thing. Theres not much to break up into parts, like a nose cone, wings, things like that. Its an egg with a flat aft end, flat sides and rounded prow. Its got one top fin thats the same color as everything else. (actually, its almost like a camo color but no splotches of color)

And your HFuel Tanker has about seven XML files, where I only need two. I dont need to include encounters, modify ship docking speeds, or things like that. Just put a skinned and hardpointed model into the game.

And MACE, heres the entries. Its only the ship.

<script>
<scriptversion>
1.0
</scriptversion>

<data file="data\ships\shiparch.ini" method="append">
<source>
[Ship
ids_name = 0
ids_info = 0
ids_info1 = 0
ids_info2 = 0
ids_info3 = 0
nickname = Sleeper Ship
ship_class = 2
type = FREIGHTER
mission_property = can_use_berths
LODranges = 0, 999999, 999999, 999999, 999999
msg_id_prefix = gcs_refer_shiparch_atransport
DA_archetype = C:\Program Files\Freelancer Mod Manager\mods\Sleeper Ship Mod\DATA\sleeper.cmp
material_library = C:\Program Files\Freelancer Mod Manager\mods\Sleeper Ship Mod\DATA\sleeper.mat
material_library = fx\envmapbasic.mat
envmap_material = envmapbasic
cockpit = C:\Program Files\Freelancer Mod Manager\mods\Sleeper Ship Mod\DATA\enforcer.ini
max_bank_angle = 15
camera_offset = 15, 55
camera_angular_acceleration = 0.050000
camera_horizontal_turn_angle = 23
camera_vertical_turn_up_angle = 5
camera_vertical_turn_down_angle = 30
camera_turn_look_ahead_slerp_amount = 1.000000
pilot_mesh = generic_pilot
nanobot_limit = 70
shield_battery_limit = 80
hit_pts = 16400
hold_size = 2000
explosion_arch = explosion_rh_battleship
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
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
num_exhaust_nozzles = 0
shield_link = l_freighter_shield01, HpMount, HpEngine01, HpShield01
;-- hp_type = hp_thruster, HpThruster01
;-- hp_type = hp_mine_dropper, HpMine01
;-- hp_type = hp_countermeasure_dropper, HpCM01
;-- hp_type = hp_torpedo_special_2, HpTorpedo01 ; Cruise Disruptor Hardpoint
;-- hp_type = hp_torpedo_special_1, HpTorpedo01 ; Torpedo Hardpoint
HP_tractor_source = HpTractor_Source
fuse = prison_burning_fuse, 0.000000, -1
fuse = prison_m01b_damage_fuse, 0.000000, -1
fuse = fuse_ge_prison_death, 0.000000, 1
hp_type = hp_gun_special_9, HpWeapon01, HpWeapon02, HpWeapon03
hp_type = hp_gun_special_8, HpWeapon01, HpWeapon02, HpWeapon03
hp_type = hp_gun_special_7, HpWeapon01, HpWeapon02, HpWeapon03
hp_type = hp_gun_special_6, HpWeapon01, HpWeapon02, HpWeapon03
hp_type = hp_gun_special_5, HpWeapon01, HpWeapon02, HpWeapon03
hp_type = hp_gun_special_4, HpWeapon01, HpWeapon02, HpWeapon03
hp_type = hp_gun_special_3, HpWeapon01, HpWeapon02, HpWeapon03
hp_type = hp_gun_special_2, HpWeapon01, HpWeapon02, HpWeapon03
hp_type = hp_gun_special_1, HpWeapon01, HpWeapon02, HpWeapon03
hp_type = hp_turret_special_8, HpTurret01, HpTurret02, HpTurret03
hp_type = hp_turret_special_7, HpTurret01, HpTurret02, HpTurret03
hp_type = hp_turret_special_6, HpTurret01, HpTurret02, HpTurret03
hp_type = hp_turret_special_5, HpTurret01, HpTurret02, HpTurret03
hp_type = hp_turret_special_4, HpTurret01, HpTurret02, HpTurret03
hp_type = hp_turret_special_3, HpTurret01, HpTurret02, HpTurret03
hp_type = hp_turret_special_2, HpTurret01, HpTurret02, HpTurret03
hp_type = hp_turret_special_1, HpTurret01, HpTurret02, HpTurret03
hp_type = hp_freighter_shield_special_8, HpShield01
hp_type = hp_freighter_shield_special_7, HpShield01
hp_type = hp_freighter_shield_special_6, HpShield01
hp_type = hp_freighter_shield_special_5, HpShield01
hp_type = hp_freighter_shield_special_4, HpShield01
hp_type = hp_freighter_shield_special_3, HpShield01
hp_type = hp_freighter_shield_special_2, HpShield01
hp_type = hp_freighter_shield_special_1, HpShield01
linear_drag = 1
mass = 100000
steering_torque = 1501900032, 1501900032, 1501900032
angular_drag = 13200000000, 13200000000, 13200000000
rotation_inertia = 15000000512, 15000000512, 15000000512
nudge_force = 3000000
</source>
</data>

<data file="DATA\EQUIPMENT\goods.ini" method="append">
<source>
[Good
nickname = Sleeper_hull
category = shiphull
ship = Sleeper Ship
price = 1
ids_name = 0
item_icon = COCKPITS\enforcer\enforcer.ini

[Good
nickname = Sleeper_package
category = ship
hull = Sleeper_hull
addon = ge_s_tractor_01, internal, 1
addon = ge_lbd_engine_01, internal, 1 ; Liberty Dreadnaught Engine
addon = infinite_power, internal, 1 ; Infinite Power Generator
addon = ge_s_scanner_02, internal, 1 ; Deep Scanner
addon = shield03_mark08_fr, HpShield01, 1 ; Adv. Aegis Fr. Shield (Positron Class 8)
addon = contrail01, HpContrail01, 1 ; Contrail
addon = contrail01, HpContrail02, 1 ; Contrail
addon = contrail01, HpContrail03, 1 ; Contrail
addon = contrail01, HpContrail04, 1 ; Contrail
addon = contrail01, HpContrail05, 1 ; Contrail
addon = LargeWhiteSpecial, HpRunningLight01, 1 ; Large White Special
addon = LargeWhiteSpecial, HpHeadlight01, 1 ; Large White Special
addon = LargeWhiteSpecial, HpHeadlight02, 1 ; Large White Special
addon = DockingLightRedSmall, HpDockLight01, 1 ; Docking HpDockLight Red Small
addon = DockingLightRedSmall, HpDockLight02, 1 ; Docking HpDockLight Red Small
</source>
</data>

<data file="DATA\Missions\mShipProps.ini" method="append">
<source>
[mShipProps
archetype_id = Nickname
prop = can_use_berths
</source>
</data>

<data file="DATA\Equipment\market_ships.ini" method="sectionreplace">
<section>
[BaseGood
base = Li01_01_base
</section>
<dest>
marketgood = lf_package, 1, -1, 1, 1, 0, 1, 1
</dest>
<source>
marketgood = Sleeper_package, 1, -1, 1, 1, 0, 1, 1
</source>
</data>

</script>

The directories for the .cmp and .mat are only that specific so I can see if it is going to work. Which, for some reason, it hasnt.

Post Mon Jul 25, 2005 8:29 am

Erm... you mean that you just covered some random geometry with one tilemap? Bleah.

At any rate, besides the aesthetics, here are some things that are obviously wrong. Lines in bold are old and wrong, lines not are right.

nickname = Sleeper Ship
Erm... you cannot use spaces or non-alphanumeric characters in names- the only valid characters are "0-9", "a-Z" and "_". So if you didn't do that right, go back to your CMP and MAT and name everything properly.
And if you'd read my Tutorial you'd realize that, because I go on and on at LENGTH about naming conventions, and give you an example ship with good names to look at in MS3D

nickname = sleeper_ship

LODranges = 0, 999999, 999999, 999999, 999999
LODranges = 0, 10000 (putting it higher won't work, if this is flyable).

DA_archetype = C:\Program Files\Freelancer Mod Manager\mods\Sleeper Ship Mod\DATA\sleeper.cmp
material_library = C:\Program Files\Freelancer Mod Manager\mods\Sleeper Ship Mod\DATA\sleeper.mat


note: do not dump files into the root of your mod... that's uber-lazy... and I will make fun of you
DA_archetype = ships\sleeper\sleeper.cmp
material_library = ships\sleeper\sleeper.mat

num_exhaust_nozzles = 0

Just leave that out if you don't want engine flames. Or remove the flame/trail entries from the Engine. Or both.

shield_link = l_freighter_shield01, HpMount, HpEngine01, HpShield01

Um... no! If you want more than one Shield, make multiple HpShield points. Do not re-use other hardpoints. HardCMP will let you make as many as you want... HpShield02, etc... sheesh.

fuse = prison_burning_fuse, 0.000000, -1
fuse = prison_m01b_damage_fuse, 0.000000, -1
fuse = fuse_ge_prison_death, 0.000000, 1


These Fuses are not suitable for something that doesn't have break-off parts, and may cause crashes when this ship dies. Not only that, but you're calling them at -1, which is bad- just call them at the maximum hitpoints of the ship.

ship = Sleeper Ship

Once again... no.
ship = sleeper_ship

ids_name = 0
item_icon = COCKPITS\enforcer\enforcer.ini


Um... what is this... c'mon... please don't tell me that you think that an ids_name of 0 is going to give you a valid description string, or that refering to an INI for an Icon is going to work...

[mShipProps
archetype_id = Nickname
prop = can_use_berths


[mShipProps
archetype_id = sleeper_ship
prop = can_use_berths

...although if this is roughly to scale, that oughtta be rather amusing to watch, if you haven't... say... used the code in the H-Fuel Tanker Mod that fixes docking problems for a lot've large ships...

You're welcome

Post Mon Jul 25, 2005 12:34 pm

fuse = prison_burning_fuse, 0.000000, -1
fuse = prison_m01b_damage_fuse, 0.000000, -1
fuse = fuse_ge_prison_death, 0.000000, 1

These Fuses are not suitable for something that doesn't have break-off parts, and may cause crashes when this ship dies. Not only that, but you're calling them at -1, which is bad- just call them at the maximum hitpoints of the ship.



Would there be a difference if I just got rid of those three lines?

Anyway, thanks for your help.
Somebody needs to make an app that does this...

I followed your instruction, fixed the problems you had the good grace to point out, but im stuck with a cursed ArchDB error.
Ya know, the omnipresent error that says it cannot find a twelve digit number.

Edited by - versoth on 7/25/2005 2:14:15 PM

Post Mon Jul 25, 2005 9:30 pm

If you're getting archdb errors, then you're referring to something that doesn't exist. The CMP name, shield reference, and MAT reference all have to be right. So, for example... if you've mis-named your CMP "sleeper ship.cmp"... you'll have an archdb error.

Post Tue Jul 26, 2005 3:40 am

Yeah, the folder is "sleeper ship mod/"..

Post Tue Jul 26, 2005 3:56 am

Heh... well, yeah, that'd do it too. Gotta use strict alphanumeric naming conventions everywhere if you want your mods to work. Names of objects, guns, the fuzzy dice in the cockpit... all need to have proper names

Post Wed Jul 27, 2005 2:33 pm

Fuzzy Dice in the cockpit? You can do that?

Well, i know that yes you can but can you make it move as you turn? That would be hilarious!

Post Wed Jul 27, 2005 6:37 pm

YAY i got it to work. Well, it didnt crash. Four things to fix first.

1) (and this one is hilarious) I buy my wonderful ship, launch, and notic something odd. my ship is flying SIDEWAYS! (cue hilarious laughter)
2) My ship is about the size of a Rhino. I thoght that it would be about seven times that size and I gave it the LIberty Dreadnaught engine effect. The effect(its still flying sideways, mind you) is about twice the size of my Sleeper.

3) That tilemap is HORRENDUS! Argh was right, a solid color is a bad idea.

4) As stated before, its way too small. Does FLModelTool resize .cmp's and .sur's?

Post Wed Jul 27, 2005 7:28 pm

1. The "sideways" thing can be fixed by re-exporting it correctly. It should be facing "forwards" and "upside down"

2. Told you... tilemaps look like butt unless done extremely carefully.

3. Yes, FLModel Tool will resize it and the SUR, and if you hardpoint it before scaling, it'll move the hardpoints automagically

Post Wed Jul 27, 2005 8:25 pm

Yeah, its got to be upside down, with you facing the ship from its left hand side.

Return to Freelancer General Editing Forum