More diesel_smoke patch
Moderator: OpenTTD Developers
Re: More diesel_smoke patch
Could you please update the first post SirkoZ?
Re: More diesel_smoke patch
You mean with the latest version?
I guess I could... Always thought it's good enough if I have the link to the latest version in my sig...
I guess I could... Always thought it's good enough if I have the link to the latest version in my sig...
NewGRF: Oil Wells in Temperate terrain now can Increase production, Better vehicle names, Use-able default aircraft, Oil Rig for Snowland and Desert, Speed for Suspension bridges.
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Re: More diesel_smoke patch
Well, most Patchmakers update the latest version in the first post, since thats what the thread is about.
Re: More diesel_smoke patch
Done.
NewGRF: Oil Wells in Temperate terrain now can Increase production, Better vehicle names, Use-able default aircraft, Oil Rig for Snowland and Desert, Speed for Suspension bridges.
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Re: More diesel_smoke patch
Thanks, this helps me A LOT.
Re: More diesel_smoke patch
Crash when the train tries to reverse on a waypoint.
- Attachments
-
- crash.png (47.13 KiB) Viewed 4134 times
Re: More diesel_smoke patch
Thank you for the heads-up. It is already fixed, but I haven't posted the new patch yet because I'm fiddling with some other aspects of it.
I'll have it posted shortly.
I'll have it posted shortly.

NewGRF: Oil Wells in Temperate terrain now can Increase production, Better vehicle names, Use-able default aircraft, Oil Rig for Snowland and Desert, Speed for Suspension bridges.
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Re: More diesel_smoke patch
Here it is - version 3.1 - now finally working as it should.
Trains no longer smoke also when given the turn-around-order and smoking or lack of it is as it should be on stations, no matter which _end setting (far_end/middle/near_end).
I've been fiddlin' around with non-excessive smoking on bridges, but even as it is there are a lot of checks and computations - besides - it's not bothersome at all.
Anyhow - trunk_patches for r20225 and 1-0-2_rel.
Trains no longer smoke also when given the turn-around-order and smoking or lack of it is as it should be on stations, no matter which _end setting (far_end/middle/near_end).
I've been fiddlin' around with non-excessive smoking on bridges, but even as it is there are a lot of checks and computations - besides - it's not bothersome at all.
Anyhow - trunk_patches for r20225 and 1-0-2_rel.
- Attachments
-
- diesel_smoke_sz_3-1_r20225_trunk.patch
- diff
- (3.67 KiB) Downloaded 182 times
-
- diesel_smoke_sz_3-1_1-0-2_trunk.patch
- diff_rel
- (3.66 KiB) Downloaded 177 times
NewGRF: Oil Wells in Temperate terrain now can Increase production, Better vehicle names, Use-able default aircraft, Oil Rig for Snowland and Desert, Speed for Suspension bridges.
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Re: More diesel_smoke patch
Hello SirkoZ,
I have added the new version to my patchpack (testfolder) and all seems to work again.
Thank you for the fixed update.
It is a very nice feature to have.
Have you had some feedback of this getting to trunk at some point in time or have you not yet asked?
I have added the new version to my patchpack (testfolder) and all seems to work again.
Thank you for the fixed update.
It is a very nice feature to have.
Have you had some feedback of this getting to trunk at some point in time or have you not yet asked?
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.
Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.
Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
Re: More diesel_smoke patch
You don't ask dev's, the devs ask you! 

Re: More diesel_smoke patch
Thank you for the kind words. I appreciate you including the patch in your patch pack - only this way more people that perhaps don't know how to apply it to trunk are able enjoy it.ChillCore wrote:Hello SirkoZ,
I have added the new version to my patchpack (testfolder) and all seems to work again.
Thank you for the fixed update.
It is a very nice feature to have.
Have you had some feedback of this getting to trunk at some point in time or have you not yet asked?

As for developers - good one Timmaexx

I don't know what is developers' du jour rationalisation for non-inclusion; the patch still is cosmetic - that says in my first post, they just may be too busy with various bug-reports and other features that involve more drastic changes, but I can't speak in their name.

NewGRF: Oil Wells in Temperate terrain now can Increase production, Better vehicle names, Use-able default aircraft, Oil Rig for Snowland and Desert, Speed for Suspension bridges.
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Re: More diesel_smoke patch
actually, i think they meant vehicles, not sprites. for sprites it is relevant how many different are loaded from grfs, not how many are displayed. but each smoke puff is a vehicle that takes a slot in the pool, and must be processed when moving etc.SirkoZ wrote:their line used to be - this patch increases the number of overall sprites (smoke sprites) on the map too much and so is not feasible for inclusion. From what I know and I never experienced any difficulties with using it - max. sprite number now has been increased (long ago).
Re: More diesel_smoke patch
I'm sorry - yes - you're right, Eddi - smoke puffs are vehicles. Well - still the number of them has since been increased; I could be wrong though.Eddi wrote:actually, i think they meant vehicles, not sprites. for sprites it is relevant how many different are loaded from grfs, not how many are displayed. but each smoke puff is a vehicle that takes a slot in the pool, and must be processed when moving etc.SirkoZ wrote:their line used to be - this patch increases the number of overall sprites (smoke sprites) on the map too much and so is not feasible for inclusion. From what I know and I never experienced any difficulties with using it - max. sprite number now has been increased (long ago).
NewGRF: Oil Wells in Temperate terrain now can Increase production, Better vehicle names, Use-able default aircraft, Oil Rig for Snowland and Desert, Speed for Suspension bridges.
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Re: More diesel_smoke patch
Yes, we definitely meant vehicles. The problem will show especially when you're near the pool's limit (which has not been increased since r1783; more than 5 years ago) and it seems to me that more people are hitting that limit lately than before. So effectively lowering the limit by replacing "useful" vehicles by eye candy vehicles is going to make their savegames unplayable as the extra smoke fills the pool completely and that effectively halts autorenew and autoreplace.
If/when the size of the vehicle pool has been increased considerably the extra "smoke" vehicles would not matter that much anymore as the pool limit would be very very far away.
It might be an idea to "counter" the more smoke, thus the extra "slowdown" of due to more smoke vehicles, patch by another patch adding a setting for disabling those effects all together to make this the set of patches beneficial for those that want a game with as many vehicles as possible, those that don't have a very fast computer and those that want somewhat more realistic smoke/effects [I have not tested that, so it's an assumption I make].
If/when the size of the vehicle pool has been increased considerably the extra "smoke" vehicles would not matter that much anymore as the pool limit would be very very far away.
It might be an idea to "counter" the more smoke, thus the extra "slowdown" of due to more smoke vehicles, patch by another patch adding a setting for disabling those effects all together to make this the set of patches beneficial for those that want a game with as many vehicles as possible, those that don't have a very fast computer and those that want somewhat more realistic smoke/effects [I have not tested that, so it's an assumption I make].
Re: More diesel_smoke patch
Thank you for the clarifications, Rubidium.
Is there any good way (no drastic mods needed) to not treat smoke/eye-candy as vehicles?
For what it's worth - I used to include a smoke reduction switch in there....could put it in again...
Is there any good way (no drastic mods needed) to not treat smoke/eye-candy as vehicles?
For what it's worth - I used to include a smoke reduction switch in there....could put it in again...
NewGRF: Oil Wells in Temperate terrain now can Increase production, Better vehicle names, Use-able default aircraft, Oil Rig for Snowland and Desert, Speed for Suspension bridges.
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Re: More diesel_smoke patch
I thought that was when you have the desire to become a Dev ...Timmaexx wrote: You don't ask dev's, the devs ask you!![]()

Rubidium wrote:Yes, vehicles.Edddi wrote:Umm, vehicles ...SirkoZ wrote: Sprites?
Maybe add a setting to disable smoke effects and related.
Please do.SirkoZ wrote: For what it's worth - I used to include a smoke reduction switch in there....could put it in again...
As Rubidium suggested make it a two stage inclusion.
First a patch that enables disables the vehicle effects. Setting in advanced settings -> enable disable/original behaviour.
Then a patch that lets you select a third option -> Pseudo-realistic aka more_diesel_smoke.
(Or maybe easier and more fun to do, write the second one first and then derive the first one for lubricating the trunk inclusion of the second.

My games are unlikely to hit the vehicle pool limit any time soon but I would love to see a coopgame with triple the amount of vehicles. (Or seeing one of their current big games run at full speed.)
If they can disable the vehicle effects this would be possible without increasing the vehicle pool limit for the moment?
I think you would need to make an entire new class for that to happen. The only thing that can make smoke move the way it does is vehicles for the moment. That is, if I am not mistaking -> shadows and rotors are vehicles too. I think vehicles is fine if the intent is to increase the pool limit later on.SirkoZ wrote: Is there any good way (no drastic mods needed) to not treat smoke/eye-candy as vehicles?
Another question that pops up is: Could this be a clients side settings and could it cause deyncs if the number of vehicles/other class thingies is not the same for all clients?
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.
Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.
Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
Re: More diesel_smoke patch
As far as I know most openttdcoop games don't come even near the vehicle limit, so there is no problem there.ChillCore wrote:My games are unlikely to hit the vehicle pool limit any time soon but I would love to see a coopgame with triple the amount of vehicles. (Or seeing one of their current big games run at full speed.)
If they can disable the vehicle effects this would be possible without increasing the vehicle pool limit for the moment?
It'll cause desync as long as smoke is a vehicle, if smoke would be moved to a different class then it could work. It is however possible to introduce a client setting that hides (as in doesn't draw) the smoke.Another question that pops up is: Could this be a clients side settings and could it cause deyncs if the number of vehicles/other class thingies is not the same for all clients?
Re: More diesel_smoke patch
Well that's nice - I shall make it so.ChillCore wrote: ...Please do.SirkoZ wrote: For what it's worth - I used to include a smoke reduction switch in there....could put it in again...
As Rubidium suggested make it a two stage inclusion.
First a patch that enables disables the vehicle effects. Setting in advanced settings -> enable disable/original behaviour.
Then a patch that lets you select a third option -> Pseudo-realistic aka more_diesel_smoke.
(Or maybe easier and more fun to do, write the second one first and then derive the first one for lubricating the trunk inclusion of the second.)
My games are unlikely to hit the vehicle pool limit any time soon but I would love to see a coopgame with triple the amount of vehicles. (Or seeing one of their current big games run at full speed.)
If they can disable the vehicle effects this would be possible without increasing the vehicle pool limit for the moment?

...
This is encouraging.Yexo wrote:As far as I know most openttdcoop games don't come even near the vehicle limit, so there is no problem there.ChillCore wrote:My games are unlikely to hit the vehicle pool limit any time soon but I would love to see a coopgame with triple the amount of vehicles. (Or seeing one of their current big games run at full speed.)
If they can disable the vehicle effects this would be possible without increasing the vehicle pool limit for the moment?

NewGRF: Oil Wells in Temperate terrain now can Increase production, Better vehicle names, Use-able default aircraft, Oil Rig for Snowland and Desert, Speed for Suspension bridges.
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Re: More diesel_smoke patch
Replying myself - couldn't resist. 
Anyhow - I've finally put it together - v3.2 with regulation back (last diesel_smoke patch that had regulation was back in r15xxx and 2.0b
).
It has 3 regulating states 0 = no smoke is emitted from any train, 1 = small amount of smoke and 2 = diesel_smokin' - the realistic/previous patched amount of puffs/smoke/sparks.
I didn't make it as two patches though because it is so small and settings touch the very workings of it. Besides - with setting 0 = no smoke, puffs/smoke/sparks calculations are even considered, so it really saves that many effect_vehicles and also CPU cycles. As for the latter - even when enabled, bit-shifting is used as often as possible (as I like to do) because it's free on X86 processors (if I recall correctly).
By the way - I'll also post it to FlySpray...
Enjoy!

Anyhow - I've finally put it together - v3.2 with regulation back (last diesel_smoke patch that had regulation was back in r15xxx and 2.0b

It has 3 regulating states 0 = no smoke is emitted from any train, 1 = small amount of smoke and 2 = diesel_smokin' - the realistic/previous patched amount of puffs/smoke/sparks.
I didn't make it as two patches though because it is so small and settings touch the very workings of it. Besides - with setting 0 = no smoke, puffs/smoke/sparks calculations are even considered, so it really saves that many effect_vehicles and also CPU cycles. As for the latter - even when enabled, bit-shifting is used as often as possible (as I like to do) because it's free on X86 processors (if I recall correctly).

By the way - I'll also post it to FlySpray...
Enjoy!
- Attachments
-
- diesel_smoke_sz_3-2_r20356_trunk.patch
- diff
- (7.81 KiB) Downloaded 162 times
NewGRF: Oil Wells in Temperate terrain now can Increase production, Better vehicle names, Use-able default aircraft, Oil Rig for Snowland and Desert, Speed for Suspension bridges.
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Re: More diesel_smoke patch
that can be a serious pitfall.SirkoZ wrote:bit-shifting is used as often as possible (as I like to do) because it's free on X86 processors (if I recall correctly).
firstly, nothing is "free", every action takes some time.
secondly, the compiler can optimise certain actions way better than you can. but for this to work, you must give the description what you really want to do as clear as possible.
for example, a compiler may catch a static multiplication by 2: a*2, and replace it with the fastest alternative possible. that may be a shift: a<<1, or an addition: a+a, or something entirely different, depending on which platform the code will run. in that case, the multiplication is the most portable and most clear piece of code. if you try to "optimise" things by hand, you might obfuscate it enough that the compiler cannot detect these special cases anymore, so the code might even get slower, but at least less maintainable.
Who is online
Users browsing this forum: No registered users and 20 guests