Subsystem

From FreeSpace Wiki
Revision as of 12:20, 9 August 2007 by Wanderer (talk | contribs) (update)
Jump to: navigation, search

Revision information.. Ship.cpp

3.6.x branch: 2.336.2.73
3.7 branch: 2.427


  • All subsystems ship can have must be defined in ships model file (.pof).


FS2 Open, 3.6.x:
  • Animation Code can be applied to the subsystems that consist of submodels, like multi-part turrets.


$Subsystem:

  • The name of the subsystem as defined in .pof file, % of ship's total hitpoints the subsystem has and rotation time (360 degrees) for multi-part turrets. Note: Assinging zero to the %-hitpoint entry causes the subsystem to be without hitpoints, like fighterbays on some capital ships.
  • Syntax: String, Float, Float, name of the subsystem followed by the subsystem hitpoints as % of ships hitpoints and seconds per 360 degree turn. Subsystem name must be the same as described in model file (.pof).
FS2 Open, 3.6.x:
  • Entries can be left empty in which case game uses default values
  • Example: communications, 5, 0.0


$Armor Type:

FS2 Open, 3.6.x:
  • REQUIRES ADDITIONAL TABLE. Defines armor type used for the subsystem. If subsystem armor type is not defined ships armor type is used instead.
  • Syntax: String, as defined in armor.tbl


$Default PBanks:

  • Defines default primary weapon for the turret
  • Syntax: ( "String" )
    • Example: ( "Subach HL-7" )


$PBank Capacity:

FS2 Open, 3.6.x:
  • Defines ammunition capacity of turrets ballistic primary weapon.
  • Syntax: ( Integer )


$Default SBanks:

  • Defines default secondary weapon for the turret
  • Syntax: ( "String" )


$SBank Capacity:

  • Defines ammunition capacity of turrets secondary weapon.
  • Syntax: ( Integer )


$Engine Wash:

  • All engines may use information concerning the engine wash. Engine washes are usually used only with larger vessels.
  • Syntax: String, name as defined in Engine Wash section in ships.tbl
    • Example: Default1000


$AliveSnd:

FS2 Open, 3.6.x:
  • Specifies a sound to play from the subsystem while it is not destroyed.
  • Syntax: Integer or String, name or identification number of the sound as defined in sounds.tbl


$DeadSnd:

FS2 Open, 3.6.x:
  • Specifies a sound to play from the subsystem while it is destroyed.
  • Syntax: Integer or String, name or identification number of the sound as defined in sounds.tbl


$RotationSnd:

FS2 Open, 3.6.x:
  • Does nothing for now
  • Syntax: Integer or String, name or identification number of the sound as defined in sounds.tbl


$AWACS:

  • Sets this subsystem's effective AWACS range. (AWACS reveals stealthed ships, cuts through nebula fog.)
  • Syntax: Float, the maximum range of the AWACS


$Flags:

FS2 Open, 3.6.x:
  • Can be used to sets additional subsystem related properties
  • List of available flags:
  • "untargetable"
    • Subsystem cannot be targetted
  • "carry no damage"
    • Damage caused to the subsystem will not carry over to the parent ship
  • "use multiple guns"
    • Enables 'salvo fire' mode for the turrets. Instead of alternating barrels the turret fires continously from all the barrels.
  • "fire down normals"
    • Forces the turret to fire along the turret normals - regardless of the swarm setting.
  • Syntax: ( "String", "String" )


Animation Code

FS2 Open, 3.6.x:
  • Option for animating the submodels


Case Specific Entries

Turret

  • All turrets require information concerning the weapon mounted to the turret. The entry can be either $Default PBanks for turret primaries (including beams) or $Default SBanks for turret secondaries
FS2 Open, 3.6.x:
  • Animation Code can be used with multi-part turrets.
  • Multiple defined weapons will all fire but the targetting is handled by the first weapon in the list. Multiple beams are not possible. All weapons alternate between the firingpoints of the turret so turrets do not need to have more than one weapon defined no matter how many barrels or firingpoints they have.

Example

$Subsystem: turret01, 1.0, 1.0
$Default PBanks: ( "Terran Turret" )


Engine

Example

$Subsystem: engine01, 5.0, 0.0
$Engine Wash: Default1000