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

**Tutorial** - Creating new dynamic weapons

Here you find the different tutorials on editing and MODing Freelancer

Post Thu Apr 08, 2004 8:26 am

Hello, I'm new to modding anything in FL (actuall in any game), but I have an idea for a new weapon that I want to make. I have really no knowledge of programming, and I have NO clue what all those file types are - .cmp, .dll, .ini, .tga, .txm, .ale ...

But I read through this great tutorial, and it made a lot of sense to me, but I have two questions before I start trying to make a new weapon:
1) You say "After you've downloaded the program you can go ahead and open it. If you are using BiniQDU (which is what this tutorial will refer to) press the Open button and go into your root Freelancer folder."
I have SDK 1.3 downloaded and installed (I installed it to run MODs), but I don't know what BiniQDU is. And since I already have SDK 1.3, what do I do with it? Is BiniQDU a program I have to DL?

2)When you say save it periodically, do I save the changes I make over the origial FL gun stats? I mean, if I change the Justice MkI to do say 1200 hull-damage and Reload Delay to 5 (meaning 5 seconds to reload,right?), do I just hit Ctrl-S and save over the original Justice MkI code, or do I do Save As, and save it as another file/folder? And if I am supposed to save in another folder, how do I tell FL to use that folder with my new weapon?

Sorry if I'm annoying, but this is really my first step into tweaking any games ever - I just DLed a ship-creating tutorial last night, but I am not really ready to do all that quite yet :\ So I figured I would start out little by making a new weapon I've always wanted: a Railgun I just want to make sure I know what I'm doing and how to do it before I go hacking into my files.
Thank you

Post Thu Apr 08, 2004 8:10 pm

ro9ue,

if you have SDK there is no need to use BiniQDU.

The reason i say to Save As is because BiniQDU has a glitch that makes it so when you save sometimes, it actually doesnt save. It is still good to save as so you can back up your files incase you mess up the code. after you save it you can just rename both files (rename the original to original_name_1 and name the new one to what the original one was called first)

Post Thu Apr 08, 2004 10:17 pm

EDIT: I deleted this mess b/c I figured out how to make a weapon, but I still have a question regarding saves. I made a System Restore point before I started altering files, so if I mess something up I can go back to it.

When I change things in weapon_equip.ini and those others, I press Ctrl-S. I do not understand how to save two folders (one with regular/untweaked weapon information for MP so I don't get kicked for cheating; the other wich includes my weapon(s) to use in SP) and then be able to switch between those folders. I mean, if I save a folder that has my weapons in it and I play SP for a while with those weapons, how would I switch back to regular FL weapon settings and get rid of my weapons in all those files in order to play MP and not get kicked?

Now I have a problem (but it should be simple ones to fix, with a little advice from someone):
After copying/pasting Justice MkI files for everything needed, I changed the nickname to "sithspit", changed damage, velocity, etc. I switched "requires ammo = true" and I made my own ammo in the [Munitions part. I made a sithspit_ammo good by copynig/pasting/altering the Javelin's [Good layout (I don't really know how to make ammo for sale- it's not in the tut. Could someone give me a few pointers in that please?). I put the sithspit_ammo for sale at Manhattan, Pittsburgh, and Ft. Bush, but it does not appear there. Is ammo exclusively for missiles? If not and I CAN use ammo for a gun, how do I do that?
Thanks

Edited by - Ro9ue on 4/9/2004 6:18:03 PM

Post Fri Apr 09, 2004 4:28 pm

Edit: I combined this post w/above to make more concise and take less room. Any advice appreciated!

Edited by - Ro9ue on 4/9/2004 6:19:31 PM

Post Fri Apr 09, 2004 5:23 pm

I've included this in the main compilation thread.

Nice work

Post Mon May 24, 2004 8:26 am

can you make hull modifiers?
imagine you have different kind of armor classes , and you want the gun to do more hull damage 1 kind of armor then to the other kind

Post Mon May 24, 2004 10:52 pm

FYI... if someone doesn't notice it yet....

lifetime of the munition entry is very dependent in the muzzle_velocity of the gun entry and vice versa... still don't know about missiles tho... it has a very different approach in lifteime.

changing the muzzle_velocity entry will dramatically change the range of an ammo...

example 1...

lifetime = 1
muzzle_velocity = 600
distance = 600

lifetime = 2
muzzle_velocity = 600
distance = 1200

Example 2...

lifetime = 1
muzzle_velocity = 1000
distance = 1000

lifetime = 0.8
muzzle_velocity = 1000
distance = 800

look at the two examples and you can see the dependencies of both lifetime and muzzle_velocity entries in the computation of the ranges/distance of an ammo.


a message from firebase...


Edited by - Sun Striker on 5/24/2004 11:59:09 PM

Post Tue May 25, 2004 2:16 pm

Sun Striker, Lifetime determines range, muzzle_velocity determines speed

About the hull modifiers, im not sure if it is, though I like where you are headed with your idea.

Post Wed May 26, 2004 8:40 am

yes , i can experiment with it so that FL thinks the hull are shield

Post Wed May 26, 2004 9:25 pm

parabolix...

muzzle_velocity is a modifier too... check it out and you will see what i mean..

it will also determine the range of your ammo. I have been editing weapons too and that is what i have found out.

ammo range = muzzle_velocity x lifetime

this is true for guns....

Edited by - Sun Striker on 5/26/2004 10:28:30 PM

Post Mon May 31, 2004 8:16 am

Yeah, I have noticed this, too. I changed a few Topedoes' velocities, and then when I looked in the game, they were close to 2 times as fast as I entered in weapon_equip. I did the opposite, changing their ranges, and their velocities changed in proprtion to the range change.

So I guess they must be proportional to each other.

PS - I just read my old posts in here from a couple months ago, and - wow, was I a newb! I can't tell you guys how thankful I am that you even took time to answer those sorry quetions. Just reading this:
"I have NO clue what all those file types are - .cmp, .dll, .ini, .tga, .txm, .ale ...
I have SDK 1.3 downloaded and installed (I installed it to run MODs), but I don't know what BiniQDU is. And since I already have SDK 1.3, what do I do with it? Is BiniQDU a program I have to DL?...
When you say save it periodically, do I save the changes I make over the origial FL gun stats? ..."
I just burst put laughing! Whew, sorry for being that ignorant and whiny; again, thanks a lot for your patience and help.

Post Sat Jun 26, 2004 8:34 am

I used your tutorial to create my own weapon but when I equipped it it didn't mount properly. The screen says that it's there but it does realise it's mounted.

it won't fire like that and I can equip other weapons on top of it but it still says my weapons name.

Any ideas

EDIT - I got the mounting bit fixed. either the DA_Archetype or the Material_libarary bit was wrong but it won't fire


It's eyes were completly devoid of life,
Empty Orbs that took in the world with an unfeeling gaze,
A thin trail of blood ran from a fresh wound,
But it would not or could not tend to it,
Only one thing ever brought a spark of vitality,
To the eyes of this Tortured Soul:
The Suffering of others.

Edited by - Tortured_Soul on 6/26/2004 12:16:29 PM

Post Sat Jun 26, 2004 11:31 pm

Is it a standard weapon or is it a missile of some kind? First make sure that the ammunition archetype is correct. Is it mounted on any modded ship or with any mods of any sorts? If you'd like, you could send me your code through an email and I can see if there are any errors. If you send an email though make sure it has an obvious subject title so I know its from you and not a spam virus.

Post Sun Jun 27, 2004 4:46 am

i'll put it up here

<data file="data\equipment\weapon_equip.ini" method="append">
<source>
[Munition
nickname = phaser_type_4_ammo
hp_type = hp_gun
requires_ammo = false
hit_pts = 2
hull_damage = 500
energy_damage = 250
weapon_type = W_Laser01
one_shot_sound = fed_phaser
munition_hit_effect = li_laser_01_impact
const_effect = phaser_type_4_proj
lifetime = 3.000000
force_gun_ori = false
mass = 1
volume = 0.000100

[Gun
nickname = phaser_type_4
ids_name = 0 ;GENERATESTRRES("Type 4 Phaser"
ids_info = 0 ;GENERATESTRRES("One step up from the Phaser Type - 3 Rifle, typically mounted on Shuttle's and Light Craft"
DA_archetype = equipment\models\weapons\li_laser_beam.cmp
material_library = equipment\models\li_equip.mat
HP_child = HPConnect
hit_pts = 400
explosion_resistance = 1.000000
debris_type = debris_normal
parent_impulse = 20
child_impulse = 80
volume = 0.000000
mass = 10
hp_gun_type = hp_gun_special_2
damage_per_fire = 0
power_usage = 10000
refire_delay = 0.5
muzzle_velocity = 2000
use_animation = Sc_fire
toughness = 1.300000
flash_particle_name = li_laser_01_flash
flash_radius = 15
light_anim = l_gun01_flash
projectile_archetype = phaser_type_4_ammo
separation_explosion = sever_debris
auto_turret = false
turn_rate = 360
lootable = false
LODranges = 0, 20, 40, 80, 100
</source>
</data>

<data file="data\equipment\weapon_good.ini" method="append">
<source>
[Good
nickname = phaser_type_4
equipment = phaser_type_4
category = equipment
price = 100
item_icon = equipment\models\commodities\nn_icons\EQUIPICON_gun.3db
combinable = false
ids_name = 0 ;GENERATESTRRES("Type 4 Phaser"
ids_info = 0 ;GENERATESTRRES("One step up from the Phaser Type - 3 Rifle, typically mounted on Shuttle's and Light Craft"
shop_archetype = equipment\models\weapons\li_plasma_blaster.cmp
material_library = equipment\models\li_equip.mat
</source>
</data>

<data file="data\equipment\market_misc.ini" method="sectionappend">
<section>
Base = Li01_01_base
</section>
<source>
MarketGood = phaser_type_4, 1, -1, 10, 10, 0, 1
</source>
</data>

<data file="data\fx\beam_effects.ini" method="append">
<source>
[BeamBolt
nickname = phaser_type_4_beam
tip_length = 20
tail_length = 2080
head_width = 2
core_width = 2
tip_color = 255, 255, 0
core_color = 255, 128, 64
outter_color = 255, 128, 64
tail_color = 255, 128, 64
head_brightness = 1
trail_brightness = 1
head_texture = ball
trail_texture = thin
flash_size = 1
</source>
</data>

<data file="data\fx\effects.ini" method="append">
<source>
[Effect
nickname = phaser_type_4_proj
effect_type = EFT_WEAPON_PROJ
vis_beam = phaser_type_4_beam
</source>
</data>

<data file="data\fx\weapons\weapons_ale.ini" method="append">
<source>
[VisEffect
nickname = phaser_type_4_proj
alchemy = fx\weapons\li_plasma_01.ale
effect_crc = -154178588
textures = fx\planetflare.txm
</source>
</data>

<data file="data\audio\sounds.ini" method="append">
<source>
[Sound
nickname = fed_phaser
file = audio\sounds\weapons\FED_PHASER.wav
range = 60, 500
crv_pitch = 9
attenuation = -7
</source>
</data>

It's eyes were completly devoid of life,
Empty Orbs that took in the world with an unfeeling gaze,
A thin trail of blood ran from a fresh wound,
But it would not or could not tend to it,
Only one thing ever brought a spark of vitality,
To the eyes of this Tortured Soul:
The Suffering of others.

Edited by - Tortured_Soul on 6/27/2004 5:47:17 AM

Post Sun Jun 27, 2004 9:40 am

Maybe its because you have the weapon using 10000 energy . It is probably too high for your ship's powerplant to handle, try lowering the energy to 125 then test it. (125 is what it should be , standard energy drain for weapons is 1/4 its damage)

EDIT: Please do email it next time though, it is alot of text to post up in one post, and it is easier to read in an email.



Edited by - parabolix on 6/27/2004 10:42:23 AM

Return to Freelancer Editing Tutorial Forum