Combat lagging from many different things. (Starting, Skill vfx, ect.)

Discussion in 'RPG Maker MV' started by TheTitan99, Nov 2, 2015.

Thread Status:
Not open for further replies.
  1. TheTitan99

    TheTitan99 Veteran Veteran

    Messages:
    165
    Likes Received:
    65
    First Language:
    English
    Primarily Uses:
    RMMV
    One of my biggest problems with VX Ace was lag issues. I'm in my free trial of MV, and would like to be able to buy it, as it can do a lot of complicated things. However, if it fails on a basic level, then those complex things are rather irrelevant.

    First, lag upon start up of combat. It lags as the sprites load... I think? Because combat is starting at exactly the same time as the menus appearing, the music starting, the camera zooming and blurring, its possible something else is causing the lag. Either way, at the start of my testing battle, the frame rate goes from the smooth 60fps that's consistent when walking, down to 20fps, then quickly back up to 60fps when the battle properly begins. Though it sounds small, it's quite noticeable.

    The second lag issue is with using skills. The game seems to lag the first time a skill's VFX is played. As in, it loads the PNG file, lags, then plays it. Upon using the skill a 2nd time, there is no lag, as it has already been loaded once. This is for all of the default moves the team and that troop of bats or slimes have. Attacking, Healing, Sparking, ect. Everything lags the first time, but not the 2nd or beyond.

    I am running on Windows 7. It is a fairly outdated computer in some ways, but it can run DOTA 2 fine, which I KNOW is more graphically intense than this game. It has 4.00 gigs of RAM. Not sure how to check other things.

    The game is still in version 1.0.0. I am using Yanfly's Core Engine v1.04, Core Combat v1.09, and Core Message v1.03.

    Any help is appreciated. Sorry for the long post. I just wanted to make sure people knew exactly what the problem was, as to avoid having to waste tons of posts explaining things further. New member, post restriction, and all that.
     
    #1
  2. Shaz

    Shaz Veteran Veteran

    Messages:
    37,710
    Likes Received:
    11,419
    Location:
    Australia
    First Language:
    English
    Primarily Uses:
    RMMV
    Does the issue happen when you disable all the plugins?  ie - is it an issue with the engine, or an issue with the plugins?
     
    #2
  3. TheTitan99

    TheTitan99 Veteran Veteran

    Messages:
    165
    Likes Received:
    65
    First Language:
    English
    Primarily Uses:
    RMMV
    Both with plugins and without.

    When plugins are all set to Off, the lag entering combat is still the same, dipping downward of 10-15fps during the transition and start of combat.

    Inside of combat itself, when the plugins are off, there is still lag upon using skills for the first time. It DOES seem to be less lag. But, then again, Yanfly's combat engine just plays about 3 times as much VFX (casting vfx, enemy attack vfx), so the lag may be the same, just not happening as many times in succession.

    Edit:

    Also, the vfx lag, due to it seemingly being an issue of loading the png files, only happens in the first battle. Fight a 2nd battle, there is no lag on the moves that were used before. The starting combat lag, however, is there at the start of every battle. Seems like it's at a battles end too.
     
    Last edited by a moderator: Nov 2, 2015
    #3
  4. TheTitan99

    TheTitan99 Veteran Veteran

    Messages:
    165
    Likes Received:
    65
    First Language:
    English
    Primarily Uses:
    RMMV
    (I believe, since it has been 3 days, I can bump this topic. Apologies if I am mistaken on this.)

    So, further testing. Started a new project, added nothing to it, set a random encounter for the 2 bats, and still got the lag. Using Spark drops fps to about... 30-40, using the fire spell drops it to, like, 45. Still only the first time of use. Starting and ending battles drops fps down to about 10 every time.

    2 side notes that could possibly help... First, I'm also getting a lot of lag loading up the pause screen. I've seen this commented on by other people in other topics, though, so I thought it was a known issue. If there was a fix to that, it's possible it may fix this. 2nd, is there a general patch for RPG Maker MV that I haven't downloaded. I've searched google for a patch, but all I get are plugin patches, so it's possible I've missed something.
     
    #4
  5. TheTitan99

    TheTitan99 Veteran Veteran

    Messages:
    165
    Likes Received:
    65
    First Language:
    English
    Primarily Uses:
    RMMV
    Okay. So, I've patched RPG Maker MV to 1.01. All the lag problems are still here. However, in all this, a thought has occurred to me: Is the problem with the RPG Maker (ie, somehow the code is bad, causing lag), or is it a problem with my computer? There's no way for me to test this on my own. So, I have thrown together a quick little test game, that just plays a TON of animations, where you fight a skeleton.

    If possible, could someone on this forum download this test game, play it, and see if anything lags? I've put a lot of waits in the events, so by lagging, I mean pressing F2, and seeing if the fps drops. I've included lots of animations, pictures, and even a movie. The animations cause lag, but the movie and pictures do not. I cannot figure this out, and would like to know if it causes lag for other people, or just me.

    Typically, pausing and unpausing drops the fps to about 20-25. Starting combat drops it to about 10-20. Animations have a wide variety, sometimes not really even dropping the fps at all.

    Here is the link. It was deployed for Windows:

    https://drive.google.com/file/d/0BwS0iZFTZ5_8dmQ1NFkxR2YxcHc/view?usp=sharing

    I believe it should be setup to be downloadable.

    There should be a download button on the screen somewhere. For me, it's above the folder.
     
    #5
  6. Jory4001

    Jory4001 Veteran Veteran

    Messages:
    80
    Likes Received:
    17
    Location:
    Canada
    First Language:
    English
    It is not your computer.

    I have a custom built top of the line gaming and video/photography editing computer that has run every game on max settings with dual moniters and multiple editing software s open.

    And I still get massive lag on battle start. Not so much with casting spells. But my fps on battle start drops to under 10.
     
    #6
    Galenmereth likes this.
  7. bgillisp

    bgillisp Global Moderators Global Mod

    Messages:
    12,076
    Likes Received:
    12,252
    Location:
    USA
    First Language:
    English
    Primarily Uses:
    RMVXA
    I have the same problem with my computer and my MV project. FPS will drop to about 12 when combat starts, then quickly go back to 60. Skills cause a dip to about 30 FPS, then it goes back to 60.

    However, on mine the FPS drop is hard to notice unless you are specifically looking for it, as I almost always have 60 FPS by the time I am able to input any commands in a battle. Maybe my comp recovers faster from it?

    Edit: After I posted I went back and tested things in ACE, no FPS drop on battle start there at all, and that was in a project that didn't have an anti-lag script. Attacks and skills also stayed at 60 FPS, even the first time they were used. Wonder what the difference in the battle start code between ACE and MV is that is causing this issue?
     
    Last edited by a moderator: Nov 9, 2015
    #7
  8. MikeMakes

    MikeMakes Veteran Veteran

    Messages:
    159
    Likes Received:
    41
    First Language:
    English
    I've also noticed that transition into combat causes FPS drop in addition that using a particular skill for the first time will also cause FPS drop.
     
    #8
  9. Kenen

    Kenen Veteran Veteran

    Messages:
    255
    Likes Received:
    152
    First Language:
    English
    Primarily Uses:
    RMMV
    I can reproduce a lag spike while entering Scene_Battle from 60 FPS to 30 FPS for exactly 1 second or less, but that is the extent at which I can reproduce lag; and I wouldn't even consider this lag, as the transition is smooth. With regards to executing skills/animations, I cannot reproduce a FPS drop. This is with using Fraps as a FPS meter.
     
    #9
  10. Syltti

    Syltti Devout Follower of Yuri Veteran

    Messages:
    178
    Likes Received:
    55
    Location:
    Storyland
    First Language:
    English
    Primarily Uses:
    RMMV
    I can vouch for the lag when using skills for the first time. I've been trying to find a fix for this for a while now.
     
    #10
  11. MikeMakes

    MikeMakes Veteran Veteran

    Messages:
    159
    Likes Received:
    41
    First Language:
    English
    I wonder is it because it's loading the resource for the first time. There should be a way to have it all preload at the start of game/ first battle, but done in a way that it wouldn't drop the FPS drastically.
     
    Last edited by a moderator: Nov 10, 2015
    #11
  12. Alexa Angel

    Alexa Angel Veteran Veteran

    Messages:
    51
    Likes Received:
    16
    Location:
    You wish ;P
    First Language:
    English
    Have you tried looking for a plugin that caches your animation images??

    If not, I can write a plugin to do that.

    The problem is like others it disposes of the animation images post battle to ease on memory.

    Otherwise it would build up memory usage.

    I think the reason you notice it in MV and not so much in ace is because the animation images and battlebacks are higher resolution therefore take longer to load.

    I believe the best solution then for this is a plugin that will load all animation when combat is just beginning.

    Most larger games get away with running fine because they load all this and mask it in a loading screen before.

    As a developer you guys have to choose where to load these images, the engine cannot load them all in an instant.
     
    #12
  13. TheTitan99

    TheTitan99 Veteran Veteran

    Messages:
    165
    Likes Received:
    65
    First Language:
    English
    Primarily Uses:
    RMMV
    I have added in this plugin, the Preload Manager:

    http://forums.rpgmakerweb.com/index.php?/topic/46515-preload-manager/

    I added into the editable arrays near the top of its code for it to preload some music, the battlebacks, animations, basically, everything that could potentially cause lag. It did not work. I am unsure if this is a problem with the plugin itself or not, as it certainly DID increase loading times, but didn't seem to reduce lag in any way.

    So, yes, a new plugin could potentially be helpful. However, I am unsure if preloading is actually a solution or not, as this preloader has not worked.
     
    #13
  14. MikeMakes

    MikeMakes Veteran Veteran

    Messages:
    159
    Likes Received:
    41
    First Language:
    English
    That plugin might be for map assets only.
     
    #14
  15. Alexa Angel

    Alexa Angel Veteran Veteran

    Messages:
    51
    Likes Received:
    16
    Location:
    You wish ;P
    First Language:
    English
    Yeah as I said above it a plugin that caches your images will not work in battle animations and the like.

    Because the problem is MV disposes of the images post battle, therefore you will load them all up and they will be removed outside of battle.

    What you need is a plugin that both caches your data but also prevents MV from disposing of them outside of battle.

    The problem with this is if you accumulate a lot of skill animations and such it will be VERY heavy on memory.
     
    #15
  16. MikeMakes

    MikeMakes Veteran Veteran

    Messages:
    159
    Likes Received:
    41
    First Language:
    English
    What does it mean by disposing images post battle?

    Because if I use the skill for the first time in a battle, there will be lag. However, there won't be any lags again in subsequent battles if I use the same skill - even with a Gameover to the title screen in between.
     
    #16
  17. jrsuri

    jrsuri Villager Member

    Messages:
    8
    Likes Received:
    0
    First Language:
    Português
    Primarily Uses:
    RMMV
    Did anyone find a fix for this?
     
    #17
  18. Andar

    Andar Veteran Veteran

    Messages:
    28,419
    Likes Received:
    6,485
    Location:
    Germany
    First Language:
    German
    Primarily Uses:
    RMMV
    @jrsuri the memory leaks were fixed several versions back, which is why this is an extremely old topic.

    jrsuri, please refrain from necro-posting in a thread. Necro-posting is posting in a thread that has not had posting activity in over 30 days. You can review our forum rules here. Thank you.



    If you experience lag, please Start a new topic with a detailed description as the cause is something else.

    Closing
     
    #18
    TheTitan99 and Windows i7 like this.
Thread Status:
Not open for further replies.

Share This Page