[WIP/Req] No Free Travel
Moderators: Scripting / Modding Moderators, Moderators for English X Forum
-
- Posts: 377
- Joined: Mon, 15. Mar 04, 08:07
[WIP/Req] No Free Travel
As the title suggests, no longer shall space travel be free, every ship will require a fuel source.
Why?
I read a post about carriers making no sense in this game due to their being no need to carry a fleet around when the fleet can just fly there as the principle of a carrier is to move light craft around and provide repair and refuelling at great distances away from a station. I also feel the fuel resource would be a fun little immersion thing and add to the gameplay, it would amuse me to occasionally see prolonged engagements come down to the stamina of the fleet or pilot in which case we would occasionally see badly optimised fleets simply begin to run out of fuel during the engagement when larger ships go down that probably carry more fuel for the fighters and also watching fuel mules fly around dropping off fuel to larger craft etc.
Concept Theory
The basic theory I have for this is using the existing fuel wares as a necessary element for travel, with different engines having a lessor/higher fuel draw, this also makes the highways a little more practical. The AI would need to be aware of this and would need to refuel and buy fuel like the player (could hook into repurposing the rearming code for this?) I am not sure how one would accomplish this without trialling some code.
Gameplay wise, each ship would need to carry a fuel source and when/if you run out fuel you need to rely on boost engines to limp around which also now serve as an interesting gameplay element due to the balance between conserving fuel or conserving shields. Carriers see more use as they serve as a fuel and repair dock for light craft, the larger craft would need to rely on hauling fuel or mule craft that are assigned a job (the job being 'Fuel Transporter' and coded so that the transporter locates the nearest fuel source picks up fuel and trades it to M/L/XL class ships which make the job orders) in large scale sector battles to transport fuel between each other or station to ship you get the idea.
Later on when X4 Milestone Update 2.50
I plan on using the Re-supply ships with a few code tweaks to that job instead of making a new selectable job for any trading ship
Optionally but not on the immediate agenda -
Tweaking existing research or adding a new research upgrade which optimises fuel usage.
Now I have limited modding experience with Rebirth and I don't know about you but I hate XML format with fiery passion its a nightmare to do anything without writing six lines of which I could accomplish in Xscript or other languages with just one line.
Why?
I read a post about carriers making no sense in this game due to their being no need to carry a fleet around when the fleet can just fly there as the principle of a carrier is to move light craft around and provide repair and refuelling at great distances away from a station. I also feel the fuel resource would be a fun little immersion thing and add to the gameplay, it would amuse me to occasionally see prolonged engagements come down to the stamina of the fleet or pilot in which case we would occasionally see badly optimised fleets simply begin to run out of fuel during the engagement when larger ships go down that probably carry more fuel for the fighters and also watching fuel mules fly around dropping off fuel to larger craft etc.
Concept Theory
The basic theory I have for this is using the existing fuel wares as a necessary element for travel, with different engines having a lessor/higher fuel draw, this also makes the highways a little more practical. The AI would need to be aware of this and would need to refuel and buy fuel like the player (could hook into repurposing the rearming code for this?) I am not sure how one would accomplish this without trialling some code.
Gameplay wise, each ship would need to carry a fuel source and when/if you run out fuel you need to rely on boost engines to limp around which also now serve as an interesting gameplay element due to the balance between conserving fuel or conserving shields. Carriers see more use as they serve as a fuel and repair dock for light craft, the larger craft would need to rely on hauling fuel or mule craft that are assigned a job (the job being 'Fuel Transporter' and coded so that the transporter locates the nearest fuel source picks up fuel and trades it to M/L/XL class ships which make the job orders) in large scale sector battles to transport fuel between each other or station to ship you get the idea.
Later on when X4 Milestone Update 2.50
I plan on using the Re-supply ships with a few code tweaks to that job instead of making a new selectable job for any trading ship
Optionally but not on the immediate agenda -
Tweaking existing research or adding a new research upgrade which optimises fuel usage.
Now I have limited modding experience with Rebirth and I don't know about you but I hate XML format with fiery passion its a nightmare to do anything without writing six lines of which I could accomplish in Xscript or other languages with just one line.
*modified*
*X3 LiteCube User*
MOD GemFX Real Space Shaders
MOD Variety and Rebalance Overhaul Icon Pack
I lost my Hans and should not be flying Solo.

*X3 LiteCube User*
MOD GemFX Real Space Shaders
MOD Variety and Rebalance Overhaul Icon Pack
I lost my Hans and should not be flying Solo.

-
- Posts: 122
- Joined: Wed, 22. Sep 10, 07:41
Re: [WIP/Req] No Free Travel
sounds interesting, good luck with it)
-
- Posts: 65
- Joined: Mon, 10. Dec 18, 23:51
Re: [WIP/Req] No Free Travel
I wanted to see something like this for some time, I'm waiting to see it work 
Are you planning to use energy/antimatter cells or some new resource? Will travelling through vacuum of space with constant speed require fuel?

Are you planning to use energy/antimatter cells or some new resource? Will travelling through vacuum of space with constant speed require fuel?
-
- Posts: 377
- Joined: Mon, 15. Mar 04, 08:07
Re: [WIP/Req] No Free Travel
Investigating what the X4 law says about fuel sources and what is available in the game as wares and use something, I mean if there is a different ware for each race might use that for that race and make it race specific fuel.
and yes constant speed would use fuel, the idea is based around fuel being required to power the thrusters and etc etc, So logical thing to do to conserve fuel would be to trade energy (boost and lose shield energy) or turn Flight assist off and drift using thurst or boost to build momentum then freely drift between places to conserve fuel. I don't plan on making the usage too harsh I will probably leave the number up to you guys and have it be adjustable in the config.
*modified*
*X3 LiteCube User*
MOD GemFX Real Space Shaders
MOD Variety and Rebalance Overhaul Icon Pack
I lost my Hans and should not be flying Solo.

*X3 LiteCube User*
MOD GemFX Real Space Shaders
MOD Variety and Rebalance Overhaul Icon Pack
I lost my Hans and should not be flying Solo.

-
- Posts: 80
- Joined: Fri, 18. Jan 19, 19:25
Re: [WIP/Req] No Free Travel
I'm just getting into modding, so I am likely wrong about things. But I think this is a cool idea, so I'm gonna put some thoughts out there
Firstly, a few issues I can see coming up quickly - AI ships seem likely to have autopilot on all the time, so they'll always be burning fuel.
Probably more importantly, maybe someone else can answer this, but I have no clue if the resupply AI is working well; it'd be easy for AI ships to end up "stranded".
Maybe ships that are out of fuel can move at like 20-50 m/s, some sort of emergency fuel reserve? Otherwise stranded ships everywhere will become a problem really fast, unless someone writes some sort of rescue ship & logic to rescue ships without fuel. But even with some minimum speed, how good the resupply stuff is works (which I think is still under development), will affect whether this change will break the economy. Similarly, I would recommend energy cells over a faction specific resource - otherwise, running any large trading empire becomes a real pain.
I think it might be possible code it up as being a consumable, e.g. maybe making use of missile storage or the main consumables. The challenge would be consuming it. It'd make for interesting tradeoffs - do I want more missiles or extra range on my warship. But I'm not sure how challenging it would be, just getting into modding myself.
Personally, I think it would be physically more realistic and cooler to have fuel burn when you change your heading or change your speed, but not all the time when flight assist is on. Otherwise it'd just annoy me, but that's personal preference. And it's probably more work to program that way.
Firstly, a few issues I can see coming up quickly - AI ships seem likely to have autopilot on all the time, so they'll always be burning fuel.
Probably more importantly, maybe someone else can answer this, but I have no clue if the resupply AI is working well; it'd be easy for AI ships to end up "stranded".
Maybe ships that are out of fuel can move at like 20-50 m/s, some sort of emergency fuel reserve? Otherwise stranded ships everywhere will become a problem really fast, unless someone writes some sort of rescue ship & logic to rescue ships without fuel. But even with some minimum speed, how good the resupply stuff is works (which I think is still under development), will affect whether this change will break the economy. Similarly, I would recommend energy cells over a faction specific resource - otherwise, running any large trading empire becomes a real pain.
I think it might be possible code it up as being a consumable, e.g. maybe making use of missile storage or the main consumables. The challenge would be consuming it. It'd make for interesting tradeoffs - do I want more missiles or extra range on my warship. But I'm not sure how challenging it would be, just getting into modding myself.
Personally, I think it would be physically more realistic and cooler to have fuel burn when you change your heading or change your speed, but not all the time when flight assist is on. Otherwise it'd just annoy me, but that's personal preference. And it's probably more work to program that way.
-
- Posts: 377
- Joined: Mon, 15. Mar 04, 08:07
Re: [WIP/Req] No Free Travel
All good feedback and points, at this stage I was waiting for 2.0 to drop before doing anything and now it is here I want to spend more time playing get a feel for the game a bit then work on this thing, at very least I intend to figure out what source of fuel. I like your energy cell idea it was what I first thought about using.Cg089 wrote: ↑Mon, 25. Feb 19, 23:19 I'm just getting into modding, so I am likely wrong about things. But I think this is a cool idea, so I'm gonna put some thoughts out there
Firstly, a few issues I can see coming up quickly - AI ships seem likely to have autopilot on all the time, so they'll always be burning fuel.
Probably more importantly, maybe someone else can answer this, but I have no clue if the resupply AI is working well; it'd be easy for AI ships to end up "stranded".
Maybe ships that are out of fuel can move at like 20-50 m/s, some sort of emergency fuel reserve? Otherwise stranded ships everywhere will become a problem really fast, unless someone writes some sort of rescue ship & logic to rescue ships without fuel. But even with some minimum speed, how good the resupply stuff is works (which I think is still under development), will affect whether this change will break the economy. Similarly, I would recommend energy cells over a faction specific resource - otherwise, running any large trading empire becomes a real pain.
I think it might be possible code it up as being a consumable, e.g. maybe making use of missile storage or the main consumables. The challenge would be consuming it. It'd make for interesting tradeoffs - do I want more missiles or extra range on my warship. But I'm not sure how challenging it would be, just getting into modding myself.
Personally, I think it would be physically more realistic and cooler to have fuel burn when you change your heading or change your speed, but not all the time when flight assist is on. Otherwise, it'd just annoy me, but that's personal preference. And it's probably more work to program that way.
Well, the Re-supply is the big question is it not? I don't see how coding using a consumable up over time is going to be that big of a stretch but actually getting to stranded ships is the challenge I think.
Whatever work needs doing I was going to re-write the Resupply ship code anyway if they were the same Logic as most other transport except with different job priorities. I plan was to have ships who get stranded or in code terms, if the fuel commodity stock was zero in the cargo bay of a ship the ship would send out a job req for resupply and how long that took depends I guess how far away the ship was to begin with.
There are a couple of ways I could do this, I could fake it.. as in after some moments have passed the AI is magically refuelled and off it goes on its merry way, or I can completely rely on a real system of a ship to ship travel and exchange, however, I fear too that this would slow the economy down pretty fast and create performance issues. So my concept for this a hybrid of both. If a stranded ship was out of the view of the player (as in a different sector) and is not player owned, and their is no Resupply ship or in the case of a war fleet no Carrier to dock at within the same sector of the stranded ship magically re-stock that ship! However if the player is in the same sector as the stranded ship it would behave the same way, first we check the current sector or nearby sectors (configurable X sectors away from the stranded ship) for a Re-Supply vessel if there is one create a job order and wait for that order to be completed if the player leaves the sector a timer would start before Magic Restock.
I would do this because it saves on CPU calculations and AI pathing keeping it fairly performance friendly and the immersion breaking is not noticeable by the player when the player is not able to visually interact with the ships in question.
I think what I may do for fuel consumption however is something a little bit different, You would require and only burn the consumable when you adjust your speed above a certain % this way if you keep your speed relative to the same speed as inside a station you do not burn fuel but accelerating uses energy and that energy you will need to carry if you want to get around quicker, and t for the first release to keep things fairly simple yet not immersion breaking, I would make the AI simply use the consumable over time rather then code in it doing so over a fixed % of speed however I will decide that depending on whichever is easier to code.
The problem I am already kinda regretting about this concept is I need to learn how to give each ship generated the fuel cell as cargo or the entire universe is going to just be crawling around for a few hours of game time until magic restock kicks in.
*modified*
*X3 LiteCube User*
MOD GemFX Real Space Shaders
MOD Variety and Rebalance Overhaul Icon Pack
I lost my Hans and should not be flying Solo.

*X3 LiteCube User*
MOD GemFX Real Space Shaders
MOD Variety and Rebalance Overhaul Icon Pack
I lost my Hans and should not be flying Solo.

-
- Posts: 80
- Joined: Fri, 18. Jan 19, 19:25
Re: [WIP/Req] No Free Travel
If you make it a consumable (i.e. like drones & missiles), it might (or might not, really not sure) make it harder to code. You'd have to make Fuel a separate ware - not sure if there's a better term for a ship consumable - produced from energy credits, but wharfs/equipment docks/etc produce ship components on demand (For instance, when you build a ship and the station is low on resources, it doesn't say Missing 1 Shield, it says missing 100 shield components or whatever, and I'm pretty sure that's true for consumables as well), so that wouldn't really be a problem in terms of production. Those stations always need energy credits, I think, and thus they could produce Fuel on demand no problem. On the other hand, this would solve your "spawning ships with fuel" challenge - it'd be an XML patch to make all preset loadouts - both used by the player and by the NPC factions - include some amount of Fuel. I don't know if there is a similar mechanism for starting cargo. An additional advantage of this approach is the player can make their ships start with more fuel or with more missiles/other consumables, depending on preference. If done through cargo, it's more of a challenge to allow the player to control the tradeoff (which in that case is cargo space vs range). Also, doing it this way lets you make use of the resupply AI (which again may still be in development) which is supposed to allow ships to restock on missiles or other consumables after use, but doesn't do anything with respect to cargo as far as I know. Again, I'm still learning, may be wrong.
-
- EGOSOFT
- Posts: 1932
- Joined: Wed, 12. Sep 07, 19:01
Re: [WIP/Req] No Free Travel
This is a great idea, but isn't it out of the scope? I mean, I guess it wouls be possible to render ships disabled (as if engine modules are destroyed) in case the fuel gets depleted...
But how do you plan on implementing the action series of refueling and NPCs recognizing the need to refuel?
But how do you plan on implementing the action series of refueling and NPCs recognizing the need to refuel?
-
- Posts: 80
- Joined: Fri, 18. Jan 19, 19:25
Re: [WIP/Req] No Free Travel
That's kind of what I was trying to address in my last post; I was suggesting leveraging the resupply functionality that's part of the game (though still in development I believe) that is designed to handle missiles & drones & laser towers & such.
-
- Posts: 377
- Joined: Mon, 15. Mar 04, 08:07
Re: [WIP/Req] No Free Travel
Will write a better response later today but I was digging around the dumped cat files a d found out where the files are for creating ship types and where the wares are created. Should be possible to add a new ware and create a new task type which can then be fulfilled by either transport or later the re supply ships. Adding stock to stations as a bi product of energy cells appears to be not too hard.
If I understand you correct tho you are saying to make fuel a consumable this not take cargo space but function like other consumable where you can check how much you have but besides drop the item into space does nothing but serve as a req for thrust movement?
Seems doable maybe even easier than a ware. I also feel she it's done I would need to leverage the ui workaround mod and optionally display fuel on the ui.
If I understand you correct tho you are saying to make fuel a consumable this not take cargo space but function like other consumable where you can check how much you have but besides drop the item into space does nothing but serve as a req for thrust movement?
Seems doable maybe even easier than a ware. I also feel she it's done I would need to leverage the ui workaround mod and optionally display fuel on the ui.
*modified*
*X3 LiteCube User*
MOD GemFX Real Space Shaders
MOD Variety and Rebalance Overhaul Icon Pack
I lost my Hans and should not be flying Solo.

*X3 LiteCube User*
MOD GemFX Real Space Shaders
MOD Variety and Rebalance Overhaul Icon Pack
I lost my Hans and should not be flying Solo.
