Different smoke behaviour indoors and out

This is something I’ve been thinking of a little while, and I might well implement it tonight.

Right now, smoke hangs around for a while. It quickly become quite dangerous as well. Because any explosure to smoke is like being in a building that’s on fire, while in real life smoke rises and (without wind) wouldn’t cause much of a problem… assuming you were outside.

So what I think should be done is that smoke stays and tends to be more intense when generated inside a roofed area, but has much lower intensity, lower chance to appear, and dissipates more quickly when outside.

I like the idea.

I thought we already checked for inside vs. outside in the fire processing code to see how much smoke it generates (and then against outside to see how fast it dissipates).

There already is a check for indoor vs outdoor regarding smoke, you are right. Values could be tweaked though.

One thing I have done in my ice content mod infrastructure wise is change the behavior of smoke in such a way that smoke can’t stack to make thicker smoke. What happens instead is that it tends to spread out more intelligently, since intensity 1 and intensity 1 won’t stack. edit: however, thin smoke and thick smoke can swap places, so there is still a certain inner flow.

I will try and get my infrastructure changes pulled before things move too far forward…

i2amroy, it might already be the case - but if so, I haven’t noticed it. If it is being done, it’s not working terribly well.

Also I might look into adding a very basic implementation of wind.

I think the biggest offender with this is the perpetual clouds of smoke around smokers, it should probably just generate super-thick fields immediately around the smoker and leave it to diffusion to make it into a big cloud.

And yes, indoor fires generate more smoke, and indoor smoke hangs around significantly longer. I think we have campfire-sized fire and smoke generation tweaked to a pretty good value where it’s not an issue anymore if outside.

Are you considering nuking outdoor smoke entirely on the basis that it should just be rising? I don’t really see a problem with that if so.

great idea glyph.

how about if you open windows the smoke dissipates faster?

id like to see smoke affect most non-zombie mobs and not just you. you can use smoke as a weapon.

If you just have the smoke diffuse /from/ the smoker, (the way they originally behaved) it’s not even worth having them in the game, it just doesn’t work, even IF they spend the whole time standing still (and it works even less well if they move at all). If you can come up with a way to make it work (have the smoke instantly auto-diffuse if it would push things over intensity 3, making it effectively spread out significantly better?) that would be cool, but I couldn’t figure out a way to manage it.

And yeah, I was considering mostly nuking outdoor smoke for the exception of very heavy fires like building fires. There would basically have to be a lot of smoke generation for it not to immediately dissipate.

How hard do you think a very basic implementation of wind would be? Just… a direction and “intensity” value of some sort, and the strong the wind the more likely outdoor smoke will move in that direction instead of dissipating?

Might also make smokers a lot cooler.

can you use the smell code to implement wind? it leaves a trail behind you?

I do think the smoke diffusion has changed a LOT since you added the smoker, so you might want to take another look at what it looks like if you just have it generating smoke adjacent to it.

Wind should be reasonably simple to add, it would just add an offset to the various code that calculates smoke and scent diffusion. The tricky-ish part IMO is having smoke pile up against walls, which I expect to look a bit odd with a naieve implementation, and I’m not sure how to fix that.

Regarding wind speed, a really simple way to do it is to have a wind strength ranging from 0-1, and “roll” the actual drift once per turn, that might be perfect actually… So a really strong wind would consistently shift smoke/scent in its direction every turn, while no wind would have no shift, and moderate wind would range from occasionally to consistently shifting smoke/scent on a given turn. I think that could work quite well.

Actually even better to keep everything synchronised would be to invert wind speed and get a “turns/shift” value, and check if current_turn % wind_turns_shift == 0, so 100 turns/shift would see only very occasional shifts, and 10 turns/shift would be fairly frequent, ramping all the way up to a strong wind being 1 turn/shift, which would end up I think with pretty narrow cones of smoke/scent in the direction of the wind.

The other thing to keep in mind is indoor smoke/scent isn’t going to be affected by wind, unless you do some relatively complicated stuff to determine if wind has a path through the indoor area.

It seems to me that strong winds should make smoke dissipate faster, rather than the other way around. Sure, some of it will be blown in the appropriate direction, but you’d generally expect smoke to stick around more when there’s no wind, as opposed to when there is.

But that… isn’t really how smoke works. And isn’t how people expect it to work. Smoke doesn’t “stick around” - it floats away, unless there’s wind pushing it to the ground or a ceiling preventing it from escaping.