CleverRaven / Cataclysm-DDA

Cataclysm - Dark Days Ahead. A turn-based survival game set in a post-apocalyptic world.
http://cataclysmdda.org
Other
10.46k stars 4.15k forks source link

Fuel consumption increased significantly #19348

Closed Coolthulhu closed 7 years ago

Coolthulhu commented 7 years ago

Fallout from #19275

Fuel consumption will need addressing. At the moment it is pretty heavy.

codemime commented 7 years ago

Fuel consumption was discussed in #15775 (that discussion may be useful here).

Chezzo commented 7 years ago

We figured out on IRC that if you go to /data/json/item/vehicles/engine.json and change lines 18 and 34 to make it read:

"efficiency": 50,

For the first one, and 70 for the latter, makes it have more consumption than we used to, but still feels good.

60 and 80 is about what we had, maybe a bit more consumption.

mugling commented 7 years ago

Plan is to adjust fuel energy density and not efficiency as the latter would prevent implementation of near-future more efficient engine designs or such items and the electric engines already have an upper bound of 100%.

Balancing is probably required and the forum post sets out a sensible approach:

We figured out on IRC

I think you're stretching the idea of consensus a little - all I see is you proposing those values. I want to collect a meaningful range of opinions along with some evidential data. Your thoughts are welcome and actively sought but you need to back them up with the reasoning and data.

Chezzo commented 7 years ago

I wasn't suggesting some sort of consensus, I was just letting people how to get the game back to the one they love.

Toward that goal, Aabbcc made this mod which gets gas, diesel, and batteries, as back to before this as he could.

https://drive.google.com/file/d/0B0btuC1DG_yxelBQOS1rT210TUE/view

Coolthulhu commented 7 years ago

I'd bump it up back at first, we can lower it after figuring out the exact mechanics that affect it the most. "Bundled" nerfs generally don't work too well, unless they only affect the things that are out of line (fuel can't be out of line because there is no comparison). I don't recall there being a concrete justification for the new values, so I assume it's just an initial proposal. We should have acceptance tests for things like that, unless "it's obvious" that the new values "work" or otherwise are explained in a way that makes it obvious it should work.

Going with Aabbcc's ideas may be good for now. It isn't exactly how the old mechanics worked (looks like he just bumped fuel values to 300%, except for batteries which got 150%), but if it's "good enough" then it should suffice. And it keeps diesel's superior storage efficiency, which is a bonus.

mugling commented 7 years ago

I wasn't suggesting some sort of consensus

We figured out on IRC letting people how to get the game back to the one they love

This isn't IRC. Please refer to yourself in the singular form and use non-perjorative language.

except for batteries which got 150%

Is that not a 150x increase which is 150'00% making any reasonably sized electric vehicles defacto free?

This is the problem with balancing the game around 90-tonne megavehicles. Sure we could (and probably should) merge that mod as 'Megavehicles' as it would keep that particular crowd happy but when it comes to balancing the game waiting for feedback via the forum seems a reasonable approach.

Coolthulhu commented 7 years ago

when it comes to balancing the game waiting for feedback via the forum seems a reasonable approach.

So far we have a version that attracts complaints and doesn't have acceptance tests. It's better to make changes like that either gradual or designed. Last fuel change is neither - it is a giant change that severely limits usage of non-muscle engines and judging from the posts, doesn't yet have a theory to back it up.

Is that not a 150x increase which is 150'00% making any reasonably sized electric vehicles defacto free?

OK, looks like 15000% - I thought energy starts at 100. So that battery buff should be skipped. But gas and diesel buffs look reasonable - even during testing, the fuel drops due to just driving around few blocks were noticeable.

Even if we don't have exact values, it's obvious that majority of players at the moment agree we need more energy per unit of fuel than what we have now.

illi-kun commented 7 years ago

I agree with @Coolthulhu, I saw a lot of complains about fuel consumption in russian community.

mugling commented 7 years ago

Even if we don't have exact values, it's obvious that majority of players at the moment agree we need more energy per unit of fuel than what we have now.

There are very few posts as yet on the forum. The values need to go up but this should be based on actual test data using the in-game vehicles. A 150'00% increase to battery suggests either no testing or only using huge vehicles.

I'm going to move that mod to core and provide it with temporary support as otherwise I'm unable to adjust the JSON code without breaking it. It could rapidly become obsolete if the core values go up enough or could survive on as the previously discussed mod providing other support and fixes for huge vehicles.

I agree with @Coolthulhu, I saw a lot of complains about fuel consumption in russian community.

Fuel consumption probably is likely too high. I'm just waiting for actual reliable suggestions as to numbers. The ones proposed here don't explain how they were calculated and one value is out by two orders of magnitude which proves there has been almost no testing.

Ataman commented 7 years ago

I'm having trouble following the recent changes on the engines but my V8 6,5L Gasoline engine turned into a Wankel Engine and my 60L tank at 100% drained in seconds. Couldn't even drive over a bush. My vehicle might be too heavy (6 tons) but even then the engine can't just burn through 60L of gasoline in mere moments.

mugling commented 7 years ago

If reproducible that sounds like a bug. Can you define 'seconds'?

Ataman commented 7 years ago

It's strange, I tried reinstalling tanks and engines without success. I meant real time seconds, it's approx. 2 to 3 ingame minutes.

Starting a new game and spawning fresh vehicles seems to work without issues though, might be time to stop updating or start a new game?

Uploaded the save on my webserver: http://ataman.ch/stuff/Kronborg.zip Tested version is 0.C-19840-gc4e4cc7 Just load, hit drive and try reaching the streets. Watch as the fuel vanishes into a black hole.

ChucklesTheBeard commented 7 years ago

Can confirm Ataman's bug independently, tested in 0.C.r19835.g861087 - ~6500lb van (save transferred from previous version could have something to do with it? 6.5L gasoline engine turned into wankel) drained 0.5L just on engine start, then ~30L in ~20 tiles at minimum speed.

I detached that and the alternator, then replaced it with a large electric motor, which drained 1.2 full storage batteries in about 6 map tiles or so.

Sorry for the lack of precision, I saw this issue before I tried it out and didn't realize that wasn't what this was about!

mugling commented 7 years ago

Which build? There's one with a nasty random corruption bug in circulation and those values are so extreme I think there might be more to this.

mugling commented 7 years ago

Can you try reproducing in the latest build?

Ataman commented 7 years ago

0.C-19840-gc4e4cc7 is the second latest by now (5929)

mugling commented 7 years ago

Cannot reproduce. Can you post a save (you can attach files to comments) with the problem vehicle and a full tank ready to test?

Ataman commented 7 years ago

Kronborg.zip

Sure, didn't realize you can upload files to a comment. Here's the save again.

mugling commented 7 years ago

Sure, didn't realize you can upload files to a comment

It's pretty nifty eh?

mugling commented 7 years ago

You have got a lot of mods installed

RightInfinity commented 7 years ago

I've been testing on 5929 in spawned, fresh regular cars, all with 2L gas engines and one tank 60L tank of fuel, with all the random cargo emptied. The car will only go 11 - 13 maptiles before it runs out of fuel, which is patently rediculous. Before the change to the engines, a standard car with the 2.5L inline-4 only required about 40 units of gas

mugling commented 7 years ago

@Coolthulhu what's traction on snow covered grass? That could be whats going on in @Ataman's save?

Ataman commented 7 years ago

It's pretty nifty eh?

It totally is.

You have got a lot of mods installed

Eh hehe, ye I guess... I hope it's not related but I don't have enough CDDA experience to make a proper guess about that.

mugling commented 7 years ago

You have got a lot of mods installed

I don't think so. I'm more wondering if we have a bug in the traction part of the code?

mugling commented 7 years ago

11 - 13 maptiles

Overmap tiles or reality bubble tiles?

ChucklesTheBeard commented 7 years ago

I've got a save with these mods enabled: more_locations, boats, Tanks, deoxymod, blazemod, StatsThroughSkills, and novitamins

that exhibits the same thing on latest (0.C.r19841.g7e4569c) if it helps: cotton.tar.gz

save created on 0.C.r19721.g82f0627, van set up on pavement, 26.2L in the tank, empty after 4 overmap tiles at full speed.

mugling commented 7 years ago

I don't think it's mods

Coolthulhu commented 7 years ago

@Coolthulhu what's traction on snow covered grass? That could be whats going on in @Ataman's save?

50% of road traction. Actual effects depend on vehicle's k_traction, but sanely constructed vehicle shouldn't have k_traction below ~30%. A deformed mutant of a vehicle built with bicycle wheels might explain it, but it doesn't cover Car-brand-cars running out of gas after 15 overmap tiles.

mugling commented 7 years ago

but it doesn't cover Car-brand-cars running out of gas after 15 overmap tiles.

I can't reproduce that. Can you?

mugling commented 7 years ago

I adding some debugmsg to see what happens with @Ataman's save

mugling commented 7 years ago

but sanely constructed vehicle shouldn't have k_traction below ~30%

Ataman's save has k_dynamics and k_traction ~30%. I think we have a candidate problem.

Coolthulhu commented 7 years ago

k_traction is essentially a multiplier on output power on grass (and dirt etc.).

It may be worth adding messages when the vehicle has lost traction and is grinding the engine to keep up cruise velocity.

RightInfinity commented 7 years ago

Overmap tiles or reality bubble tiles?

Overmap tiles

It appears that the tank mod/vehicle additions mod is fiddling with the fuel economy, as a default save will only use about 120 units of fuel for the same distance (12 overmap tiles)

mugling commented 7 years ago

It appears that the tank mod/vehicle additions mod is fiddling with the fuel economy,

I bet that mod defines gasoline and diesel...

mugling commented 7 years ago

It certainly defines gasoline which would fix your first problem and also explain why its difficult to reproduce now

Ataman commented 7 years ago

Can confirm, new world/game with vehicle additions mod turns vehicles into fuel devouring monsters... EDIT: Only gasoline apparently, diesel's just fine.

Coolthulhu commented 7 years ago

Not fixed, the fuel balance is still nerfed hard and the "huge vehicles" mod is just a bandaid, not a fix.

illi-kun commented 7 years ago

Yeah, and bad thing about "fixing" it by mod is the fact you need to start new game to apply "fix".

mugling commented 7 years ago

Electric engines were problematic prior to the vehicles update so can be considered separately. Possibly we aim to get acceptance tests for velocity sorted and then handle energy usage after that?

The mod is probably going to be required due to the disparity between vehicle sizes - we have 600kg in-game vehicles vs 60 tonne custom designs. It's going to be fairly challenging to come up with any numbers that make both viable at the same time.

I'm going to work on some fuel usage graphs (tiles/L) for different in-game vehicles and we could write acceptance tests for those?

macrosblackd commented 7 years ago

Something to add to the conversation: I've got an immobile generator vehicle for charging batteries, It's using a V-Twin Engine (0.4L) and it drains fuel insanely fast. The only thing it should be powering is an alternator.

Tharn commented 7 years ago

60 tons, that's about the weight of an average modern tank. Such a vehicle doesn't have to be viable -at all- with the parts currently available in vanilla. You're looking at a 1500hp engine.

To give a real-world example for a more reasonable mobile base, a 13,5 ton APC like the M113A3 can run off a 275hp 6-cylinder diesel engine just fine. 66km/h cruise speed, 483km effective range with a 360L diesel tank, that's about 80km per 60L tank. I hope those figures come in handy if you're looking to fix the math.

You may also want to have a look at the Truck Fuel Economy spreadsheet here. 16 tons for a truck is still in the ballpark: https://en.wikipedia.org/wiki/Fuel_efficiency#Fuel_efficiency_of_motor_vehicles

kevingranade commented 7 years ago

60 tons, that's about the weight of an average modern tank. Such a vehicle doesn't have to be viable -at all- with the parts currently available in vanilla. You're looking at a 1500hp engine.

I totally agree with this, if you want a super mega vehicle the limitation is going to be fuel consumption. In return for the benefits of carrying everything with you, you need to find massive amounts of fuel.

If you want to not have these constraints, a mod is appropriate.

jesseking commented 7 years ago

Game-play wise you could create a new class of vehicle reactors (thorium reactors & cells), in some of the bigger labs/military bases as rare drops to power the >50ton class of vehicles without trying to put so much gasoline in the world that fuel economy becomes meaningless for everything else.

This would allow you to keep the relative scarcity of gasoline and fuel efficiency standards you want for the general over-world game from being distorted by the fuel requirements of massive vehicles like Main Battle Tanks, which are frankly not viable in a post-apocalyptic setting.

This would still allow those fantastic vehicles as a challenging end-game build, and the energy density of a thorium cell would be about 26 million times greater than diesel fuel, so a few small, rare drops could keep your mobile fortress crawling along for quite a while. ;)

Coolthulhu commented 7 years ago

In #19689 I described how is fuel consumption broken. tl;dr:

Asmageddon commented 7 years ago

@Chezzo Thank you for the fix!

And yeah, it's definitively broken. A 1t car can use as much as 15L traveling between two relatively distantly spaced cities, I'd wager that my 0.C 13t deathmobile used considerably less.

As a footnote, I feel like having increased the value from 20 to 80 actually improved the fuel usage more than fourfold, is that my imagination or?

Firestorm01X2 commented 7 years ago

Here is the thing. Looks like no one known how to fix current bug. And maybe no one will. It may lead to situation than this bug will exist for 3 months or more. Or maybe for year. Or maybe forever.

Maybe it is time to think about:

Because really, what the point of Prioirity tag in that case?

kevingranade commented 7 years ago

Based on current discussion, the quickest fix is to backport Coolthulu's efficiency test to pre-engine-overhaul code, find some loose acceptance tests based on some standard vehicles, forward-port those changes to the current code, and then tweak engine and/or item weight values until the tests pass. Further major balance changes will require good rationale. Simply applying changes someone says, "feels right" isn't a good solution, if we're regressing, the previous value is a good point to aim for.

keyspace commented 7 years ago

Revert of #19275 (Vehicle propulsion overhaul) might have made this obsolete.

Asmageddon commented 7 years ago

What will happen to that PR, now? This issue aside it seemed like a valuable contribution.

Coolthulhu notifications@github.com wrote:

Closed #19348.

-- You are receiving this because you commented. Reply to this email directly or view it on GitHub: https://github.com/CleverRaven/Cataclysm-DDA/issues/19348#event-917740968

Coolthulhu commented 7 years ago

If @mugling decides to pick it back up and fix the issues, most likely merge. Otherwise unless someone else picks it up (rarely happens), it will be dropped.