This OXP seeks to add some interest and depth to the way fuel is handled. Firstly, a new commodity has been created, Quirium Fuel, which can be collected using fuel scoops and a Quirium Fuel Processing unit, then sold at stations for profit. Secondly, the way fuel is handled by stations can be controlled by various functions and properties. Fuel can be made available through fuel stations, or even completely unavailable except by scooping it.
A new trade good has been added to the system: Quirium Fuel. This trade good gets its best price at mainly agricultural systems.
|Quirium Fuel||Fuel scooped from a star's corona||30.0||TC|
Three new equipment items have been added to the game.
Quirium Fuel Processors
Cost to install : 450.0 Cr. Techlevel : 4
This device replicates some of the fuel scooping system except, rather than putting the fuel into the main tank, processed fuel is stored in specialised fuel storage containers. The Fuel Processor is automatically activated during the fuel scoop process when the ship's main tank is full.
The Fuel Processor comes equipped with 1 fuel container, so simply by purchasing this item pilots will be able to scoop 1t of quirium fuel.
Quirium Fuel Storage Unit
Cost to install : 120.0 Cr. Techlevel : 3
Fuel storage units can store 1t of Quirium fuel. Until used they will not consume any cargo space. When fuel is scooped and processed the units will expand to hold the fuel.
Quirium Fuel Transfer
Cost to install : 1380.0 Cr. Techlevel : 7
This device is a slightly unstable method of moving fuel from storage and into the main ship tank. Quirium fuel is highly volatile, and the connection between the fuel processor and all storage units is designed to be one-way during flight. The Fuel transfer device is a third party add-on which breaches some of the containment protocols of the storage units in order to extract fuel and dump it in the engines. There is a chance that cargo loss or equipment damage could result from the transfer process. There have been reports of complete ship destruction in extreme cases, but these reports are rare.
To transfer fuel during flight, prime the "Quirium Fuel Transfer" equipment, then press the "n" (activate) key twice to start transferring fuel. Press the "n" key a third time (or use the "b" (mode) key) to stop the process.
A minimum 1t of Quirium fuel will be used regardless of how much is actually transferred to the main tank. Excess fuel is dumped to prevent any additional damage. For example, transferring 0.4LY of fuel will use 1t of Quirium. Transferring 1.2LY of fuel will use 2t.
If fuel stations are enabled for a particular system, they will appear towards the edge of scanner range behind the main station. To get refuelled, simply fly into the station and come to a halt when directed. Fuel will then be transferred. When finished, exit the station and your account will be charged.
Some systems may have introduced a ration system, where a limited amount of fuel is available for purchase at the main station. Once you have purchased your ration, you will be unable to purchase any more fuel in that system until you jump out and come back.
worldScripts.FuelTweaks_FuelEconomy.$addFuelAvailability(ecos : array, govs : array, tl : int[, useRations : boolean])
Adds a economy/government/min techlevel fuel availability setting. "ecos" and "govs" are arrays containing integers between 0 and 7. To ignore the economy or government, pass an empty array. tl is an integer, being the minimum techlevel required, between -1 and 15 (-1 means no techlevel check is performed). useRations is an optional flag indicating that fuel rations will be used at these systems, rather than the standard fuel.
worldScripts.FuelTweaks_FuelEconomy.$setMaxFuelRation(maxVal : int)
Sets the maximum amount of fuel that can be purchased through a non-refuelling stations
Sets an array of allegiance types to control what stations can sell fuel. An empty array means all stations can sell fuel.
worldScripts.FuelTweaks_FuelEconomy.$addFuelSystemOverride(sysID : int, avail : boolean [, useRations : boolean [, maxRation : int]])
Adds a system specific override to the fuel system. avail determines whether fuel will be available for sale. useRations determines whether fuel rationing is in effect. maxRation sets the maximum amount of fuel ration that can be sold.
The following methods control the presence of refueling stations: Note: Refuel stations will not be present if no fuel is available in the system. Note: If a refueling station is present in a system, fuel will not be for sale in other stations.
worldScripts.FuelTweaks_FuelEconomy.$addRefuelStationAvailability(ecos : array, govs : array, tl : int)
Adds a economy/government/min techlevel fuel availability setting. "ecos" and "govs" are arrays containing integers between 0 and 7. To ignore the economy or government, pass an empty array. tl is an integer, being the minimum techlevel required, between -1 and 15 (-1 means no techlevel check is performed) Note: Fuel must be available in the system before a refuelling station can be added.
worldScripts.FuelTweaks_FuelEconomy.$setRefuelStationCostFactor(cf : decimal)
Sets the default cost factor applied to fuel sales at refuelling stations. default 0.15
worldScripts.FuelTweaks_FuelEconomy.$addRefuelStationSystemOverride(sysID : int, avail : boolean, costFactor : decimal)
Adds an refuel station override item for the speficied system ID. avail = true means a refuel station will always be present, false means it will never be present costFactor is the cost factor applied to fuel sales through the refuel station.
worldScripts.FuelTweaks_FuelEconomy.$isFuelAvailable([sysID : int])
Returns true if the passed system ID (or the current system if no value passed) will have fuel fuel available (either at the station itself or via a refuelling station). Otherwise false.
worldScripts.FuelTweaks_FuelEconomy.$fuelRationsInUse([sysID : int])
Returns true if fuel rationing is in use in the passed system ID.
Returns the maximum fuel ration permitted in the passed system ID.
worldScripts.FuelTweaks_FuelEconomy.$isRefuelStationAvailable([sysID : int])
Returns true if the passed system ID (or the current system if no value passed) will have refuelling stations present. Otherwise false. Note: Fuel must be available in the system before a refuelling station can be added.
Resets all fuel settings back to their default.
This work is licensed under the Creative Commons Attribution-Noncommercial-Share Alike 4.0 Unported License. To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/4.0/
With thanks to Thargoid for his fly-through Fuel Station (from the Fuel Station OXP), and to gsagostinho for his amazing textures.
This OXP is discussed at this forum link: http://aegidian.org/bb/viewtopic.php?f=4&t=18947
- Fixed invalid reference bug after exiting witchspace.
- Added missing cost factor to refuel station availability code.
- Message about fuel not being for sale incorrectly being broadcast even when rations are available.
- Added information about fuel availability to the F7 System Data screen.
- Fixed incorrect TL variable reference in various lookup functions.
- Tweaks to checking functions to make them more logical.
- Bug fixes.
- Tweaks to the equipment.plist file.
- Added 5 and 6 ly fuel rations.
- Tweaks to the logic of the various properties to make system clearer.
- Added textures from gsagostinho's updated version of Fuel Stations.
- Added reset function to remove any fuel-related settings currently in use.
- Bug fixes.
- Set the default quantity of Quirium fuel available for purchase at all stations to be zero, to encourage scooping.
- Added the "Quirium Fuel Transfer" equipment item, to allow for fuel to be transferred from cargo to the main tank, but with a risk of cargo and/or equipment damage (and even entire ship destruction!).
- Scooping of Quirium Fuel cargo pods when there is insufficient fuel storage units to hold it will now result in the cargo being auto-ejected.
- Corrected logic for determining when fuel or fuel stations are available.
- Added logic to allow for players without fuel scoops to always have the ability to purchase 4ly fuel rations, even if all other logic says no fuel or rations or fuel stations are allowed in this system.
- Added options and JS methods to control how and where fuel is sold.
- Initial release.
|1.7||2017-08-07||CC BY-NC-SA 4.0||Fuel changes||Mechanics OXPs||phkb||Oolite BB|