[TOOL]Unsettled Weather[perl script]

Note that alterations to the YSFlight .EXE is forbidden
K2W
Rookie
Rookie
Posts: 55
Joined: Sat Aug 22, 2015 1:56 am
Favorite Aircraft: cessna c172
OS: Windows 10
Has thanked: 5 times
Been thanked: 214 times

[TOOL]Unsettled Weather[perl script]

Post by K2W »

Hello, every one.
Don't you get bored to changeless weather of YSFLIGHT?

I made a perl script which adds weather change events to YSFLIGHT.
You can enjoy flights with capricious weather in YS.

sumple video
The tool can be downloaded from tool & plugin of C.K.Packs.
http://mrsandj.sakura.ne.jp/ht/ckp/tool/tool.html
*click the link of "天候変化ツール"

---------------------------
YSFLIGHT用天候変化ツール(Weather Change tool for YSFLIGHT)"unsettledweather.pl"

概要:about
YSFLIGHTの「前回のフライトに再挑戦」用ファイルに天候変化(風、指定)イベントを指定回数追加するperlスクリプトです。

This is a perl script which add weather change events to "prevflight.dat" which is used for "Retry Previous Flight."


使い方:How to Use
1、YSFLIGHTでフライトを作成し、フライトを開始する。
"Create New Flight" & "Fly Now!" in YSFLIGHT.

2、フライトを終了する。
Terminate the flight.

3、"unsettledweather.pl"を"prevflight.dat"と同じフォルダ(Documents\YSFLIGHT.com\YSFLIGHT)に置き、実行する。
Set "unsettledweather.pl" to same directory with "prevflight.dat",(Documents\YSFLIGHT.com\YSFLIGHT),
and Done.

4、指示に従い、パラメーターを入力する。
Input parametars as instructions.

5、終了後、「前回のフライトに再挑戦」を選択し、実行する。
After complete, in YS, choose "Retry Previous Flight".



注意:Caution
改造、再頒布の一切は自由ですが、使用については全て自己責任でお願いします。
This script is free to any use, modification and redistribution.
however, I'm not responsible for any results.
Last edited by K2W on Wed Sep 05, 2018 8:25 am, edited 1 time in total.
User avatar
Turbofan
Senior Veteran
Senior Veteran
Posts: 2072
Joined: Thu Feb 03, 2011 4:22 pm
Favorite Aircraft: Boeing 747, all variants
Location: Southern Plains
Has thanked: 1172 times
Been thanked: 843 times
Contact:

Re: [TOOL]Unsettled Weather[perl script]

Post by Turbofan »

I'll definitely give this a try, appreciate it K2W!
User avatar
u2fly
Senior Veteran
Senior Veteran
Posts: 1488
Joined: Fri Oct 02, 2015 9:27 am
Favorite Aircraft: Antonov An-225 Mriya
Location: Ukraine
OS: Linux
Has thanked: 1053 times
Been thanked: 343 times

Re: [TOOL]Unsettled Weather[perl script]

Post by u2fly »

Nice!
Will try rewrite/port it to Python.

U.S. Senator John McCain wrote:“Spending #NewYearsEve w/ brave #Ukrainian Marines at a forward combat outpost
- we stand w/ them in their fight against #Putin's aggression”

pic.twitter.com/vkz0gdozVV [archived]
(31 DEC 2016)
Richard Vo
Veteran
Veteran
Posts: 528
Joined: Mon Dec 14, 2015 8:19 pm
Favorite Aircraft: A380, JAS-39
Location: Sweden
OS: Windows 10
Has thanked: 320 times
Been thanked: 115 times
Contact:

Re: [TOOL]Unsettled Weather[perl script]

Post by Richard Vo »

So with this tool, I can set any type of weather I want right?
The A380 is ahead of its time. With the resilient passenger traffic growth for times to come (reference from Airbus's Global Market Forecast), plus congested airports, the A380 could not be ignored.

By any chance if you have Instagram, please drop a follow on @vhaq_aero and if you have Twitter, please drop a follow on @vhaq_aero. Appreciate that!
K2W
Rookie
Rookie
Posts: 55
Joined: Sat Aug 22, 2015 1:56 am
Favorite Aircraft: cessna c172
OS: Windows 10
Has thanked: 5 times
Been thanked: 214 times

Re: [TOOL]Unsettled Weather[perl script]

Post by K2W »

I made a new tool to cleate interesting skies, "Cloudmaker.pl"
It generate a lot of clouds in your prevflight.dat.
the usage is same as unsettledweather.
YS FLIGHT SIMULATOR Main Window (OpenGL 2.0 _ ES 2.0) 2018_03_02 21_18_42.png
YS FLIGHT SIMULATOR Main Window (Direct3D9) 2018_03_02 21_32_08.png
YS FLIGHT SIMULATOR Main Window (OpenGL 2.0 _ ES 2.0) 2018_03_03 1_02_18.png
you can get from https://drive.google.com/file/d/1Mug3jB ... p=sharing
TournelHenry
Newbie
Newbie
Posts: 26
Joined: Thu Jun 11, 2015 4:08 pm
Favorite Aircraft: bombardier CS300
OS: windows 10 Home
Has thanked: 48 times
Been thanked: 9 times
Contact:

Re: [TOOL]Unsettled Weather[perl script]

Post by TournelHenry »

I don't know how to use these things. Does it require coding?
DarkestHour
Newbie
Newbie
Posts: 29
Joined: Mon May 21, 2018 12:29 pm
Favorite Aircraft: Anything that flies
Location: England
OS: Win10
Has thanked: 17 times
Been thanked: 9 times

Re: [TOOL]Unsettled Weather[perl script]

Post by DarkestHour »

Did anyone manage to get cloudmaker.pl to work? I set the parameters for the first 5 lines to test it.

Distance of clouds from origin east:1000
Distance of clouds from origin north:1000
Range of Clouds:1000
Number of clouds:100
Minimum altitude of bottom of clouds:500

It wouldn't work. I did remove the parameter for detecting if there are already default clouds as I wanted to use it on a saved flight already with clouds, but it seems not to work with or without this.
''Ebony & ivory, live together in perfect harmony, side
by side on my piano keyboard, oh lord, why don't we''
User avatar
waspe414
Staff
Staff
Posts: 1592
Joined: Thu Feb 10, 2011 9:35 pm
Favorite Aircraft: Kiowa, Mitten, Hornet
Location: Canada
Has thanked: 158 times
Been thanked: 510 times

Re: [TOOL]Unsettled Weather[perl script]

Post by waspe414 »

Are you running it where it has access to the prevflight.dat file? prevflight.dat is actually a .yfs file pretending to be a .dat file, and lives in C:\Users\[username]\Documents\YSFLIGHT.COM\YSFLIGHT
You can open prevflight.dat and delete SLDCLOUD and everything after to remove the stock clouds
Actual UltraViolet
Image Image
Image
I stole your turnip. Now you must come and defend your honour. ~ Hank Green
DarkestHour
Newbie
Newbie
Posts: 29
Joined: Mon May 21, 2018 12:29 pm
Favorite Aircraft: Anything that flies
Location: England
OS: Win10
Has thanked: 17 times
Been thanked: 9 times

Re: [TOOL]Unsettled Weather[perl script]

Post by DarkestHour »

Yes, I confirm it is in the Documents\YSFLIGHT.COM\YSFLIGHT folder. I uploaded a text file with my edited cloudmaker.pl copied to it if you want to take a look. Also, I cannot find SLDCLOUD in my prevflight.dat although if I save the previous flight, SLDCLOUD is in the saved file.
Is number of clouds set to 100 much too high for YSF or can it handle that amount?

On another topic, YSF always seems to slow down the pc everytime I leave the program on while focusing on something else. There isn't a way to reduce or prevent this, is there? I have a Fnatic gaming rig so it must be a YSF limitation.
Attachments
cloudmaker.txt
(5.49 KiB) Downloaded 45 times
''Ebony & ivory, live together in perfect harmony, side
by side on my piano keyboard, oh lord, why don't we''
User avatar
waspe414
Staff
Staff
Posts: 1592
Joined: Thu Feb 10, 2011 9:35 pm
Favorite Aircraft: Kiowa, Mitten, Hornet
Location: Canada
Has thanked: 158 times
Been thanked: 510 times

Re: [TOOL]Unsettled Weather[perl script]

Post by waspe414 »

YS is quite unoptimized, but try a different .exe. D3d has the least consistent rendering but runs the best. OGL1 has the most consistent rendering but runs poorly. OGL2 is in the middle. If you upload your prevflight.dat with the clouds added, I can see what my YS does with it
Actual UltraViolet
Image Image
Image
I stole your turnip. Now you must come and defend your honour. ~ Hank Green
DarkestHour
Newbie
Newbie
Posts: 29
Joined: Mon May 21, 2018 12:29 pm
Favorite Aircraft: Anything that flies
Location: England
OS: Win10
Has thanked: 17 times
Been thanked: 9 times

Re: [TOOL]Unsettled Weather[perl script]

Post by DarkestHour »

waspe414 wrote: Sun Jul 07, 2024 4:10 pm If you upload your prevflight.dat with the clouds added, I can see what my YS does with it
Dumb question but do you mean I should upload after having tried running the previous flight with cloudmaker.pl in the same directory or actually copy pasting SLDCLOUD from the saved flight file?
''Ebony & ivory, live together in perfect harmony, side
by side on my piano keyboard, oh lord, why don't we''
DarkestHour
Newbie
Newbie
Posts: 29
Joined: Mon May 21, 2018 12:29 pm
Favorite Aircraft: Anything that flies
Location: England
OS: Win10
Has thanked: 17 times
Been thanked: 9 times

Re: [TOOL]Unsettled Weather[perl script]

Post by DarkestHour »

I've now tried all three .exe's by removing cloudmaker before creating a flight (with no default clouds), closing the flight, then adding cloudmaker back in as per K2W's instructions before retrying previous flight, but to no avail.
''Ebony & ivory, live together in perfect harmony, side
by side on my piano keyboard, oh lord, why don't we''
User avatar
waspe414
Staff
Staff
Posts: 1592
Joined: Thu Feb 10, 2011 9:35 pm
Favorite Aircraft: Kiowa, Mitten, Hornet
Location: Canada
Has thanked: 158 times
Been thanked: 510 times

Re: [TOOL]Unsettled Weather[perl script]

Post by waspe414 »

Delete the clouds from prevflight.dat, run cloudmaker, then check prevflight.dat. If there is SLDCLOUD in it, upload it and I'll have a look at the performance on my machine
Actual UltraViolet
Image Image
Image
I stole your turnip. Now you must come and defend your honour. ~ Hank Green
DarkestHour
Newbie
Newbie
Posts: 29
Joined: Mon May 21, 2018 12:29 pm
Favorite Aircraft: Anything that flies
Location: England
OS: Win10
Has thanked: 17 times
Been thanked: 9 times

Re: [TOOL]Unsettled Weather[perl script]

Post by DarkestHour »

There is no SLDCLOUD in it still but I'll upload anyhow. I can't seem to upload the .dat so I exported the contents to .txt
Thanks.
Attachments
prevflight.txt
(18.94 KiB) Downloaded 46 times
''Ebony & ivory, live together in perfect harmony, side
by side on my piano keyboard, oh lord, why don't we''
User avatar
waspe414
Staff
Staff
Posts: 1592
Joined: Thu Feb 10, 2011 9:35 pm
Favorite Aircraft: Kiowa, Mitten, Hornet
Location: Canada
Has thanked: 158 times
Been thanked: 510 times

Re: [TOOL]Unsettled Weather[perl script]

Post by waspe414 »

Have you been able to generate any clouds at all with cloudmaker or no? I got a bit confused by the 100 cloud comment. It's been years since I used any Perl scripts, so I'm the right person to troubleshoot the code itself
Actual UltraViolet
Image Image
Image
I stole your turnip. Now you must come and defend your honour. ~ Hank Green
DarkestHour
Newbie
Newbie
Posts: 29
Joined: Mon May 21, 2018 12:29 pm
Favorite Aircraft: Anything that flies
Location: England
OS: Win10
Has thanked: 17 times
Been thanked: 9 times

Re: [TOOL]Unsettled Weather[perl script]

Post by DarkestHour »

Thanks for the assistance.
No I haven't been able to generate any from cloudmaker at all yet.
I juggled around a bit with cloudmaker to see if I could,.so the one I uploaded may not be the vers.
with amount of clouds set to 100.

Since the default clouds are no more than 11/12 generated, I wondered if 100+ (cloudmaker generated) would be too much for YS. I think I tried just 15 generated at the lowest but still nothing. I tried copying various portions of cloudmaker to both prevflight and saved record, (No coder/graphics credentials here) to see what happened, not much besides YS closing. :o

I used vannila Heathrow since its pretty small and I wasn't sure where/above the map they would appear. (Why didn't I use Small Map or other). :? I've no idea. Will do next time I try.

Specifically, I wasn't really sure where origin from North/East meant exactly on the map.
I'm baffled why prevflight doesn't have SLDCloud written to it after I've exited a flight with solid cloud in it, as you say it should. If I save a record of the aforementioned flight it shows up in there.
This is on 20150425 vers.

Sorry, bit if a mouthful.
''Ebony & ivory, live together in perfect harmony, side
by side on my piano keyboard, oh lord, why don't we''
K2W
Rookie
Rookie
Posts: 55
Joined: Sat Aug 22, 2015 1:56 am
Favorite Aircraft: cessna c172
OS: Windows 10
Has thanked: 5 times
Been thanked: 214 times

Re: [TOOL]Unsettled Weather[perl script]

Post by K2W »

I'm sorry to be late to reply.

I don't understand all of your trouble.
But, I realized one thing about it.
your "range of cloud"parametor is too large.
1000 means 1000km x 1000km.
so, if you success to create clouds,you couldn't meet clouds.
you should set that parameter to 50 or less for your 100 clouds.

I will tell you, if I recognize other matters.
DarkestHour
Newbie
Newbie
Posts: 29
Joined: Mon May 21, 2018 12:29 pm
Favorite Aircraft: Anything that flies
Location: England
OS: Win10
Has thanked: 17 times
Been thanked: 9 times

Re: [TOOL]Unsettled Weather[perl script]

Post by DarkestHour »

Ok, I will test next time I get a chance.
Thanks.
''Ebony & ivory, live together in perfect harmony, side
by side on my piano keyboard, oh lord, why don't we''
DarkestHour
Newbie
Newbie
Posts: 29
Joined: Mon May 21, 2018 12:29 pm
Favorite Aircraft: Anything that flies
Location: England
OS: Win10
Has thanked: 17 times
Been thanked: 9 times

Re: [TOOL]Unsettled Weather[perl script]

Post by DarkestHour »

I've tested but unfortunately it still doesn't work.
I'm very curious to see if it works for anyone else besides OP.
I also downloaded a clean version (20150425) of YSF but it doesn't work on that either.
''Ebony & ivory, live together in perfect harmony, side
by side on my piano keyboard, oh lord, why don't we''
K2W
Rookie
Rookie
Posts: 55
Joined: Sat Aug 22, 2015 1:56 am
Favorite Aircraft: cessna c172
OS: Windows 10
Has thanked: 5 times
Been thanked: 214 times

Re: [TOOL]Unsettled Weather[perl script]

Post by K2W »

Please allow me to ask a basic question.

1. Can Any other Perl script work on your PC?

2.Please delete last line of Cloudmaker.pl, "rename "cloudmaker.wet","prevflight.dat";". Then, run the Cloudmaker.
After that, Can you find a new file named "coludmaker.wet" in the folder?

At least, My cloudmaker is working on Heathlow map with 1000 cloud.
スクリーンショット (1).png
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests