Multi Layer Fog

I'm thinking about ditching the blog and just putting all the links straight to pastebin. It just means I'll need to make sure all the instructions for my scripts are complete here.
well all depends of what type is your scripts if this is a small script you can only paste on the forum and if you want later to make the script on your blog but

if this is a massive script who requires a manuel it still preferable to upload it on a blog because  massive manual can be lost in this kind of  post

but this still preferable to only do a pdf who have the manual 

this all case of organisation really 
your system is compatible with Khas Lightning system?
No idea. Try it and see. I don't set out to make any of my scripts compatible with anything other than RTP, so if they work together, it's a happy accident 🙂
Here is an image of an event for showing fog which appears to have problems, but i can't work out why.  What happens is this:

I transfer to the map - no fog.

If I exit and reload from autosave, which clearly is going from the very beginning of the party's arrival as there is a flash when they get there, I have fog.

If instead I save and exit, when I reload I have fog.

If, while I have no fog, I enter a battle scene, I can see the fog drifting across, as I have set it to show fogs and weathers during battles.  When I exit the battle scene and am back on the map, I have fog.

If, without going into a battle scene, I exit that map, when I return I have fog.

It is just on the initial transfer to the map that the fog is missing, and I cannot for the life of me work out why.

Here is the event

Spoiler
fogevent_zps291c74e2.png
Thanks
This is the only event on this map that has anything to do with fog?


Can I see the event on the other map that transfers you here?


Your commands should not affect each other, but what if you try changing the order - put the fog before the tint, or after the weather effects. I'd be surprised if it makes a difference, but I'd like to rule it out.


Does it ONLY happen on this one map, or all maps where you have events like this set up?
This is the only event on that map with fog in it.

It only happens here, not on other maps.

I tried changing the order and it didn't have any effect.

Here is the transfer event.  I haven't done the full event page, as it is very long with dialogue, moves and then finally a long series of 'Show picture' commands, though you can see the last chunk of that.  The script call immediately before the transfer event is to establish who will be in the party.  Other than that, it is just a straightforward transfer.

Spoiler
TransferEvent_zps887ca72b.png
thanks.
A bit strange ... Can you try changing that event so that it JUST transfers the player to the new map and does nothing else? Just to see if there's a certain command in that event that might be stopping something from happening on the next map.
I took out the party change and the flash animation, and it made no difference.

I also tried transferring the party straight there without going through the cut scene at all, so that I could see if it made any difference, and it didn't.  Still no fog.
If you go to the map (no fog) and open the menu, is the fog there when you close the menu, without actually doing anything while in the menu?


No common events that muck around with fog?


Can I see tab 4 of that transfer event? That one apparently works okay.


You've got the transfer setting as 'white'. What if you change it to 'normal'?
Ah, if I go into Menu and do nothing, when I close it I do indeed have the fog.

I have no common events which refer to fog.

I've tried changing the transfer setting from white to normal, and it makes no difference.

And here is page 4, which is totally blank.

Spoiler
TransferEventp4_zps41cfe5b2.png
oh - I assumed it'd have a transfer on it.


What if you add a z-value to the fog? Try making it 200, then 300, then 500, and see if it makes any difference at all.


Are you using any scripts that affect the map or its spriteset?
Sadly adding a z value didn't have any effect.

I have a couple of scripts which affect some maps e.g. Tsukihime's tile swap, and Yanfly's slippery tiles, but none of them are in use on this map.  I have another area where fog is set up in a similar way, and I have no problems there, so it is not as if something in the background is causing the problem.

Just tried setting the map as the Player's Starting Position and New Game, and the fog appears as it should.  It therefore looks as if it is something to do with transferring in.
Is it possible to make it allow showing fogs in battle via switch? or perhaps trough maps notetags? In some areas the fogs in battle are ok but in others the fog might look weird due to the different perspective. Removing the fog with the script before battle looks bad and by fading out the screen before removing the fog you can't see the battle transition. Also, using fog_fade makes the fog fade when already in the battle screen.
I haven't tested this, but can you try editing the script, in the Spriteset_Battle class, in the update method, change the update_fogs line (in the original script this is line 457) to say this:

update_fogs if $game_switches[23]replacing 23 with whatever switch number you want to use (no leading zeros) - if that switch is turned on, the fog will be shown.
Let me know if it works or not.
Yes, it does work. Thank you!
Do you have an 640x480 for images to source (for fog/shadowing for forests  e.c.t. )? 🙂
I own an XP license, so I use the XP fog images.
Done just that as it was on sale, thought why not 😀

Also can't wait to start using your fog script!

Thanks for this 🙂

So with the ID can it just be 1 or does it need to be 001?

(also the fogs folder I have put in my game doesn't appear in the actual resource manager list, should it?)

and 1 last thing, the filename I am guessing its the full name without the .png? 🙂
Use "1" not "001" and I'd keep the .png in the file name in the script call.

---

If these Fogs had an Altitude, they could work like a Cloud Altitude script I wrote for XP.  I never ported Cloud Altitude to anything but XP so it would be a welcome addition to the script.  Also, I made a royalty free Fog that tiles perfectly and has an Alpha Transparency Layer so it looks correct as a "Cloud" or "Fog".  Permission is granted to use that fog as long as permission is given where ever it is used, including this script.

Just my two cents...
Well I am using the script call 

show_fog(1, Fog01.png)

on a blank event on a test map to just see the different graphics.

(I have the "Fogs" folder in my graphics folder on my game)

But I get the attached error:

fogissue.png

Original thread: https://forums.rpgmakerweb.com/threads/multi-layer-fog.18835/