9 hours ago
Hello! I finally got something to ask (lol). I asked somewhere else too, but I want to try to get as much help as possible x') So let me copy:
My JS knowledge is basic and my plugin making experience is also that, so please be patient.
I am trying to make transitions in game (when starting a new game, when loading, when going to title, when entering battle and leaving battle... basically scene transitions) work with images. In my specific case I have 3 images, one that covers the whole screen with dots, one with bigger dots, and a third one that is just black.
This works fine in a common event for, say, map transfers.
>Show image #1 transition1.png
>Wait X frames
>Erase image #1
>Show image #1 transition2.png...
I know the battle intro is a different thing, which is why I use a plugin to replace it with a common event (SRD_CEBattleIntro). However, by default, when the battle actually starts, there is a fadeout, and when it ends there is another fadein-fadeout to go to the map scene. I want to modify those very fadeins-fadeouts.
But well, by default it obviously doesn't use a multiple-image approach (there is no need for it to do so). I also don't truly understand how it 100% works. This is the function, so you have it at hand:
(And a similar one for FadeIn)
Anyway. Anytime this is used, duration is set as fadeSpeed(), which returns 24 by default. I made it 1 so the transitions were instant, and that works, again, up to a certain point. All my map transfers can use evented show image commands, but I can't do it with transitions between scenes. Could someone guide me a little?
I know how to load images with ImageManager.reservePicture(), as I've managed to draw busts to my menus with a custom function (that uses this.contents.blt()). But that was a static image in a menu. I have no idea how to show more than one, in sucession, after waiting frames, and make it an animation.
I can also figure how to set up plugin parameters that reserve the images that will be used, so other than that, can someone think of a way of showing images in sucession with frame waits in between?
Sorry if it's not that simple to implement, as again, I'm not great at code. But I figured I could ask before giving up and using a plan B. Thank you!
My JS knowledge is basic and my plugin making experience is also that, so please be patient.
I am trying to make transitions in game (when starting a new game, when loading, when going to title, when entering battle and leaving battle... basically scene transitions) work with images. In my specific case I have 3 images, one that covers the whole screen with dots, one with bigger dots, and a third one that is just black.
This works fine in a common event for, say, map transfers.
>Show image #1 transition1.png
>Wait X frames
>Erase image #1
>Show image #1 transition2.png...
I know the battle intro is a different thing, which is why I use a plugin to replace it with a common event (SRD_CEBattleIntro). However, by default, when the battle actually starts, there is a fadeout, and when it ends there is another fadein-fadeout to go to the map scene. I want to modify those very fadeins-fadeouts.
But well, by default it obviously doesn't use a multiple-image approach (there is no need for it to do so). I also don't truly understand how it 100% works. This is the function, so you have it at hand:
Code:
Scene_Base.prototype.startFadeOut = function(duration, white) {
this.createFadeSprite(white);
this._fadeSign = -1;
this._fadeDuration = duration || 30;
this._fadeSprite.opacity = 0;
};
(And a similar one for FadeIn)
Anyway. Anytime this is used, duration is set as fadeSpeed(), which returns 24 by default. I made it 1 so the transitions were instant, and that works, again, up to a certain point. All my map transfers can use evented show image commands, but I can't do it with transitions between scenes. Could someone guide me a little?
I know how to load images with ImageManager.reservePicture(), as I've managed to draw busts to my menus with a custom function (that uses this.contents.blt()). But that was a static image in a menu. I have no idea how to show more than one, in sucession, after waiting frames, and make it an animation.
I can also figure how to set up plugin parameters that reserve the images that will be used, so other than that, can someone think of a way of showing images in sucession with frame waits in between?
Sorry if it's not that simple to implement, as again, I'm not great at code. But I figured I could ask before giving up and using a plan B. Thank you!