Re: How do I automatically turn a skin on or off based on weather information?
Posted: August 5th, 2022, 12:47 am
Can you try and let me know the result
Can you try and let me know the result
Try out tass_co's skin (I didn't try it out so far) to see how is it working. I won't alter his code, but if you want an alternative, here is what I recommend:Pyuahowaito wrote: ↑August 4th, 2022, 10:39 pm I really don't know how to modify the weather skin correctly, this skin is very good I understand the approximate way of working but it is very complicated for me, at the moment I do not know how to correctly make the Rain skin automatically turn on and off according to the humidity provided by the JSBarometer skin1.jpg
Logically you are right balalabalala wrote: ↑August 5th, 2022, 7:41 am I don't really think that activating or deactivating the Rain skin is proper to be done based on the humidity. Better would be in my opinion, to activate it when the weather condition returned by the weather skin says it is raining (as said above).
Please let me know if you are interested.
Usually you can't have two codes of two different skins into one single .ini file. For this you need two different .ini files. If you place them into one single config (folder) you can load only one of them at a time. Placing them in different configs allows you to load both in the same time (only one skin of certain config can be activated in the same time, trying to activate another, deactivates the already activated one).Pyuahowaito wrote: ↑August 5th, 2022, 11:00 pm When working with the code of 2 skins in the same ini, my Windows will be significantly slower and the refresh rate of the skin does not know how to adjust separately, I still think it would be better to separate the skins
This is a simple weather skin, which can be adapted to activate the Rain when the weather condition match the case. Do you want me to adapt it, adding the Rain skin to be activated when it's raining? The location can be simply set up, by changing the lat and long variables in the [Variables] section of the skin.Pyuahowaito wrote: ↑August 5th, 2022, 11:00 pm Balala I don't know if this skin can, it's just that I understand its code more easily. https://www.deviantart.com/catart-1304/art/Aesthetic-weather-0-1-Cat-Art-ft-Creewick-917984819
Yes, please help me add it, if you finish, another snow skin I will learn your code to try it yourself, thank you Balala.balala wrote: ↑August 6th, 2022, 7:25 am Usually you can't have two codes of two different skins into one single .ini file. For this you need two different .ini files. If you place them into one single config (folder) you can load only one of them at a time. Placing them in different configs allows you to load both in the same time (only one skin of certain config can be activated in the same time, trying to activate another, deactivates the already activated one).
If you have two different skins, you can adjust their Update value distinctly. But in any case most of the skin (however there might be some exceptions) shouldn't load too much a more or less decent CPU.
This is a simple weather skin, which can be adapted to activate the Rain when the weather condition match the case. Do you want me to adapt it, adding the Rain skin to be activated when it's raining? The location can be simply set up, by changing the lat and long variables in the [Variables] section of the skin.
And one more: if you are interested, the same author (killall-q) published a while ago another Snowing skin. It also can be added to be activated when it's snowing.
Just please let me know if you are interested and and want me to add these skins.
Ok, I added the Rain and Snowfall skins (both are located into the newly added AestheticWeather\RainSnow config). Also added the needed resources to the @Resources folder. For instance there is a Drop.png file, along with the needed two script files, which are placed to the @Resources\Script\ folder. See that I also added a previously not existing [MeasureStr] measure to the code of the skin. This measure is meant to activate the proper skin from the Rain and Snowfall, or deactivate them when it's the case.Pyuahowaito wrote: ↑August 6th, 2022, 11:23 am Yes, please help me add it, if you finish, another snow skin I will learn your code to try it yourself, thank you Balala.
I tested a lot of rainy places based on the weather information provided by the website, and most of it can automatically start rain skin work accurately and stably (although I haven't seen the moment when the Rain skin automatically stops yet).Once again, I would like to thank Balala for her meticulous answers and help, and for letting me know exactly how skin-to-skin interactions and some of the things that need attention, and thank you for Tass_co letting me know another way.balala wrote: ↑August 6th, 2022, 8:16 pm Ok, I added the Rain and Snowfall skins (both are located into the newly added AestheticWeather\RainSnow config). Also added the needed resources to the @Resources folder. For instance there is a Drop.png file, along with the needed two script files, which are placed to the @Resources\Script\ folder. See that I also added a previously not existing [MeasureStr] measure to the code of the skin. This measure is meant to activate the proper skin from the Rain and Snowfall, or deactivate them when it's the case.
Please install and test the attached package and let me know how does it working. If needed, further adjustments are also possible, maybe I missed something (many times I do).
Additional notes: The original package is a little bit weird, because:
- The name of the root config (the folder under the Skins folder, which contains the skin) begun with a space. I removed this space.
- I also removed the not-first space from the name of the config. Initially it was Aesthetic Weather, I renamed it to AestheticWeather. Even if it's not forbidden, nor a good idea is to have spaces in name of configs (nor in name of skins, variables, sections of skin and so on).
- The author and name of skin is different in the [Metadata] section and in the installer package. In fact the name of skin is definitely mistaken in the [Metadata] section of the skin. There says the name of the skin is Simple Clock. Weird if the author when created the package forgot to replace the copied information, because this is what has happened in my opinion.
You're welcome from my part. Please continue testing and let me know if you encounter any problem.Pyuahowaito wrote: ↑August 7th, 2022, 4:50 pm I tested a lot of rainy places based on the weather information provided by the website, and most of it can automatically start rain skin work accurately and stably (although I haven't seen the moment when the Rain skin automatically stops yet).Once again, I would like to thank Balala for her meticulous answers and help, and for letting me know exactly how skin-to-skin interactions and some of the things that need attention, and thank you for Tass_co letting me know another way.