idbeholdME 398 Posted February 19, 2022 Share Posted February 19, 2022 (edited) I'd like to make weather effects occur more often and to last longer. The way it works by default (from observation), at least in the first act area, is that the game randomly selects some "squares" of the map where a weather effect applies. As long as you are in the square, the weather effect lasts. It is quite easy to find the boundary line where taking one step in a direction will stop the rain after a couple of seconds and taking one step back will start it again. But as you are moving most of the time, you only get to enjoy the rain for like 20 or 30 seconds, before you exit the square. Again, this is how it behaves in act 1 areas. I remember it raining/storming nearly constantly in the Swamps. Is there a way to increase the number of these squares where weather effects are happening? Optimally into larger blobs, so a larger area of the map would be covered by it instead of singular squares? I'd assume that the density/occurrence of these "weather squares" is set per area somewhere. The question is, if it's hardcoded or changeable in some file? It just makes it feel really out of place when there is rain occurring in exactly 1 square area of Thylisium and nowhere else around. Edited February 19, 2022 by idbeholdME Link to comment
Hooyaah 2,836 Posted February 19, 2022 Share Posted February 19, 2022 As far as I am aware, one may only turn off or on the weather phenomenon. Link to comment
Popular Post Flix 5,124 Posted February 19, 2022 Popular Post Share Posted February 19, 2022 Poke around in scripts\server\weather.txt. It's as you say, weather spawns per sector like an enemy. This is why it seems to stop abruptly if you move around a lot. I've never tried to alter this file myself but you may get some results. I personally keep weather turned off in the options menu because of how buggy it feels. mgr.addWeather (1,28,0,{ -- these are the sector coordinates: x,y,z. z being overworld (0), dungeon level 1 (-1) or dungeon level 2 (-2) type = 2, density = 30, frequency = 15, hours = 16777215, } ) 2 1 Link to comment
Popular Post idbeholdME 398 Posted February 19, 2022 Author Popular Post Share Posted February 19, 2022 (edited) 15 hours ago, Flix said: Poke around in scripts\server\weather.txt. It's as you say, weather spawns per sector like an enemy. This is why it seems to stop abruptly if you move around a lot. I've never tried to alter this file myself but you may get some results. I personally keep weather turned off in the options menu because of how buggy it feels. mgr.addWeather (1,28,0,{ -- these are the sector coordinates: x,y,z. z being overworld (0), dungeon level 1 (-1) or dungeon level 2 (-2) type = 2, density = 30, frequency = 15, hours = 16777215, } ) Damn, can't believe I missed this file... So wait. Does that mean that every single sector (square) has it's own settings? Damn, Is there a coordinate map available somewhere so I could test in a specific area? I assume that: type - would be the type of weather (rain, snow, storm etc.) density - how intense/visible the weather is? No idea honestly. It is between 10 and 100, meaning it is probably a percentage. frequency - no idea because it seems the squares are determined on game session start and don't change (at least from me running around). Also a percentage. Could be the chance for the weather effect to happen? As the minimum value here is 1 (compared to 10 in density), it sounds about right (1% chance of a square having a weather effect). hours - doesn't seem to matter as almost everything is set to this value. There are some other values for some coordinates, but like 99% of them have the 16777215. Or could it specify the time of the day when weather can appear? I could toy around with it but without a coordinate map, it would be very difficult. EDIT: Gonna try a brute force method. Backup the original file and set frequency for every coordinate to 100 Putting 100 for frequency everywhere definitely increased the squares it rains in, but interestingly enough, it's not on all the time. Now it seems like it rains in every other square, but it still gets interrupted most of the time upon entering a new sector. Density affects a couple of things. It now rains everywhere like it does in the Swamps It also increases the volume of the rain. At 100, it is really audible. And it also affects the footsteps. With density on 100, every step sounds like it does in the swamp. Like stepping into a huge puddle. It also determines how much darker does it get when it rains. type is the weather type: NOTE: By default, all enabling weather in the game options does is that it allows for the very small, occasional gusts of wind (visible on PhysX particles). This happens regardless of the set weather type. 1 seems to do nothing. Probably used to set no weather for a square when weather is turned on. The only thing that happens with this are the default gusts. 2 is wind. At density 100, you can actually hear the wind howling in the background. PhysX particles are flying around wildly and trees and grass are swaying strongly in the wind. 3 is rain. Setting the type to 3 everywhere actually makes it rain in every single square in the game. Running around, it is raining non-stop. 4 is thunder storm. Rain (3) + thunder and lightning (6) + wind (2). Screenshot from Thylisium bridge. 5 - no idea. This weather type is never used in the vanilla file. But considering that 6 DOES something and is also not used anywhere, it might actually do something. 6 is also never used in the game but testing it, it enables lightning ONLY. No rain, just thunder strikes and flashes :O 7 is snow. Ever wondered what it'd look like if it snowed in Thylisium? 8 is never used in game normally. Testing it out, it gives snow (7) + lightning and thunder (6) + wind (2). All three once. Past 8, there doesn't seem to be any effect so it is most likely the final one. Really can't spot what 5 does, if anything. So to sum it up: type = the type of weather. See the list above. frequency = the actual % chance the square will have a weather effect. From observation, this seems to be determined on game start/first sector load and remains that way until you quit. It doesn't re-roll this chance every time you enter the sector. Scratch that. Once you get far enough so that the sector actually unloads and then come back to make it load again, the chance is re-rolled. Just had that happen to me. density = determines the severity of the weather effect hours = no idea But to make something that would make sense and consistency would require going through all the main map squares one by one and tuning them to one's desire xD. I'm probably just going to increase the frequency where the numbers are very low (1 or 5) and keep the rest. I doubt there is a way to do this in a non-static way, so just fine tuning the numbers is really the only option. If there was a coordinates map, one could create a custom weather for various areas but that's about it. Edited February 19, 2022 by idbeholdME 1 1 Link to comment
Flix 5,124 Posted February 19, 2022 Share Posted February 19, 2022 19 minutes ago, idbeholdME said: Is there a coordinate map available somewhere so I could test in a specific area? Here this is what I use with the sector editor tool, works as a standalone image as well: https://drive.google.com/file/d/1b6EUCxZH9lPbLGAj3OiQGQW7gkXtNo4T/view?usp=sharing 1 Link to comment
Lindor 460 Posted February 19, 2022 Share Posted February 19, 2022 13 hours ago, idbeholdME said: 1 seems to do nothing. Probably used to set no weather for a square when weather is turned on. The only thing that happens with this are the default gusts. 2 is wind. At density 100, you can actually hear the wind howling in the background. PhysX particles are flying around wildly and trees and grass are swaying strongly in the wind. 3 is rain. Setting the type to 3 everywhere actually makes it rain in every single square in the game. Running around, it is raining non-stop. 4 is thunder storm. Rain (3) + thunder and lightning (6) + wind (2). Screenshot from Thylisium bridge. 5 - no idea. This weather type is never used in the vanilla file. But considering that 6 DOES something and is also not used anywhere, it might actually do something. 6 is also never used in the game but testing it, it enables lightning ONLY. No rain, just thunder strikes and flashes :O 7 is snow. Ever wondered what it'd look like if it snowed in Thylisium? 8 is never used in game normally. Testing it out, it gives snow (7) + lightning and thunder (6) + wind (2). All three once. Past 8, there doesn't seem to be any effect so it is most likely the final one. Really can't spot what 5 does, if anything. The weather flags are saved in scripts/shared/defines.txt. I remember them from my journey through all the .txt files for scripting my tools. Since they're binary and your list is decimal I guess you'll have to take log_2() to make sense of them. Seems like 5 was intended for earthquakes. 1 Link to comment
idbeholdME 398 Posted February 19, 2022 Author Share Posted February 19, 2022 (edited) 5 hours ago, Lindor said: The weather flags are saved in scripts/shared/defines.txt. I remember them from my journey through all the .txt files for scripting my tools. Since they're binary and your list is decimal I guess you'll have to take log_2() to make sense of them. Seems like 5 was intended for earthquakes. Hmmm. So 0 should do something too? Could it be a night exclusive effect? Or does it simply force night? Will try later. And regarding earthquakes, it was either not implemented or happens only in some set area. Had no effect in Thylysium and the nearby area. But going by the defines.txt, the entries don't really seem to correspond with the actual in-game effect. I don't see snow in there and it even ends at 128, where log_2(128) results in 7. But from my testing, 8 is still another weather type. Edited February 19, 2022 by idbeholdME Link to comment
Lindor 460 Posted February 19, 2022 Share Posted February 19, 2022 Try (log_2(x))+1. Eight test results, eight entries. Might fit better. Link to comment
Vishanka 236 Posted February 19, 2022 Share Posted February 19, 2022 This is so amazing, I wanted to make my orc region look colder and I edited all the images and now I can have snow as the icing on the cake Thank you for sharing this. 1 Link to comment
idbeholdME 398 Posted February 19, 2022 Author Share Posted February 19, 2022 (edited) So far, I only increased some numbers. Upped the frequency: 1 to 3 3 to 5 5 to 7 Rain definitely occurs much more often now. It could take hours normally to stumble upon a square with rain by default (1% chance). Now I encounter a couple of them every hour (at 3% chance). Makes the weather much more lively. I might try to fiddle with it more later thanks to the map Flix provided. One could actually create regions where a certain type of weather would occur regularly. Like setting a square to a 100% probability of rain, the surrounding ones to 75%, the ones next to those to 50% etc. and create rain-zones, snow-zones etc. Although... If I remember correctly, isn't there a quest in the orc region that affects weather (something about manipulating rain?) Wonder if changing this file could break some scripts. Edited February 19, 2022 by idbeholdME 1 Link to comment
Vishanka 236 Posted February 19, 2022 Share Posted February 19, 2022 I don't think that it will break some scripts. Also multiple weathers apparently can occur at the same time, like snow and wind or rain and wind, I think that's why there are multiple entries for the same sector. The intensity seems to vary while lingering in the same sector, and some weathers like wind and rain approach and fade without leaving the sector. I had snow at 62% and it changes it's intensity all the time but never stopped and it reacts to wind (the snowflakes blow around). Funny, I just wish there was a possibility to assign the weather to larger sectors. 1 Link to comment
Hooyaah 2,836 Posted February 19, 2022 Share Posted February 19, 2022 1 hour ago, idbeholdME said: So far, I only increased some numbers. Upped the frequency: 1 to 3 3 to 5 5 to 7 Rain definitely occurs much more often now. It could take hours normally to stumble upon a square with rain by default (1% chance). Now I encounter a couple of them every hour (at 3% chance). Makes the weather much more lively. I might try to fiddle with it more later thanks to the map Flix provided. One could actually create regions where a certain type of weather would occur regularly. Like setting a square to a 100% probability of rain, the surrounding ones to 75%, the ones next to those to 50% etc. and create rain-zones, snow-zones etc. Although... If I remember correctly, isn't there a quest in the orc region that affects weather (something about manipulating rain?) Wonder if changing this file could break some scripts. This sounds like great material for a new "Weather Mod." 1 Link to comment
idbeholdME 398 Posted February 21, 2022 Author Share Posted February 21, 2022 (edited) On 2/20/2022 at 12:04 AM, Vishanka said: I don't think that it will break some scripts. Also multiple weathers apparently can occur at the same time, like snow and wind or rain and wind, I think that's why there are multiple entries for the same sector. I completely missed that. As I was just brute-forcing numbers everywhere, I just glanced over that. Most sectors seem to have between 1 and 3 occurrences and the frequency usually adds up to 100. Take 1,28,0 for example (the first multi-entry one). Spoiler mgr.addWeather (1,28,0,{ type = 1, density = 100, frequency = 80, hours = 16777215, } ) mgr.addWeather (1,28,0,{ type = 2, density = 30, frequency = 15, hours = 16777215, } ) mgr.addWeather (1,28,0,{ type = 2, density = 60, frequency = 5, hours = 16777215, } ) That I assume would mean that: 80% of the time, there will be no weather effect (frequency 80 for type 1) 15% of the time, it would be be wind with a density 30 (frequency 15 for type 2) 5% of the time, it would be wind with a density 60 (frequency 5 for type 2) So I think that doesn't mean that there can be multiple weather effects at the same time, but the game can ROLL for several effects at once, whenever it checks for the weather. I'd assume it first checks the lowest chance, then the one above it etc. And I wonder what would happen if you went over 100 total. Probably nothing, but haven't tried that yet. That could actually give much more flexibility when it comes to choosing a weather that I originally thought. This would allow to make rainy areas where the intensity and occurrence could vary every time you visit the area. On 2/20/2022 at 12:04 AM, Vishanka said: The intensity seems to vary while lingering in the same sector, and some weathers like wind and rain approach and fade without leaving the sector. Yeah, I was posing around for some screenshots recently, waiting for night to come and rain suddenly just started. So it is entirely possible that in a sector where it was raining, the game re-rolled it and resulted in a rain but with different intensity. But I can't really pinpoint how often or under what conditions the game rolls for the weather effect. It could be the hours parameter, but I still have no idea what it does. One theory could be, that the number is a time in milliseconds. That would make 16777215 result in roughly 4.6 hours, which COULD be the amount of game time (not real time) that the effect will last once it is rolled. After that period, the game re-rolls. Edited February 22, 2022 by idbeholdME Link to comment
Vishanka 236 Posted February 22, 2022 Share Posted February 22, 2022 13 hours ago, idbeholdME said: So I think that doesn't mean that there can be multiple weather effects at the same time, I definitely have wind and snow at the same time and since there is only sometimes wind but always snow I would assume that two enties happen at the same time. But no guarantee that it's the way how it works, just an observation Link to comment
idbeholdME 398 Posted February 22, 2022 Author Share Posted February 22, 2022 (edited) 3 hours ago, Vishanka said: I definitely have wind and snow at the same time and since there is only sometimes wind but always snow I would assume that two enties happen at the same time. But no guarantee that it's the way how it works, just an observation Keep in mind that the default gusts of wind occur no matter the weather type. Weather type 2 is the one to actually apply a wind weather effect to a sector. I just tried setting 2 weather types to 100 frequency for a sector and it always applies only one. Tried 3 and 7 (rain and snow), and it always applied only rain. Between 2 and 7 (wind and snow) it always seems to randomly pick one (if both have frequency at 100). The snow might seem like it's changing, but it's just how the weather effect looks by default. It constantly transitions between a high/low amount of snowflakes. Edited February 22, 2022 by idbeholdME Link to comment
BrucknerHun 5 Posted February 22, 2022 Share Posted February 22, 2022 Wow, this is really promising! Can it be implemented into EE mod? It would be great to see more environmental factors or even lightning! At least increase the chance of occurrence! Just what I was waiting for! Thanks! Link to comment
idbeholdME 398 Posted February 27, 2022 Author Share Posted February 27, 2022 (edited) Also, how would one go about doing the effect that is done in the haunted woods area of Act 2? Everything gets much darker, no matter what time of day it is. I don't think it's a weather effect (checking the relevant sectors), so it's probably done some other way. Any ideas? The Last Watch graveyard for example gets darker than normal night, even when it's full noon. Would be cool to create some areas where Light Radius would actually be kind of useful. Edited February 27, 2022 by idbeholdME Link to comment
Popular Post Flix 5,124 Posted February 27, 2022 Popular Post Share Posted February 27, 2022 Probably the lighting is saved in the .sector file for each sector. Sadly the sector editor can't handle these files, only the .r and .s files within persector.zip. This lets you add static creatures/NPCs and also change the region ID assignment - relevant for music/ambient soundprofile, but little else. If we could edit the .sector files we'd be able to do true map and terrain editing. It's the one thing missing from the modding scene. 2 Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now