Canvallax
Canvallax copied to clipboard
Canvallax clouds
Thank you for your work, I really liked it and have included it on the site.
http://vvl99.narod.ru/Clouds.html
If you reload the page, the code from Canvallax v.1 and Canvallax v.2 will be used randomly:
if (type) { ctx.translate(randomRange(halfw, width - (w * maxScale * 1.3)), randomRange(halfh + halfh / 4, height - (h * maxScale))) } else { ctx.translate( weightedRandom( width - (w * randScale), 5 ), weightedRandom( height- (h * randScale), 5) ) };
Which corresponds to:
location.hash = type ? "puffy_clouds" : "cumulus_clouds";
- time: "morning", "noon", "twilight", "evening", "night", "afternoon". I tried to vary the clouds as much as possible depending on the time of day.
Added options - _http://vvl99.narod.ru/Clouds.html#4?1?81 #[0-9] - Scene. ?[0-1] - Cloud type. ?[0-100] - Percentage of clouds. Made for testing, but may be useful for viewing. For example, a thunderstorm on scenes 4 and 8 with clouds over 80.