Difference between revisions of "HowTo:Edit units.csv"

From VsWiki
Jump to: navigation, search
Line 26: Line 26:
 
*Textual_Description
 
*Textual_Description
 
*Hud_image
 
*Hud_image
*Unit_Scale
+
*Unit_Scale - Sets the scaling of the unit in the game
*Cockpit
+
*Cockpit - Points to a cockpit file. Extension <code>.cpt</code>. See also [[HowTo:Edit HUDs]].
**CockpitX
+
**CockpitX - Coordinates where the Cockpit should be in the Unit/Ship (in meters)
**CockpitY
+
**CockpitY - Coordinates where the Cockpit should be in the Unit/Ship (in meters)
**CockpitZ
+
**CockpitZ - Coordinates where the Cockpit should be in the Unit/Ship (in meters)
*Mesh
+
*Mesh - Points to a mesh-file of the ship. Extension <code>.xmesh</code>
**Shield_Mesh
+
**Shield_Mesh - ('''optional''') mesh-file to use for the shield instead of a sphere. Extension <code>.xmesh</code>
**Rapid_Mesh
+
**Rapid_Mesh - ('''optional''') mesh-file to load and use for collisions with other '''units/ships/'''... instead of the Meshfile from above (not drawn) Extension <code>.xmesh</code>
 
**BSP_Mesh
 
**BSP_Mesh
 
**Use_BSP
 
**Use_BSP
Line 132: Line 132:
  
  
<code><'''Unit''' ...> </Unit></code> - Marks the begin and the end of the unit(file)
+
 
* <code>'''Scale'''</code> - Sets the scaling of the unit in the game
 
* <code><'''Cockpit''' .../></code> - Defines a cockpit for the ship.
 
** <code>file</code> - Points to a cockpit file. Extension <code>.cpt</code>
 
** <code>x</code>,<code>y</code>,<code>z</code> - Coordinates where the Cockpit should be in the Unit/Ship (in meters)
 
** See also [[HowTo:Edit HUDs]].
 
 
* <code><'''Meshfile''' .../></code>
 
* <code><'''Meshfile''' .../></code>
** <code>file</code> - Points to a xmesh-file of the ship. Extension <code>.xmesh</code>
+
** <code>file</code> ** <code>texturestarttime</code> - ('''optional''') Defines the starting delay of a mesh animation. See [http://vegastrike.sourceforge.net/forums/viewtopic.php?p=9688#9688 forums] for more.
** <code>texturestarttime</code> - ('''optional''') Defines the starting delay of a mesh animation. See [http://vegastrike.sourceforge.net/forums/viewtopic.php?p=9688#9688 forums] for more.
 
 
*** <code>RANDOM</code> - Random start delay.
 
*** <code>RANDOM</code> - Random start delay.
 
***time until mesh animation starts
 
***time until mesh animation starts
Line 146: Line 140:
 
*** <code>RANDOM</code> - Random start-frame.
 
*** <code>RANDOM</code> - Random start-frame.
 
*** number of start-frame
 
*** number of start-frame
* <code><'''ShieldMesh'''></code> - ('''optional''') xmesh-file to use for the shield instead of a sphere. Extension <code>.xmesh</code>
 
* <code><'''RapidMesh'''></code> - ('''optional''') xmesh-file to load and use for collisions with other units/ships/... instead of the Meshfile from above (not drawn) Extension <code>.xmesh</code>
 
* <code><'''BspMesh'''></code> - ('''optional''') xmesh-file to use for beam and bolt collisions (not drawn) Extension <code>.xmesh</code>
 
 
* <code><'''Mount''' .../></code> - ('''optional''')('''repeatable''') Specifies a weapon mount
 
* <code><'''Mount''' .../></code> - ('''optional''')('''repeatable''') Specifies a weapon mount
 
** <code>weapon</code> - Type of weapon (see '''[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/vegastrike/data4.x/weapon_list.xml?rev=HEAD&content-type=text/vnd.viewcvs-markup weapon_list.xml]''' in the data directory)
 
** <code>weapon</code> - Type of weapon (see '''[http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/vegastrike/data4.x/weapon_list.xml?rev=HEAD&content-type=text/vnd.viewcvs-markup weapon_list.xml]''' in the data directory)

Revision as of 04:22, 1 April 2005

arrow_left.png Create Ships in Wings3D arrow_up.png HowTo Edit Unit Files arrow_right.png

UNITS.CSV

The Units.csv file contains specific information on all Vessels and Installations and Upgrades in VegaStrike.

Units File

The units.csv is a comma delimited text file which can be edited with any spreadsheet program.

NOTE: Microsoft Works has problems with the long description columns. For a free alternative, use OpenOffice.

Columns in Units File

The original desciption of the xunit syntax from hellcatv is located in CVS

The columns of the units.csv file and their description are;

  • Key
  • Directory
  • Name
  • FoFID
  • Object_Type
  • Combat_Role
  • Textual_Description
  • Hud_image
  • Unit_Scale - Sets the scaling of the unit in the game
  • Cockpit - Points to a cockpit file. Extension .cpt. See also HowTo:Edit HUDs.
    • CockpitX - Coordinates where the Cockpit should be in the Unit/Ship (in meters)
    • CockpitY - Coordinates where the Cockpit should be in the Unit/Ship (in meters)
    • CockpitZ - Coordinates where the Cockpit should be in the Unit/Ship (in meters)
  • Mesh - Points to a mesh-file of the ship. Extension .xmesh
    • Shield_Mesh - (optional) mesh-file to use for the shield instead of a sphere. Extension .xmesh
    • Rapid_Mesh - (optional) mesh-file to load and use for collisions with other units/ships/... instead of the Meshfile from above (not drawn) Extension .xmesh
    • BSP_Mesh
    • Use_BSP
    • Use_Rapid
  • Mass
  • Moment_Of_Inertia
  • Convex_Hull_Volume
  • Fuel_Capacity
  • Hull
    • Armor_Front_Top_Right
    • Armor_Front_Top_Left
    • Armor_Front_Bottom_Right
    • Armor_Front_Bottom_Left
    • Armor_Back_Top_Right
    • Armor_Back_Top_Left
    • Armor_Back_Bottom_Right
    • Armor_Back_Bottom_Left
    • Shield_Front_Top_Right
    • Shield_Back_Top_Left
    • Shield_Front_Bottom_Right
    • Shield_Front_Bottom_Left
    • Shield_Back_Top_Right
    • Shield_Front_Top_Left
    • Shield_Back_Bottom_Right
    • Shield_Back_Bottom_Left
    • Shield_Recharge
    • Shield_Leak
  • Warp_Capacitor
  • Primary_Capacitor
  • Reactor_Recharge
  • Jump_Drive_Present
  • Jump_Drive_Delay
  • Wormhole
  • Outsystem_Jump_Cost
  • Warp_Usage_Cost
  • Afterburner_Type
  • Afterburner_Usage_Cost
  • Maneuver_Yaw
  • Maneuver_Pitch
  • Maneuver_Roll
  • Yaw_Governor
  • Pitch_Governor
  • Roll_Governor
  • Afterburner_Accel
  • Forward_Accel
  • Retro_Accel
  • Left_Accel
  • Right_Accel
  • Top_Accel
  • Bottom_Accel
  • Afterburner_Speed_Governor
  • Default_Speed_Governor
  • ITTS
  • Radar_Color
  • Radar_Range
  • Tracking_Cone
  • Max_Cone
  • Lock_Cone
  • Hold_Volume
  • Can_Cloak
  • Cloak_Min
  • Cloak_Rate
  • Cloak_Energy
  • Cloak_Glass
  • Repair_Droid
  • ECM_Rating
  • ECM_Resist
  • Ecm_Drain
  • Hud_Functionality
  • Max_Hud_Functionality
  • Lifesupport_Functionality
  • Max_Lifesupport_Functionality
  • Comm_Functionality
  • Max_Comm_Functionality
  • FireControl_Functionality
  • Max_FireControl_Functionality
  • SPECDrive_Functionality
  • Max_SPECDrive_Functionality
  • Slide_Start
  • Slide_End
  • Activation_Accel
  • Activation_Speed
  • Upgrades
  • Prohibited_Upgrades
  • Sub_Units
  • Sound
  • Light
  • Mounts
  • Net_Comm
  • Dock
  • Cargo_Import
  • Cargo
  • Explosion
  • Equipment_Space
  • Num_Animation_Stages
  • Upgrade_Storage_Volume
  • Heat_Sink_Rating


  • <Meshfile .../>
    • file ** texturestarttime - (optional) Defines the starting delay of a mesh animation. See forums for more.
      • RANDOM - Random start delay.
      • time until mesh animation starts
    • startframe - (optional) Defines the starting-frame of a mesh animation. See forums for more.
      • RANDOM - Random start-frame.
      • number of start-frame
  • <Mount .../> - (optional)(repeatable) Specifies a weapon mount
    • weapon - Type of weapon (see weapon_list.xml in the data directory)
    • size - size class(es)/type(s) and if they are capable of autotracking. The single entries are seperated by spaces. e.g: size="LIGHT MEDIUM AUTOTRACKING"
      • LIGHT
      • MEDIUM
      • HEAVY
      • SPECIAL
      • CAPSHIP-LIGHT
      • CAPSHIP-MEDIUM
      • CAPSHIP-HEAVY
      • AUTOTRACKING
      • SPECIAL-MISSILE
      • LIGHT-MISSILE
      • MEDIUM-MISSILE
      • HEAVY-MISSILE
      • LIGHT-CAPSHIP-MISSILE
      • MEDIUM-CAPSHIP-MISSILE
      • HEAVY-CAPSHIP-MISSILE
    • ammo - how much ammo the gun holds (only needed for ammo needing weapons e.g. missiles,torpedos,...)
    • volume - (optional see "ammo") how much ammo the gun can hold if you refill
    • x,y,z - location of weapon (in meters ;-))
    • ri,rj,rk - (optional) R-vector forward vector) of gun (assume 0,0,1)
    • qi,qj,qk - (optional) Q-vector (up vector) of gun (assume 0,1,0)
  • <Sound> </Sound> - FIXME nothing yet ???
  • <Defense ...> </Defense> - FIXME
    • HudImage - sprite file to use when targetted FIXME relative to what?
    • ExplosionAni - (optional) special explosion to use
    • RepairDroid - (optional) strength of repair system (0-6)
    • ECM - (optional) type of ECM (Electronic Counter Measure)
    • <Armor .../> - Specifies the ships physical armor
      • front - Forward max armor in VSD
      • right - Right armor in VSD
      • left - Left armor in VSD
      • back - Back armor in VSD
    • <Shields .../> - Specifies the ships Shield (electric armor)
      • front - Forward max shields in VSD
      • back - Back shields in VSD
      • recharge - Shield regeneration if not violating speed limit in VSD/s
      • leak - (optional) how much leak these shields have (usually 0%) between 0 and 100
      • left - (optional) Left shields in VSD
      • right - (optional) Right shields in VSD
      • top - (optional) Top shields) in VSD
      • bottom - (optional)bottom shields in VSD
    • <Hull .../> - Specifies the ships Hull
      • strength - Max hull in VSD
    • <Cloak .../> - (optional) Specifies the ships cloak device
      • missing - if 1, then no cloak is here. also missing in abserce of optional tag
      • cloakmin - minimum percentage of cloakedness
      • cloakglass - boolean whether or not effect 2 is used
      • cloakrate - time per second to cloak in decimal per second
      • cloakenergy - how much energy this takes in 100kJ
  • <Stats .../> - Specifies the statics of the ship
    • mass - mass in metric tonnes (kkg)
    • momentofinertia - mass*m*m in (metric tonnes * meter * meter)
    • fuel - amount of fuel
  • <Thrust>...</Thrust> - Specifies the ships thrust
    • <Engine /> - Specifies the ships engine
      • Afterburner - Thrust with afterburners in metric tonnes meters per second squared
      • Forward - Thrust without afterburners in kkg*m/s^2
      • Retro - Reverse thrust in kkg*m/s^2
      • Left - Left thrust in kkg*m/s^2
      • Right - Right thrust in kkg*m/s^2
      • Top - Top thrust in kkg*m/s^2
      • Bottom - Bottom thrust in kkg*m/s^2
    • <Maneuver .../> - Specifies the ships maneuver data
      • yaw - Right yaw in metric tonnes degrees per second squared
      • pitch - Right pitch in kkg*deg/s^2
      • roll - Right roll in kkg*deg/s^2
  • <Computer ...> ... </Computer>-
    • yaw - max yaw in degrees per second
    • pitch - max pitch in dps
    • roll - max roll in dps
    • afterburner - Max safe speed with afterburners in m/s
    • maxspeed - Max safe speed without afterburner in m/s
    • slidestart - (optional) number of tenths of seconds before fully reacting to keyboard (smoothing)
    • slideend - (optional) number of tenths of seconds to stop
    • <Radar .../> - Specifies the ships radar system
      • itts - if the unit has ability to target track with lead
      • color - if unit has color radar
      • range - maximum range of radar
      • error - (optional) currently unused
      • trackingCone - cosine of cone at which guns may track
      • lockcone - cosine of cone at which missiles gain locking time
      • mintargetsize - unused...but supposedly minimum target this can do
  • <Energy> ... </Energy> -
    • <Reactor .../> - Specifies the ships poer unit (reactor)
      • recharge - recharging of reactor in 100 MJ/s
      • limit - max storage of reactor in 100 MJ/s
  • <Jump .../> - (optional)
    • delay - seconds before jump drive initiates
      • jumpenergy - energy to jump
    • wormhole - forces units to teleport upon touching this one
    • missing - boolean whether the jump drive is missing (assumed missing in absence of tag)
  • <description ...>... </description> - (repeatable)
    • combatrole - combat role that the ship has (see ai/VegaPriorities.csv )
    • lang - (optional) Language code for the language the description is written in.
      • e.g lang='DE' for german language
      • See this link for all codes:
      • If no lang attribute is specified the description is meant to be english. (is this correct'?')
    • Some cool description of the ship.
  • <Hold ...> ... </Hold>
    • volume - volume in cargo units
    • <Category ...> ... </Category> - (optional)(repeatable) A category to use from the Vs-MasterPartList'.
      • file -
        • e.g. file="Natural_Products/Natural_Resources"
      • <import .../> (optional)
        • price - price scale (multiplied by price in list)
        • pricestddev - price scale variation (above adjusted by this)
        • quantity - quantity of this sort of cargo
        • quantitystddev - quantity variation
      • <Cargo .../> (optional)(repeatable)
        • file - name of cargo
        • price - price of cargo
        • quantity - ammount of cargo
        • mass - mass in tonnes
        • volume - size of cargo in cargo units
        • description - (optional/unused)
  • <Light .../> - (optional)(repeatable) Specifies an engine-flame/light/glow/whatever on your ship
    • file - meshfile (sans .xmesh) for this engine model
      • e.g. "supernova.bmp" it's actually a xmesh file
    • x,y,z - location of light (in meters ;-))
    • size - size of engine (radius, in meters ;-))
    • red,blue,green - (optional)red/blue/green dye of engine
  • <Dock .../> - (optional)(repeatable) A place where another unit can dock.
    • x,y,z - location of dock (in meters ;-))
    • size - size of dock port (radius, in meters ;-))
    • dockinternal - (optional/unused) whether the dock port makes the ship disappeared. The ship must be smaller than the size of the dock, otherwise it will remain in open space.
  • <SubUnit .../> - (optional)(repeatable) A Subunt is a (not necessarily) small independant part of your unit. In fact the main unit and the subunit are two different ships (units) patched together at a certain point (x,y,z see below). If a subunit is destroyed the remaining parts will fly into space like the remainings of any other ship ... e.g turrets
    • file - unit file that can be referenced frmo toplevel units
    • siz - size class (which sizes it can hold)
    • x,y,z - location of subunit (in meters ;-))
    • ri,rj,rk - (optional) R-vector (forward vector) of subunit (assume 0,0,1)
    • qi,qj,qk - (optional) Q-vector (up vector) of subunit (assume 0,1,0)
    • restricted - (optional) minimum dot with rj that the turret can have so it can't turn inside itself
  • <CockpitDamage .../> - (optional)(repeatable up to 1+NUMGAUGES+MAXVDUS or 29)
    • NOTE: If you have more, strange things may happen, as it will probably overrun the cockpitdamage buffer.
    • damage - float between 0 and 1 depending on the amount of static the vdu has.
  • <Upgrade .../> - (optional)(repeatable) an upgrade unit that adds its stats onto this unit (as if you had bought it from the shop).
    • file - the file to upgrade it with.

Editing Units.csv File

  • Open the units.csv file in a spreadsheet application and if you are adding a new item, add a new line.
  • FIXME ADD INFO
  • Save the file as a csv file.


Example Row



See also


arrow_left.png Create Ships in Wings3D arrow_up.png HowTo Edit Unit Files arrow_right.png