Best ways to reduce lag?

What are some of the best ways to reduce lag?

I find most of my lag occurs during combat and have read that it’s because RMMV loads images as they crop up, meaning they aren’t preloaded.

Is a preloader plugin the best way to overcome this? Does anyone have a preferred preloader plugin they use or another method they do to reduce lag?

Thanks in advance
what are you doing that is causing lag? I have never had any lag issues with RPG Maker MV before.
What are some of the best ways to reduce lag?

I find most of my lag occurs during combat and have read that it’s because RMMV loads images as they crop up, meaning they aren’t preloaded.

Is a preloader plugin the best way to overcome this? Does anyone have a preferred preloader plugin they use or another method they do to reduce lag?

Thanks in advance

Are you not using a spritesheet? Anything that has to do with motion should generally be a spritesheet. Yanfly has a picture spritesheet plugin that lets you put down animated pictures using spritesheets. Grid-free-doodads by Yanfly lets you put down animated stuff on your maps and is known to be very well optimized.

Are you using some sort of ABS? Otherwise I don't really see why things would lag during turn-based combat.


what are you doing that is causing lag? I have never had any lag issues with RPG Maker MV before.

It depends on the game. RTP/little to no custom assets will never really lag. But once you start bringing in HD maps (images can be like 10,000 pixels wide), action combat sprites, live shadows, lighting plugins, dust particles and fog, fog of war, HUDs, etc. things can get pretty dicey real quick on older devices.
Set your PC's Power Mode to Better Performance, check for thermal throttling, try running Disk Cleanup, etc . . . You could also try copying, and pasting the code below into Notepad, save it as .bat, and run as administrator.

@echo off

FOR /F "tokens=1,2*" %%V IN ('bcdedit') DO SET adminTest=%%V
IF (%adminTest%)==(Access) goto noAdmin
for /F "tokens=*" %%G in ('wevtutil.exe el') DO (call :do_clear "%%G")
echo.
echo All Event Logs have been cleared!
goto theEnd

:do_clear
echo clearing %1
wevtutil.exe cl %1
goto :eof

:noAdmin
echo Current user permissions to execute this .BAT file are inadequate.
echo This .BAT file must be run with administrative privileges.
echo Exit now, right click on this .BAT file, and select "Run as administrator".
pause >nul

:theEnd
Exit
Set your PC's Power Mode to Better Performance, check for thermal throttling, try running Disk Cleanup, etc . . . You could also try copying, and pasting the code below into Notepad, save it as .bat, and run as administrator.

@echo off

FOR /F "tokens=1,2*" %%V IN ('bcdedit') DO SET adminTest=%%V
IF (%adminTest%)==(Access) goto noAdmin
for /F "tokens=*" %%G in ('wevtutil.exe el') DO (call :do_clear "%%G")
echo.
echo All Event Logs have been cleared!
goto theEnd

:do_clear
echo clearing %1
wevtutil.exe cl %1
goto :eof

:noAdmin
echo Current user permissions to execute this .BAT file are inadequate.
echo This .BAT file must be run with administrative privileges.
echo Exit now, right click on this .BAT file, and select "Run as administrator".
pause >nul

:theEnd
Exit

I guess a pretty important thing for OP to clarify is whether he's looking to optimize the development process so he stops lagging himself, or whether he's trying to actually make his game run better so his future players aren't lagging.

I'm personally guessing it's the latter though.
There is a free plugin that I found really helps with that combat lag. I'll post a link to it in case you would like to check it out. For me it completely removed the lag so I do recommend it.
Thanks everyone for the responses.

I use Yanfly’s active time battle system with a custom hud and custom monster sprites. I use front view battle system and several custom combat plugins. I’m assuming it’s because of that. I don’t have massive maps (typically just do one screen maps, so no scrolling) and I don’t use parallax. I do use terrax lighting but not intensely. I’m looking for ways to help any lag for future players.

It’s not like the lag is terrible. It usually runs 50-60 fps and then can drop to 25-34 FPS. It clips at the start of a battle with new enemies encountered. That’s why I thought it was a preloader issue for images. I do have that upgrade performance plugin and it does help.
@Oir I never thought of that . . . meanwhile I'm trying to get CRT-Royale to work with MZ, so I can add it into my project . . . maybe it's not such a good idea; just because I can run it, doesn't mean everyone can.
Messed around with it a little more and it was a preloader issue. Which is now resolved!!

Original thread: https://forums.rpgmakerweb.com/threads/best-ways-to-reduce-lag.132816/