Hello all,
I am hoping maybe someone might be able to help out with this issue, or shed some light as to why it is occurring, because at this point I am about to tear out some of my hair in frustration :)
For awhile now I have observed a certain amount of screen "jitter" whenever moving around in my game, Aleph. This is not the typical lag you get from too many events, scripts, etc. It is like a little visual hiccup whenever you are moving around the screen. I created a few videos to try and demonstrate this issue:
Screen Jitter (low to none) - sorry for the low quality of this video, youtube for some reason compressed the heck out of it. But this shows what the game should be like, and how most RM games run - little to no jitter, 60 fps. There are only a few scripts in this version: YEA Ace Core Engine, plane fix for the high-res dll, and some character animation scripts from Dekita.
Screen Jitter (medium amount) - this one shows a middling amount of jitter, in spite of being 59-60 fps. The previous set of scripts are utilized here, with the addition of one extra script. The script itself added does not seem to matter at all, just the fact that it exists seems to cause jitter.
Screen Jitter (heavier) - this one shows higher jitter - forgive the lower fps, I forgot to disable a particular script before recording which dropped the fps, BUT it doesn't matter because even without the script the screen jitter is still there. Full set of scripts for the game in this version.
The videos don't seem to capture the full effect of the jitter due to the video compression, but hopefully they give an idea.
So I wanted to figure out what was causing this and I spent a great deal of time doing various tests on all of my scripts only to find no specific connection between the screen jitter and any scripts. Here are the steps I took for the most part:
Run the game with full script list, full databases, full graphical/audio resources (basically, as the game is intended) - get pretty heavy screen jitter.
Created new project. No jitter.
Added the Map datafiles, graphics, and audio. No jitter.
Added database datafiles (no script datafile). No jitter.
Wanted to test out higher-resolution dll to see if that is making an effect. Add high-res dll, plane fix script, and YEA Ace Core script, run game at 800x640 resolution. No jitter.
Begin to add scripts. First scripts I add are from Dekita, which increase frames of animation for movement as well as adds 8-dir movement. No jitter.
Added next script, Fog script. Screen jitter appears now.
Removed Fog script, jitter disappeared.
Added another script. Jitter re-appeared.
Removed script. Jitter disappered.
Added yet a different script. Jitter re-appeared.
Removed script, jitter now remains.
I went through and tried these steps in various combinations and it generally boils down to adding more than like 5 or 6 scripts causes screen jitter.
I spoke at length with Dekita regarding this, and have discussed this issue in the past with other scripters, and nobody has any idea what might be causing this issue.
Some observations regarding this jitter:
The scripts in question that I use for the test videos are not the cause of the jitter. The jitter existed before I even had any of these scripts. These scripts were also tested in isolation and in conjunction with other scripts prior to being placed in my project and they were perfectly fine.
The resolution does not seem to make a difference. The jitter exists at the default RPGMaker resolution, at 640x480, 800x640, etc. The severity remains constant.
The fps does not seem to impact the jitter. The screen can still be jittery at 60 fps, just as well at 40, 30, 20, etc.
The jitter only exists when the player character is moving. The direction of travel does not seem to matter, the jitter exists regardless of direction. If standing still, there are no issues. Events moving around do not jitter, animated elements on screen do not jitter. This seems to be movement-related.
Map size seems to have some small effect on the jitter. Larger maps might have a bit more jitter, smaller maps less. This might be related to fps/lag though, hard to tell, but it exists irregardless. The size of the test map in the video is 200x200, very few events.
The total database entries seems to effect the jitter somehow. I noticed heavier jitter when all of the database entries were maxxed out at 999, vs smaller jitter with all database entries at 1. However, it does not seem that the database sizes are the *source* of the jitter, they just somehow impact it in some strange way.
I tested this out on my desktop PC which is very souped up, jitter remains. Tested on laptop, jitter remains. Other people tried out the game and reported the jitter, so it does not appear to be localized to my PC or my hardware specifically.
I tried checking the 'reduce screen flickering' option, it seemed to make the jitter worse (or at the very least, it wasn't any better).
Generally, once I succeed in re-creating the jitter in a project through the addition of some scripts or whatever, removing the scripts does NOT remove the jitter. The jitter then remains indefinitely unless I replace the script datafile entirely with a clean one. Re-adding scripts to it though seems to eventually make it start causing the screen jitter.
I actually had this exact issue when I first began making Aleph on RPG Maker VX. After the game got to a certain point in development, the screen jitter emerged. It is one of the reasons why I moved the project to VX Ace when it came out. Only now, it seems the jitter has re-emerged for me on VX Ace as well.
I tried googling for a possible answer or solution, but have not been able to find a single case like this.
The jitter remains with both the old dll and the new high-resolution dll.
I tried the MGC Tilemap script and dll. The fps generally improved, but does not seem to have much effect on the jitter. Plus, after three RGSS player crashes, it appeared to be unusable for my purposes.
So this issue has stumped me for quite some time, and has stumped everyone else who I have asked about it.
If there are any additional tests I can perform to help narrow down this issue, I will gladly do them. Any information would be of great help and I would be very appreciative. Thank you!
Frustrating Screen Jitter Issue
● ARCHIVED · READ-ONLY
-
-
Most probably my guess is wrong, but I remember topics about a bug in the game engine that caused problems when the player speed was set to slowest due to coordinate rounding, and that there was a fix for that bug in the official bugfixes.
But even if that is not the cause of your problem, it might be worth the time to check those parts of the engine to see if the effect is caused by something similiar.
Here is the link to the fix for that bug: http://pastebin.com/XDd0tVWJ -
I am probably wrong but have you tried reinstalling Vx Ace? It might fix it but then again it might not. Hope it helps if you choose to reinstall :)
-
no clue if it will help or not, but might look at this as well
http://www.rpgmakervxace.net/topic/13662-lune-smooth-camera-slide/ -
Sounds like player movement is using an excessive amount of resources (with those script combinations) somehow. it may be a default engine function that is called excessively (that is slow) or something excessively called with the script combinations. Also, do any of those scripts save anything between saved games (and new games)? For that could be the reason that the jitter persists when the scripts are removed (especially if the default scripts use what is saved).
Although I can't guarantee anything, I can take a look for you to see if I can find anything (I am a scripter after all and I want to see your game be completed due to it being so awesome). -
Have you tried this as well? http://forums.rpgmakerweb.com/index.php?/topic/17448-event-jitter-fix-display-rounding-error-fix/
-
Hey guys, thanks for the responses thus far, I will try to respond to each question/suggestions:
@Andar and Archeia: Thanks for the links to the script. I did have that script though in place. It fixes the event jitter thing which I noticed when Ace first came out, but this screen jitter does not seem to have anything to do with events. But all the same, this script does not seem to address the issue.
@FireBird: Seems highly doubtful that would do anything. I have the English retail version of VXAce purchased through this sight on my laptop, and have the Steam version installed on my PC, both produce the screen jitter. Further, this jitter seems to be solely happening to Aleph. No other RM games seem to have it. I don't recall coming across it when making Ashworth for the IGMC either. Further, I have encountered this when I originally was developing Aleph in RPG Maker VX, before Ace was ever released.
@Venka: Thanks for the link, this is a really nifty script :) It helps in the sense that it makes the jitter less obvious, but it does not remove the jitter all the same unfortunately.
@Awesomecool: I am not a scripter, so I can't say with 100% certainty that nothing gets saved between New Games, but with the scripts I tested, I really highly doubt that is the case. Further, in my experience, whenever something like that has occurred in the past, the result is usually a fps drop. The screen jitter persists regardless of the fps being 60 or any other number, even with a bare bones amount of scripts. The scripts I happened to be testing with at the time were YEA Ace Core (the recommended one for the high-res dll) and a couple of Dekita's scripts, and Dekita is certain is has nothing to do with those. Plus, the problem has been around loooooooong since before I had those scripts regardless, so it seems highly unlikely it is those scripts specifically. I might take you up on your offer though to take a look-see, if you don't mind. But first, let me see where this thread goes before I go bothering you with it. Maybe someone might know something about this issue :) -
I don't mind helping you :) .
did you ever try using victor scripts for 8-dir and such in place of dekita's to see if the issue would go away? -
Thanks AwesomeCool, I will most likely hit ya up for that in the near future.
I did use Victor's 8-dir script and animation script as well, still had screen jitter. Generally have screen jitter even without such scripts, unfortunately. -
Hey Jesse, I'd like to help you out with this issue.
Are you able to reproduce it in a brand new project with just a single map, using all the scripts you currently have installed? If so, could you zip that up and send me a link?
I'd like to know more about the list of scripts you have, but if you can put them all into a new project so I can take a look, I can experiment myself and save heaps of questions. -
I know it wont be much help, but I truly dont think it is his scripts, I have this exact same issue using his Tiles in RPG maker, not sure if its only with his tiles but I only have 4 scripts installed, Yami Engine, Viktor diag, Viktor Character Control, Viktor MutiFrame. And just like him when using anti lag script it still dosent help the "jitter" and it does indeed happen even at 60 fps.
-
Well, if it doesn't happen when you don't add scripts, and it does happen after you add certain scripts, then it's pretty much got to have something to do with the scripts.
If you get rid of those scripts from your game, does it still happen? -
I have deleted all of my scripts, and even checked if the events had any selected to parallel processing- for me anyways the screen still jitters- even when Im not using screen resolution, idk, its not really lag it really does seem like a little Jitter
(All of my events are set to action trigger) -
@Shaz: In the near future I will try and whip up a test project that contains a minimal amount of resources and such to reproduce the issue.
I also hear what you are saying "Well, if it doesn't happen when you don't add scripts, and it does happen after you add certain scripts, then it's pretty much got to have something to do with the scripts." - but that is kind of part of the issue, it doesn't seem to matter what script I add after a certain point, screen jitters appear. Could be a fog script, could be a shop scene, doesn't seem to matter. That is what makes this issue particularly elusive thus far. If it was a case of a single script or even a couple of scripts in tandem doing this, I would have found it by now because I have gone through my script list numerous times disabling each script, starting from scratch and adding one script at a time, etc.
At any rate, I will whip up a test project to share soon. Thank you guys for your willingness to help! :) -
This is just a random hunch but... How are enemy encounters set up in your game? I ask because for a while I'd noticed a very similar occurrence in my game, that ended up being a combination of an overlay of some kind and the way a certain events autonomous movement was set. Basically it turned out like this, I had a completely evented encounter system where enemies would chase you, but return to their origin once they 'lost site' of you. For some reason, on a map with an overlay of any kind if the enemy tried to return to it's origin and the player moved the opposite direction the screen would jitter and jump around until either the event in question returned to it origin and resumed patrol or the player stopped moving. Without an overlay on the screen the same events and maps produced no problem though. Probably not your issue as it's to specific but just in case...
-
@Alexander Amnell - Right now, monsters randomly spawn on map through a script, and will give chase to a player if within X tiles. However, the screen jitter still appears even when these scripts are removed and there are no events on the map.
-
Yea, this is what I thought too :pWell, if it doesn't happen when you don't add scripts, and it does happen after you add certain scripts, then it's pretty much got to have something to do with the scripts.
If you get rid of those scripts from your game, does it still happen?
Initially when I first seen the issue (a few months ago now..) I thought it may have been caused by the events respawning. Its only recently, when Jesse began to put everything into a new project - I suggested it may hep to isolate the issue, again thinking it would be caused by some number of conflicting methods or something but no, that doesnt seem to be the case at all.
The scripts of mine in the project can contribute to small FPS drops at times, for example - the first time you move diagonally the diagonal spritesheet is loaded, FPS drops a few for a second and then goes back to normal, then each other time diagonal movement is performed the spritesheet has already been cached so its no real loading time at all. The FPS drop from the character scripts is slightly noticeable, but again, this effects FPS, not the jitteryness of the character.
The FOG script can also cause a little FPS drop - as any fog script would, its literally, as efficient as I can make it. (not my first fog script, so I have a good idea on efficiency for planes). The FPS drop from the fogs, is based on how many fogs you are using and the screen resolution. These are things outwith the normal scripters control and seems to lie within the way the hidden Graphics module processes things.
Previously, I have noticed this kind of jitter a few times..
1 - When movement speed is a floating point number (ie, not a whole number like 1,2,3,4,56... but a decimal number such as 3.6). There are fixes for such things available as mentioned previously in this post, so I wont go into that much...
2 - When MASS calculations are being performed (inefficiently) for each character's statistics. Example: If you are using poorly written calc's for the method 'params(param_id)'. things like excessive eval-ing, calling other cpu heavy methods within your calculations, or over calling methods unnecessary times. Things like calling the method 'example(id)' when that method simply returns '@example[id]' variable (an array)... There are many other things, but since this is not the case here, no need to go too into depth with that...
3 - When an event is being initialized and moved to a location on the map. This seems to cause a little jitter, but providing there are not alot of events doing this simultaneously, it generally doesn't cause a noticable jitter.
Anyway, not sure if this information helps really... More a case of what it isnt rather than what it is. :D -
I've had that happen with some Ace games and it seems to occur if multiple movement events that had player and NPC movements on a map and a good number of events running in the background. Certain scripts I noticed tend to cause it to occur more too.
Out of curiosity do you find that it jitters less if you try running the game after rebooting your computer than if you are running the game and you had your computer and that the jitter occur less often after reboot but become more prominent latter on.
Are any of the scripts you using Japanese ones out of curiosity too? I've noticed jitters happen more when playing games that use Japanese scripts or when working on translating Japanese Ace games in the English version of Ace. -
@Shaz and AwesomeCool - I sent you both a zip with some test projects in it, and a readme which explains what is in each one and how much screen jitter is present in each one. Any thoughts, help, and so forth are greatly appreciated, and thank you very much for taking a look! :)
Edit: In ScreenJitter 1, I actually am noticing screen jitter a bit - and there are zero scripts, no datafiles, etc present. It is a completely fresh project with 3 tiles and a character imported.
@Jay_NOLA: The jitter exists even with zero events on the map. Rebooting does not do anything, and it occurs on all PCs, laptops, etc that I have tested it on, plus other people have reported it as well. No scripts I use are Japanese. The jitter can occur with a very bare minimal amount of scripts present. -
I will also have a look in the test project tonight and see if anything stands out :)