Hard Light Productions Forums

Modding, Mission Design, and Coding => The Modding Workshop => Topic started by: warpshadow on September 02, 2007, 04:02:04 pm

Title: Strange Problem
Post by: warpshadow on September 02, 2007, 04:02:04 pm
Hello. I've been lurking for a while now, using this excellent site to start my own mod but I gotta tell ya. It wasn't easy. I kept toying with the idea of joining up every time I encountered a problem I didn't know how to fix but I managed to eventually solve all of them Today I have finally been driven to make an account in order to ask for some needed advice. For three days I have had this problem. It is that whenever I try to change the recharge rate of a weapon nothing happens. I tried changing the power output to values for 1 to 250 and still no difference. I deleted flags, revised the strings table and imported ships from other mods. Still the same. Then I figured that since I was running version 3.6.9 I might as well use the $weapon regeneration rate: posted on the wiki. I keep getting this error message.

Error: ships.tbl(line 189:
Error: Required token = [#End], [$Subsystem:] or [$Name], found [$Weapon Regeneration Rate: 0.04].

File:J:\src\cvs\fs2_open_3_6_9.final\code\Parse\PARSELO.CPP
Line: 659
[This filename points to the location of a file on the computer that built this executable]

Call stack:
------------------------------------------------------------------
------------------------------------------------------------------


My ships table looks like this [it is the original Ulysses model because my first model is still awaiting texture [and kinda sucks  :sigh:]]
Code: [Select]
;  file to indicate all ship types and their physical characteristics (such as physics info, etc)
;  format is a simple form of the mission files
;
;  Some general comments about some of the fields
;
;  Velocities are specified in (freespace) units/second.  You can currently only
;  specify velocities in the linear directions.  Rotational velocities are still
;  currently speified with thrust (until I get this fixed).  Rotation time is the
;  amount of time (in seconds) to complete 1 revolution in the given direction
;  (x is pitch, y is heading, and z is bank).
;
;  Damp affects how quickly you will accel/decel to your target velocity.  Higher damp
;  means slow acceleration and deceleration.  The lower this number, the faster
;  the ship responds.   For example, specifying a value of 0.0 means there is no
;  damping, in other words, people would say, "this has no physics, like Wing
;  Commander."   The more damping, the harder to control, but the more smoothly
;  it moves.
;
;  Accelerations:
;   All the acceleration numbers are damp factors for how fast the thing
;   changes speed.   0 would mean instantaneous velocity changes, and the
;   bigger the number, the slower the acceleration.  Sort of backwards, but...
;   forward_accel - The damp factor for when the ship is trying to go faster
;   forward_decel - The damp factor for when the ship is trying to slow down
;   slide_accel - The damp factor for left/right/up/down/reverse acceleration.
;   slide_decel - The damp factor for left/right/up/down/reverse deceleration.
;
;       Energy Transfer System:
;       $Power Output           =>      energy is produced per second by the ship's reactor
; $Max Oclk Speed         =>      the max forward speed of the ship when 100% energy
;                                       is directed at the engines
; $Max Weapon Eng         =>      how much weapon energy can be stored (related to $Energy Cosumed
;                                       field in weapons.tbl)
;
;       Afterburners:
;        $Afterburner                   => YES if afterburner present, NO otherwise
;
;        The following parameters must be present if $Afterburner is YES, otherwise comment
;   out or delete them:
;
;       +Aburn Max Vel:                 => x,y,z velocity when afterburner engaged
;       +Aburn For accel:               => forward accel when afterburner engaged
;       +Aburn Fuel:                    => fuel capacity of afterburners
;       +Aburn Burn Rate:               => rate in fuel/second that afterburners consume fuel
;       +Aburn Rec Rate:                => rate in fuel/second that afterburners recover fuel
;
;       $Subsystem:                     name, percent_damage, turret_turn_360_time
;               $Default PBanks:        ( "weapon1" "weapon2" )
;               $Default SBanks:        ( "missile1" "missile2" )
;               $SBank Capacity:        ( 50, 100 )
;
; A note regarding ship sounds:
;       The index for ship sounds corresponds to the index in sounds.tbl.
;  If you don't want to assign a sound, put -1 as the index.


#Default Player Ship
$Name: GTF Ulysses
#End
#Engine Wash Info

;; NOTE:  The default MUST be the first entry in the list of engine wash info

$Name: Default
$Angle: 10.0
$Radius Mult: 1.2
$Length: 400
$Intensity: 1.0

$Name: Default100
$Angle: 12.0
$Radius Mult: 1.2
$Length: 100
$Intensity: 1.0

$Name: Default150
$Angle: 10.0
$Radius Mult: 1.2
$Length: 150
$Intensity: 1.0

$Name: Default200
$Angle: 10.0
$Radius Mult: 1.2
$Length: 200
$Intensity: 1.0

$Name: Default300
$Angle: 8.0
$Radius Mult: 1.2
$Length: 300
$Intensity: 1.0

$Name: Default500
$Angle: 7.0
$Radius Mult: 1.2
$Length: 500
$Intensity: 1.0

$Name: Default700
$Angle: 7.0
$Radius Mult: 1.2
$Length: 700
$Intensity: 1.0

$Name: Default800
$Angle: 6.0
$Radius Mult: 1.2
$Length: 800
$Intensity: 1.0

$Name: Default900
$Angle: 6.0
$Radius Mult: 1.2
$Length: 900
$Intensity: 1.0

$Name: Default1000
$Angle: 5.0
$Radius Mult: 1.2
$Length: 1000
$Intensity: 1.0

$Name: Default1100
$Angle: 5.0
$Radius Mult: 1.2
$Length: 1100
$Intensity: 1.0

$Name: Default1500
$Angle: 5.0
$Radius Mult: 1.2
$Length: 1500
$Intensity: 1.0




#End

#Ship Classes

;=====>> TERRANS <<=======
$Name:                          GTF Ulysses
$Short name:            TFight
$Species:                       Terran
+Type:                          XSTR("Space Superiority", 2939)
+Maneuverability:       XSTR("Excellent", 2940)
+Armor:                         XSTR("Light", 2941)
+Manufacturer:          XSTR("Triton / Mekhu", 2942)
+Description: XSTR( " ", 2943)
+Nocreate
$end_multi_text
+Tech Description:
XSTR("Affectionately nicknamed 'The Bat' by its pilots, the GTF Ulysses is a well-designed craft that has had a far longer useful life than its engineers ever imagined. Developed jointly by Terran and Vasudan contractors, the Ulysses was first deployed near the end of the Great War. Its excellent maneuverability and high top speed give it an agility that pilots love, but at a cost of thin armor and a small secondary weapon loadout. The Ulysses is a better choice for offensive missions than defensive ones.", 2944)
$end_multi_text
+Length:          16 m
+Gun Mounts:      4
+Missile Banks:   1
$POF file:                      fighter01.pof
$Detail distance:       (0, 80, 300, 900)
; $ND: 42 42 244
$Show damage:           YES
$Density: 1
$Damp: 0.65
$Rotdamp: 0.4
$Max Velocity:          60.0, 60.0, 145.0                  ;; in x/y/z -- z only specified forward.  use special tokens for backward movement
$Rotation time:         3.0, 3.0, 2.0
$Rear Velocity:         0.0
$Forward accel:         2.0
$Forward decel:         1.7
$Slide accel:           0.02
$Slide decel:           0.02
$Glide: YES
$Expl inner rad:        25.0
$Expl outer rad:        55.0
$Expl damage:           150.0
$Expl blast:            1000.0
$Expl Propagates:       NO                                                      ;; If set to Yes, then when the ship dies, the explosion propagates through it.
$Shockwave Speed:       0.0                                             ;; speed shockwave expands at, 0 means no shockwave
$Allowed PBanks:        ( "LD-16 Fury" "PL-3 'Nova'" )
$Allowed Dogfight PBanks:        (  "LD-16 Fury" )
$Default PBanks:        ( "LD-16 Fury" "LD-16 Fury'" )
$Allowed SBanks:        ( "Rockeye" "Harpoon"  "S-MCA Stalker" )
$Allowed Dogfight SBanks:    (  "Harpoon " )
$Default SBanks:        ( "Harpoon" )
$SBank Capacity:        ( 40 )
$Power Output: 19.0
$Weapon Regeneration Rate: 0.04
$Max Oclk Speed:        240.0
$Max Weapon Eng:        200.0
$Hitpoints:                     300
$Hull Repair Rate: 0.05
$Flags:                         ( "player_ship" "default_player_ship" "gun convergence" "fighter" "in tech database" )
$AI Class:                      Captain
$Afterburner:           YES
+Aburn Max Vel: 0.0, 0.0, 300.0
+Aburn For accel:       0.5
+Aburn Fuel:            300.0
+Aburn Burn Rate:       60.0
+Aburn Rec Rate:        30.0
$Countermeasures:       20
$Scan time:                     2000
$EngineSnd:       128                   ;; Engine sound of ship
$Closeup_pos:           0.0, 0.0, -22
$Closeup_zoom:          0.5
$Shield_icon:           shield-f01
$Ship_icon:                     iconfighter01
$Ship_anim:                     ssfighter01
$Ship_overhead: loadfighter01
$Score:             8
$Trail:
+Offset: -7.75 -2.8 0.75
+Start Width: 0.25
+End Width: 0.05
+Start Alpha: 1.0
+End Alpha: 0.0
+Max Life: 5.0
+Spew Time: 60
+Bitmap: Contrail01
$Trail:
+Offset: 7.75 -2.8 0.75
+Start Width: 0.25
+End Width: 0.05
+Start Alpha: 1.0
+End Alpha: 0.0
+Max Life: 5.0
+Spew Time: 60
+Bitmap: Contrail01
$Subsystem:                     communication,  10, 0
$Subsystem:                     navigation,             10, 0
$Subsystem:                     weapons,                        20, 0
$Subsystem:                     sensors,                        10, 0
$Subsystem:                     engines,                        35, 0

$Name:                          @GTS Hygeia
$Short name:            TSup
$Species:                       Terran
+Tech Description:
XSTR("The GTS Hygeia is the fleet's newest Terran support ship. It is fast and maneuverable, a necessity when trying to dock with fighters in the heat of battle. Triton Dynamics designed the Hygeia class with huge cargo bays for munitions storage, plus the latest magnetic-stasis delivery system for quickly re-supplying combat craft with missiles and bombs. The Hygeia's repair facilities are driven by neural-net AI, for ultra-fast system diagnostics and repair. The high number of warheads carried by the Hygeia makes it a dangerous ship to be near when it blows up.", 3037)
$end_multi_text
$POF file:                      support2t-01.pof
$Detail distance:       (0, 130, 250, 800)
$ND: 236 227 89
$ND: 199 186 52
$Show damage:           YES
$Density:                       1
$Damp:                          0.2
$Rotdamp:                       0.3
$Max Velocity:          0.0, 0.0, 140.0          ;;      We agreed on 60, but we also agreed to decrease 40%.  I lowered from 120 to 70.
$Rotation time:         4.5, 4.5, 3.0
$Rear Velocity:         0.0
$Forward accel:         2.5
$Forward decel:         0.3125            ;;      lower numbers mean faster acceleration.
$Slide accel:           0.0
$Slide decel:           0.0

;; Lots of weapons onboard means big explosion
$Expl inner rad:        100.0
$Expl outer rad:        200.0
$Expl damage:           100.0
$Expl blast:            4000.0
$Expl Propagates:       NO                                                      ;; If set to Yes, then when the ship dies, the explosion propagates through it.
$Shockwave Speed:       0.0                                             ;; speed shockwave expands at, 0 means no shockwave
$Default PBanks:        ()
$Default SBanks:        ()
$SBank Capacity:        ()
$Shields:                       500
$Shield Color: 100 100 255
$Power Output:          1.0
$Max Oclk Speed:        200.0
$Max Weapon Eng:        0.0
$Hitpoints:                     500
$Flags:                         ( "repair_rearm"  )
$AI Class:                      Captain
$Afterburner:           NO
$Countermeasures:       0
$Scan time:                     2000
$EngineSnd:         136                 ;; Engine sound of ship
$Closeup_pos:           0.0, 1.0, -29
$Closeup_zoom:          0.7
$Score: 15
$Subsystem:                     communications,      30, 0.0
$Subsystem:                     engine,                        20,     0.0
$Subsystem:                     sensors,                        10,     0.0
$Subsystem:                     navigation,                        10,     0.0

#End

; $Player Ship Precedence is used in ship selection when a ship specified by the mission
; designer is not available to the player.  The next ship on the list is used in its place
; (assuming that ship is allowed for the player).
;

$Player Ship Precedence: (
"GTF Ulysses"
"GTF Hercules"
"GTB Medusa"
"GTB Ursa"
)


Someone please help this nNo0b!
Title: Re: Strange Problem
Post by: Hades on September 02, 2007, 04:08:31 pm
:welcomegreen::welcomegreen::welcomegreen::welcomegreen::welcomegreen:

It might be the wepons you put for the ship.
Title: Re: Strange Problem
Post by: Mobius on September 02, 2007, 04:11:37 pm
:welcomesilver:

Well, most ships are gone! In order to fix the problem, use only tables coming straight from the mediavps/root VPs. It is worthwile to delete your modified table, I think :)

EDIT: Oh, you preceeded me, Hades. This one won't count  :nod:
Title: Re: Strange Problem
Post by: warpshadow on September 02, 2007, 04:16:09 pm
Well I know it isn't the weapons because those have been working fine in every way but It might be the ships I guess. The GTF Ulysses Is my experiment ship of sorts. The reason the rest of them are gone was because all the clutter was annoying me.  I'll try it with the default .tbl Oh and thanks! :)

P.S weird thing I just noticed. The error tells me that the weapon regeneration rate is on the line 189 when its not??? :wtf:
Title: Re: Strange Problem
Post by: Mobius on September 02, 2007, 04:17:31 pm
1) Try to use tbms. Go check the Wiki :)

2) Yeah, it happens :doubt:
Title: Re: Strange Problem
Post by: warpshadow on September 02, 2007, 04:27:10 pm
Ok, I tried using a tbm and the bug went away! :D
But now I have an entirely new problem! :(
I don't get an error message anymore but changing the value of the regeneration rate doesn't affect the in game ship at all. I even removed my custom tbl entirely!
Title: Re: Strange Problem
Post by: Mobius on September 02, 2007, 04:33:18 pm
Ok, just place the VP in the correct place. If you're using mods, place the tbm in your mod folder. If not, just place it in your FS2 folder(data/tables) :)

Remember that the mediavps count as mods! :D
Title: Re: Strange Problem
Post by: warpshadow on September 02, 2007, 04:38:10 pm
I'm not using any media VPs. It's all core, no mods, vanilla freespace 2. The ships.tbm is in the data/tables section and If I try typing in hull repair or max velocity, they both work This tag alone refuses to work.
Title: Re: Strange Problem
Post by: Mobius on September 02, 2007, 04:40:10 pm
Are you using the tbm correctly? Have you added "+nocreate"?
Title: Re: Strange Problem
Post by: warpshadow on September 02, 2007, 04:42:11 pm
Correction. Changes to the Tbl. file work. Changing the tbm at all does nothing? It's in the freespace/data/tables section? Whats going on?

Edit: oh no I didn't. Where do I put that?

Edit again: Oh wait. It is already there.
Title: Re: Strange Problem
Post by: Wanderer on September 02, 2007, 04:47:59 pm
What is the name of your TBM file? How old 3.6.9 build are you using?
Title: Re: Strange Problem
Post by: warpshadow on September 02, 2007, 04:49:55 pm
The tbm file is just called ships and I don't know how old the 3.6.9 is. I got it a while ago.
Title: Re: Strange Problem
Post by: warpshadow on September 02, 2007, 04:54:41 pm
Does this help at all? Even though I deleted my origional ships folder. If I try to make a mission in FRED it still allows me to give the Ulysses custom weapons.
Title: Re: Strange Problem
Post by: Mobius on September 02, 2007, 04:56:14 pm
The correct name for ship tbms is <insert a name here>-shp.tbm

The "-shp" is important! :)
Title: Re: Strange Problem
Post by: Wanderer on September 02, 2007, 04:56:30 pm
If you read the main wiki page about modular tables then you should notice that 'ships.tbm' is not going to work, however 'ships-shp.tbm' would work. Also it is possible that the entry for setting recharge rates has been added to the 3.6.x branch after the initial 3.6.9 release. Those options - recharge rates - should be found from stable (3.6.9) branch builds compiled after Feb 2007
Title: Re: Strange Problem
Post by: warpshadow on September 02, 2007, 05:06:07 pm
Ohhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh hhhhhhhhhhh.
I tried looking in the wiki but I couldn't find anything on tbms. That would explain a lot.

Okay, I just tried putting the name -shp in it and now the game recognizes it but now the bug is back! :wtf:
Wow this is so confusing. Solve one problem and another comes up.
Title: Re: Strange Problem
Post by: Mobius on September 02, 2007, 05:09:23 pm
It must be connected to your changes, then. I can't think of anything else(without considering old 3.6.9 builds).
Title: Re: Strange Problem
Post by: warpshadow on September 02, 2007, 05:25:12 pm
I just tried completely re-installing 3.6.9 from the SCP forum. Then I made a new data folder and put the TBM in and I got this error message.

Error: ships-shp.tbm(line 208:
Error: Required token = [#End], [$Subsystem:] or [$Name], found [$Weapon Regeneration Rate:   0.90].

File:J:\src\cvs\fs2_open_3_6_9.final\code\Parse\PARSELO.CPP
Line: 659
[This filename points to the location of a file on the computer that built this executable]

Call stack:
------------------------------------------------------------------
------------------------------------------------------------------

Sorry for taking so much of your time guys. :(
Title: Re: Strange Problem
Post by: warpshadow on September 02, 2007, 06:43:11 pm
C'mon. Does anyone know what the heck is going on here? I'm really frustrated here. Apparently this should be working but it's not?
Title: Re: Strange Problem
Post by: Backslash on September 03, 2007, 12:06:17 am
Sorry about your frustration!
I'm pretty sure that error means the build you're using doesn't know about the $Weapon Regeneration Rate feature.  Try a build that is from 2007.02.27 or newer.
If it turns out that's the case, perhaps we should add a small note to the wiki.
Title: Re: Strange Problem
Post by: jr2 on September 03, 2007, 03:05:35 am
http://fs2source.warpcore.org/exes/latest

And, as I've said before elsewhere, the search function on HLPBB and the Wiki suxx0rs.  Use Google custom FS search (http://www.google.com/coop/cse?cx=011755096467377794791%3Azu0j14tp5jy) instead.  :p
Title: Re: Strange Problem
Post by: Wanderer on September 03, 2007, 06:15:26 am
I didn't time stamp the features while writing the wikipage.. Main reasons were just that a) it would have taken a lot longer, b) i assumed that any modder trying the more advanced features would be using 'cutting edge' builds.

And currently it is probably better to go through 'recent builds' forum rather than direct downloads.
http://www.hard-light.net/forums/index.php/board,97.0.html
Title: Re: Strange Problem
Post by: warpshadow on September 03, 2007, 01:57:07 pm
Thank you everyone for your help! :) I got the latest build and the tbm is working fine! As well as fixing the problem I learned a few things as well! So thanks for all the time you bothered to spend on this Noob! Now all I've got to do is pof my first ship since the model is done! Woohoo!

(did I just use an exclamation mark at the end of every sentence? I guess it shows how happy I am!)
Title: Re: Strange Problem
Post by: Excalibur on September 05, 2007, 11:21:28 pm
You forgot one sentence! ;)