In a fog... Move Picture going right off map. Can it loop?

So my kiddos wanted to know how to make it look like their map was burning.


Wowa, we have flame maps on our cool site!


And here I am the cool RPG making teacher, trying to Demo how to make the flamemap fog move.


(Kids use Ace Lite in class. Some have full version at home but all classwork is in Lite)


Well, bleh, I can't do it.


I keep getting the fog running off the edge of the map screen. Looks like total fail.


I searched like a good girl.


http://forums.rpgmakerweb.com/index.php?/topic/31309-fog-and-the-like-how-to/?hl=%2Bmove+%2Bpicture#entry304255


http://forums.rpgmakerweb.com/index.php?/topic/36416-evented-weather-system-vxace/?hl=%2Bmove+%2Bpicture#entry361975


http://forums.rpgmakerweb.com/index.php?/topic/4933-simple-fog-event-tutorial-for-rpg-maker-vxace/?hl=+move%20+picture


But I thought you could choose fog graphics that were twice the size of the screen and have a seamless experience when you moved the picture.


I don't know why it would work exactly, but I thought it was supposed to.


Anyways, here are my event pages and the dimensions of my map and fog:


event page one.png


event page two.png


map nd fog properties.png


Is it possible to have them loop around? Did I like not do the math right or something?
I always searched for a way to create my own weather-like effects. Nice!
I'm not really sure I understand what you're trying to do there ... move it horizontally AND vertically at different speeds?


The idea behind the twice-as-large image is that you place it so that the image aligns with the bottom of the window (so you've got a window-sized portion above that you can't actually see), and then slowly move it down so the unseen top portion moves into view. When it's fully in view, the image and the window are aligned at the top. That then loops, so after the image has scrolled down a full screen's worth of movement, it jumps to the top again and repeats.


It's not really necessarily JUST a double-height image either, but more a screen-sized fog that is duplicated (so you've got the same image at the top as at the bottom). If it were just a single image twice the height of the screen, it might not be seamless when it comes to looping.


That's a bit confusing - I hope you can understand what I'm saying.
Well, I was just trying for a diagonal movement with a bit of random variation.


So I what I was aiming for was having the y value move at a set rate that I chose (but could play with later to tweak) 100 or 75 pixel changes


And the x value would just allow a little drift generally to the right but wandering to the left a bit.


As far as that goes, it looks fine. I was going to add some slight changes in opacity or movement to make it look as much like rolling smoke as I could.


But the sudden screen with no fog is the killer. The fog image leaves the screen and never comes back.


Hope that makes sense. =]


So as far as what you were saying, Shaz, do I need the image to be proportional to the screen then, or just plenty enough bigger?


Video of fog :


http://screencast-o-matic.com/watch/cohDQhfjAl
The main problem is that you're not looping it. You're never positioning the fog back at the start, so it's always moving further and further down.

What you'd normally do is something like this, in a parallel process event:

Show Picture: Fog1 @ 0,-fog_height Move Picture: Fog1 to 0, 0 in X framesIt's not so much the screen height that matters - it's the size and composition of the fog image itself. In order to make it appear seamless and be able to snap back to loop, you actually need to compose an image using two identical fog pictures, either one above the other, or beside each other, depending on the direction you're going to make it move (if you're moving it both horizontally AND vertically, you will need 4 fog pictures in a 2x2 format).So what's happening, if you're just scrolling it vertically, is that you first show the image with the top half out of sight above the map, and the bottom half visible. Then you move it down so that the bottom half is out of sight below the map, and the top half is visible. At this point the loop has ended, and starts again from the top, repositioning the image so the top half is above the screen and the bottom half is visible, and so on it goes.

Note, I recommend you use 0,0 as the origin rather than the center, because it's easier to do the calculations based on fog size & 0,0 rather than figuring out what's the middle of the image, what's the middle of the screen, what's a full image height above that ...

If you're also moving the fog horizontally, you will similarly adjust the x position (so the picture will be shown at -fog_width,-fog_height) then will move at 45 degrees, then snap back to the starting position and do it all over again.

The other issue you're going to have is that you're not moving at the same pace all the time, and the method above relies on you moving exactly a fog's width's/height's distance before jumping back to the original position again. You could do the calculations so the whole distance moved between all your movement commands is the full (individual) fog size, or you could take a different approach where you adjust the x and y by very small amounts and check each time to see if it's at the point to move back and do it (this would require changing the logic of the Show Picture command a bit).

There's also added complexity if you're zooming in on the fog.

I will see if I can do up some demos for you tomorrow that might help 🙂

If that's too confusing, it's because it's past my bedtime 🙂
Okay, Shaz, I think I get it now. There was never any looping occurring in this demo. It's all manual.


http://forums.rpgmakerweb.com/index.php?/topic/4933-simple-fog-event-tutorial-for-rpg-maker-vxace/?hl=+move%20+picture


He's just moving the picture back and forth.


I don't know if the link to Celianna's weather system was completly evented or not.


In any ~event~ let me play around with it a bit now that I understand this a bit more but please don't close, and don't feel like you need to make a demo. I'll post again in a while. Thanks.

Original thread: https://forums.rpgmakerweb.com/threads/in-a-fog-move-picture-going-right-off-map-can-it-loop.40050/