Line 103:
Line 103:
Open up the [[GMF]] compiler, and make sure Compile on the bottom is checked. In the source filebox select the reference.gmf file. In destination select a file called just anyway you want it to be, but it'd better be short and without spaces. I'll call mine star.gmf. Click on Compile, and hopefully it should compile with no warnings. If not, make sure the [[GMF]] file is not messed up, and there aren't any unnecessary whitespaces in it.
Open up the [[GMF]] compiler, and make sure Compile on the bottom is checked. In the source filebox select the reference.gmf file. In destination select a file called just anyway you want it to be, but it'd better be short and without spaces. I'll call mine star.gmf. Click on Compile, and hopefully it should compile with no warnings. If not, make sure the [[GMF]] file is not messed up, and there aren't any unnecessary whitespaces in it.
−
== 8) Installing the component into RA2 ==
+
== Installing the component into RA2 ==
Make directory in RA2\Components called like the [[GMF]], eg. star. Copy the compiled [[GMF]] in there, and also create a star_preview.bmp (or whatever_preview.bmp). The preview image will be the preview image in the component selecter, it must be 96x72.
Make directory in RA2\Components called like the [[GMF]], eg. star. Copy the compiled [[GMF]] in there, and also create a star_preview.bmp (or whatever_preview.bmp). The preview image will be the preview image in the component selecter, it must be 96x72.
Line 109:
Line 109:
Next, in the Components directory create a file called star.txt (or whatever.txt). THis'll be our file defining the component. I'll paste my example here:
Next, in the Components directory create a file called star.txt (or whatever.txt). THis'll be our file defining the component. I'll paste my example here:
−
name = Star
+
name = Star
−
+
preview = star_preview.bmp
−
preview = star_preview.bmp
+
dir = star
−
+
model = star.gmf
−
dir = star
+
type = weapons
−
+
base = Weapon
−
model = star.gmf
+
styles = Default
−
+
description = Example component.
−
type = weapons
+
damagesounds = sounds\chorus_metal_tink.wav
−
+
normal = false -1 0 0
−
base = Weapon
+
decal = double_slash.tga 0 0 1 .5 .5 1
−
+
attachsound = sounds\cmp_generic.wav
−
styles = Default
+
concussion = .8
−
+
piercing = .3
−
description = Example component.
−
−
damagesounds = sounds\chorus_metal_tink.wav
−
−
normal = false -1 0 0
−
−
decal = double_slash.tga 0 0 1 .5 .5 1
−
−
attachsound = sounds\cmp_generic.wav
−
−
concussion = .8
−
−
piercing = .3
The values you'll want to change are:
The values you'll want to change are:
name - the Name of your component that will show up in the component library. It can be whatever you wish, contain spaces, etc.
name - the Name of your component that will show up in the component library. It can be whatever you wish, contain spaces, etc.
−
preview - The name of the preview bitmap
+
preview - ''The name of the preview bitmap''
−
+
dir - ''the name of the component directory''
−
dir - the name of the component directory
+
model - ''the name of the compiled [[GMF]] file''
−
+
description - ''the component description.''
−
model - the name of the compiled [[GMF]] file
−
−
description - the component description.
== 9) Give yourself a pat on the back ==
== 9) Give yourself a pat on the back ==