.com.unity Forums
  The Official e-Store of Shrapnel Games

This Month's Specials

Raging Tiger- Save $9.00
winSPMBT: Main Battle Tank- Save $6.00

   







Go Back   .com.unity Forums > Shrapnel Community > Space Empires: Starfury

Reply
 
Thread Tools Display Modes
  #1  
Old February 26th, 2004, 02:18 AM

Bluewind5 Bluewind5 is offline
Private
 
Join Date: Feb 2004
Location: Springfield, VA
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Bluewind5 is on a distinguished road
Default Tips: Making new weapon slots.

Just adding new weapon slots and setting firing arcs in is not the enough to make a new weapon slot work. The line:

Slot # Weapon Firing Point := 3

Does not refer to which bay (1-4) the weapon is firing from. And the lines

Slot # Weapon Arc Start := 315
Slot # Weapon Arc End := 45

only refers to the graphically representation of firing arc NOT the actual firing arc.

If you want to add a new weapon with different firing arcs, you need to edit the file SpaceObjects_XFiles.txt for that specific ship.

This file has the actaul firing arc for that firing point of the weapon.

Lets say you want to Modify the firing arc for one of the Light weapons of your Destroyer. It's

Slot 1 Xpos := 214
Slot 1 Ypos := 67
Slot 1 Group Name := Weapon (Light) 1
Slot 1 Comp Type Allowed := Weapon (Light)
Slot 1 Comp Type Abbreviation := W(L)
Slot 1 Comp Box Color Index := 1
Slot 1 Ship Section := Hull
Slot 1 Ship Side Facing := 0
Slot 1 Weapon Firing Point := 1
Slot 1 Weapon Arc Start := 315
Slot 1 Weapon Arc End := 45

First you need to change the firing arc in Main_ComponentConfigurationSlotsPlayer.txt

Change

Slot 1 Weapon Arc Start := 315
Slot 1 Weapon Arc End := 45

To

Slot 1 Weapon Arc Start := 270
Slot 1 Weapon Arc End := 90

That will let you see the firing arc of the weapon correctly on the display. But unless you change the Weapon Firing point for that weapon in SpaceObjects_XFiles.txt, it will still fire in the arc of 315 to 45. To change this open up SpaceObjects_XFiles.txt and look for terran destroyer layout. Look for these lines:

Firing Point 1 X := -96.8204
Firing Point 1 Y := 473.763
Firing Point 1 Z := 23.3792
Firing Point 1 Arc Start := 315
Firing Point 1 Arc End := 45

You have to make the same changes to the Firing Point 1 Arc Start and End to make what you changed in Main_ComponentConfigurationSlotsPlayer.txt. So, after making changes it should look like this:

Firing Point 1 Arc Start := 270
Firing Point 1 Arc End := 90

Now, weapon light 1 will fire in the arc of 270 to 180.

For those of you who want to add new weapons slots and want it to fire form a different point on the ship, you should define a new Weapon Firing Point number for that new weapon slot in Main_ComponentConfigurationSlotsPlayer.txt. After you set the Weapon Arc Start and Weapon Arc End, you need to open up
SpaceObjects_XFiles.txt. Look for the layout of the ship you're modifying. Go to the line
Number Of Firing Points := 4

and increase that by 1 or whatever number of firing points you added. Since we're only adding 1 more weapon. The line should read:

Number Of Firing Points := 5

Next make a new Entry for your new firing point

Firing Point 5 X := -142.405
Firing Point 5 Y := 14.1545
Firing Point 5 Z := 41.1546
Firing Point 5 Arc Start := 225
Firing Point 5 Arc End := 315

The Firing Point 5 X,Y, and Z lines refers to the location of the ship your new weapon will be firing from. Since, I've do not have a progrma to render the ship models, I've been making estimations for x and y. Example, lets say your firing point is located just to the left a a pre-existing weapon firing point. In that case, just subtract a bit from the firing point x value and copy the value from firing point y. Or if your new firing point is directly below a pre-existing firing point, then just copy the value for firing point x and increase the value for firing point y. To make minute adjustments, start a game and buy the ship then hit the "`" right below the ESC key at the top left of your keyboard and type in "SHOWFIRINGPOINTS" and hit the "`" again. This will show all your ship's firing points. If it looks off, just go back to SpaceObjects_XFiles.txt, make changes, restart the game, and buy the ship again.

Remember, the following

The center of the ship is approximately 0,0 (x,y)
The front of the ship points to the positive side of the y-axis.
The rear of the ship poins to the negative side of the y-axis
The left side of the ship is on the negative side of x-axis.
The right side of the ship is on the positive side of the x-axis.

For firing point X
...subtract to the value to shift it to the left, west side
...add to the value to shift it to the right, east side
For firing point y
...add to the value to shift it upwards, north side
...subtract to the value to shift it downwards, south side
For firing point z
...add to the value to raise it, top side of ship
...subtract to the value to lower it, bottom side of ship.

It took me a while to figure all this out but now I ahve a ship with 16 firing points with some firing arcs that are more than 180 degrees. I also read that you'll get less problems with the new firing arcs if it's in increments of 22.5. So don't try to make a firing arc of 10 or 50.

Have fun modding but always remember to back up every file you use before making adjustments.
Reply With Quote
  #2  
Old February 26th, 2004, 08:56 AM
Hok's Avatar

Hok Hok is offline
Corporal
 
Join Date: Feb 2004
Location: Roma, Italy
Posts: 62
Thanks: 0
Thanked 0 Times in 0 Posts
Hok is on a distinguished road
Default Re: Tips: Making new weapon slots.

Very useful. Thanks.
__________________
U.A.
----
Artificial Intelligence is no match for Natural Stupidity
Reply With Quote
Reply

Bookmarks


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT -4. The time now is 10:50 PM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2024, Shrapnel Games, Inc. - All Rights Reserved.