Starship Soccer - Universal Constants
The game world provides access to many of the universal constants used
to simulate the physics of starship soccer.
This enables teams to make decisions based on real values rather than
fudge factors, and means that constants can be altered to liven things
up a bit!
Arena constants
ssc_minX, ssc_minY,
ssc_maxX, ssc_maxY
The bounds of the arena.
MinX, MinY is the bottom left-hand corner.
ssc_centreX, ssc_centreY
The centre of the arena.
ssc_width, ssc_height
The size of the arena.
Default: 280m by 200m
Configurable range: 100m by 100m to 1000m by 1000m
ssc_friction, ssc_frictionPerFrame,
ssc_frictionPerSecond
The friction constant of the arena.
Default: 0.25
Configurable range: 0 to 1.0
Game constants
ssc_framesPerSecond,
ssc_secondsPerFrame
How many frames there are in a second. Each team gets processed once per
frame
Default: 50 frames per second, 0.02 seconds per frame
ssc_shipsPerTeam
How many ships on each side (when the game starts)
Default: 3 ships
Configurable range: 1 - 10 ships
ssc_maxGameTime
How long before Extra-Time, in seconds
Default: 120 seconds
Configurable range: 0 - 3600 seconds
ssc_maxExtraTime
How long extra time lasts, in seconds
Default: 60 seconds
Configurable range: 0 - 3600 seconds
ssc_betFraction
What fraction of your rating you bet in a match
Default: 0.05
ssc_initialRating
The rating given to virgin teams
Default: 100
Starship constants
ssc_starshipTurnRadiansPerSecond,
ssc_starshipTurnRadiansPerFrame
How fast the starships can turn, in radians/second
Default: 3*PI/2 radians/second
Configurable range: PI/8 to 4*PI
ssc_starshipThrustAcceleration,
ssc_starshipThrustAccelerationPerFrame
How fast the ship accelerates in one frame when thrusting (m/s/s) or (m/s/frame)
Default: 25 m/s/s
Configurable range: 5 to 100 m/s/s
ssc_starshipRadius
The radius of the ship, in metres
Default: 3m
ssc_starshipMass
The standard mass of a starship, in kg
Default: 200 kg
Configurable range: 10 to 10000 kg
Gun Constants
ssc_gunReloadTime
How long before the gun can reload after firing.
This defines the maximum firing rate.
Default: 0.33s
Configurable range: 0.10 to 60 s
ssc_maxGunTemp, ssc_minGunTemp
The gun's operating temperature range, in degrees.
The gun will not fire when it's temp is outside this range.
Default: 20 through 1200 degrees
Configurable range: 0 through 10,000 degrees
ssc_gunCoolingRate
Degrees/second that the gun loses temperature.
Default: 500 degrees/second
Configurable range: 1 through 10,000 degrees/second
ssc_gunFiringCost
Increase in gun temperature caused by firing
Default: 600 degrees
Configurable range: 0 through 10,000 degrees/second
Ball Constants
ssc_ballRadius
The radius of the ball in metres (when not dead).
Default: 3m
Configurable range: 0.5 to 30m
ssc_deadBallRadius
The radius of the dead ball in metres
Default: 1.5m
Configurable range: 0.5 to 30m
ssc_deadBallZoneRadius
How far away (in metres) from both goals the ball needs to be before it
will return to normal play.
Default: 86m (calculated).
ssc_deadZoneFraction
How far away from both goals the ball needs to be before it will return
to normal play, expressed as a fraction of the diagonal size of the arena.
i.e.
constant( ssc_deadBallZoneRadius ) = n
* sqrt( width * width + height * height ) * constant( ssc_deadZoneFraction
)
Default: 0.25
Configurable range: 0 to 0.45
ssc_ballMass
The standard mass of the ball, in kg.
Default: 100 kg
Configurable range: 1 to 100000 kg
Goal Constants
ssc_goalRadius
The radius of the goal in metres.
Default: 10m
Configurable range: 1 to 40m
ssc_goalMass
The standard mass of the goad, in kg
Default: 800 kg
Configurable range: 1 to 100000 kg
Bullet Constants
ssc_bulletExplosionRadius
When a bullet explodes, anything inside this radius will be affected.
Default: 5
Configurable range: 0 to 10m
ssc_bulletLifespan
How long before a bullet dissipates, in seconds
Default: 1.5s
Configurable range: 0.1 to 10s
ssc_bulletExplosionEnergy
How many Joules of Kinetic Energy is delivered to each target caught in
the bullet's explosion.
Default: 100,000J
Configurable range: 0 to 1,000,000J
ssc_bulletLaunchSpeed
How fast the bullet is launched from the gun
Default: 80 m/s
Configurable range: 10 to 500 m/s
ssc_bulletMass
The mass of the bullet, in kg
Default: 20 kg
Configurable range: 1 to 1000 kg