Web Deployment laggy on Raspberry Pi 4b 8gb

Basically says it all. You can view the website I made through RPG maker here:

Antimtr

If you have a raspberry pi you'll definitely see the problem. If you don't... I've tested it with basically every PC and smartphone belonging to me and my family members and only experienced the issue once; refreshed my server and it resolved the issue that one time. One other time someone's hardware acceleration was off so java wouldn't load.

Things I've tried to resolve the issue on my raspberry pi:

  • 6+ different browsers (Chromium, Firefox, and several branches of each)
    • a plethora of different "experimental" settings within each browser
  • 4+ different Operating Systems
  • Resolving YEP incompatibility by substituting with Visustella instead of using FOSSIL
  • Removing every single plugin both one at a time and altogether then reuploading and trying again
  • Having 3 pro devs search the code for bad optimization--they all ran away scared of this monster
  • Changing backend optimizations on my server
  • Overclocking my Pi
  • Putting more RAM allocation to GPU on my Pi
  • Several different power supplies for my Pi
  • Every resolution on multiple different screens for my Pi

Plugins (because I know you'll want this info even if I have already tested it):

  • YEP Core
  • Yep EventHitboxResize
  • Yep EventClickTrigger
  • MRP Mousemove (rewritten to work with touch input as well)
  • Community Lighting
  • MOG Weather EX
  • THEO disable touch UI
  • Generic Mouse Clickbox Removal
  • Generic TitleEdit
  • and FOSSIL

I want to use a Raspberry PI cyberdeck I'm custom building to demo the website at comic cons. So the question is... am I just screwed or is there a hail mary to be found here?
What are the technical specifications for that computer?

If I remember correctly the rasperry computers are optimized for battery life/low power consumption and not for high CPU power.
And that WILL cause you problems for the more javascript-intense website and HTML games.

you might get better performance when upgrading the device - but that would mean faster CPU and more RAM total (distributing more or less RAM to GPU does not have any effect if the total RAM is too low, especially as the RM games rarely use the GPU at all unless you go with extreme lighting or 3D effecst).
  • Broadcom BCM2711, Quad core Cortex-A72 (ARM v8) 64-bit SoC @ 1.8GHz
  • 8GB LPDDR4-3200 SDRAM
  • 256GB USB 3.1 Boot drive
I had considered the possibility, just really surprised that a 6 year old budget android phone can run something smoothly that a raspberry pi 4 can't. To determine if it's performance related beyond all reasonable doubt, I went ahead and dropped an absurd amount on an Orange Pi 5 plus...

  • Rockchip RK3588 (8nm LP process)
  • CPU: 8-core 64-bit processor 4 x Cortex-A76(2.4GHz), 4 x Cortex-A55(1.8GHz) and separate NEON co-processors
  • GPU: Arm Mali-G610 Built-in 3D GPU Compatible with OpenGL ES1.1/2.0/3.2, OpenCL 2.2 and Vulkan 1.2
  • RAM: 32GB(LPDDR4/4X)
At this point, cost wise, I should've just dismantled a laptop... :rtear:

I will update once this is set up and tested.
Update: The Orange Pi 5 Plus 32GB resolved the issue... kind of.

With the new system set up, using Chromium as the browser, the game runs smoothly, except on the starting map. If you exit the starting map and then return, it still runs slow. Now keep in mind this is not molasses low--it's just not perfect. This is a problem that I've actually witnessed transiently on various high powered systems, so mentally I'm returning to two possible culprits: poor code optimization. Intermittent web server issues. Considering the issue is only happening on one map, I'm leaning toward poor code optimization--but as mentioned previously I have explored every avenue I can conceive short of having an expert optimize the code for me.

Thoughts?
Technically there is no difference between the starting map and any other map.
However many developers place the setup events on the starting map, and if someone messes those up then I can easily see that specific map being slower than others.

But that effect is caused by those events and if the events are optimized it should no longer slow anyone down.
Technically there is no difference between the starting map and any other map.
However many developers place the setup events on the starting map, and if someone messes those up then I can easily see that specific map being slower than others.

But that effect is caused by those events and if the events are optimized it should no longer slow anyone down.
Any insight into why it would only happen intermittently on a seemingly completely random basis then?
THat has too many options, including what the computer itself does on background processes and when.
There is no true randomness in any computer however, everything has a cause. even the random generators are not truly random, they just use a chaotic formula to appear random to the player - but with the same seed the result is always identical.

So you'll have to pinpoint the cause a bit more before anyone can guess.
THat has too many options, including what the computer itself does on background processes and when.
There is no true randomness in any computer however, everything has a cause. even the random generators are not truly random, they just use a chaotic formula to appear random to the player - but with the same seed the result is always identical.

So you'll have to pinpoint the cause a bit more before anyone can guess.
I'll file that lesson under common knowledge. On my end, I've exhausted any and all pinpointing I can figure on with over a dozen hours of research. That's why I'm asking for suggestions in this thread. There are some issues noted in the console with the YEP core plugin (which you can see if you inspect the page), but I've already tried completely eliminating that plugin set and it doesn't resolve anything. I'll look into events as you mentioned. Maybe there's something there. An event on the main map causing lag.
sorry that I can't help more either - remote support is always difficult, even if you know exactly what is happening at the other side. But if there are too many questions open that will cause additional problems with looking for causes.
sorry that I can't help more either - remote support is always difficult, even if you know exactly what is happening at the other side. But if there are too many questions open that will cause additional problems with looking for causes.
Thinking more about what you said regarding events, I spent an hour or so looking at the 3 current maps trying to determine what might be different about the first map. I saw a possibility (Please keep in mind that I've built this monster with literally no dev background and very limited coding skills!): The entry map has a number of parallel events on it that the other maps don't. I've taken screenshots to share with you and they are attached.

Reading more into how parallel events run, I'm wondering if the problem is really this simple. If the map is slow because these processes are running on an infinite loop. BUT if that's the case--how do I resolve this while still having these settings changes applied? I tried doing it as autorun, but that still leaves the event looping with the added issue of not allowing me to run other events.

( It's a big headache to test if the problem persists after deleting these events because the problem only happens on some devices sometimes. smh. D; )

example 2.png
example 1.png

example 3.png
All of that can be 1 event. Also why is there a loop, parallel events already loop. All of these events are being called 60 times a second.

Put all of that into one event with erase event or a self switch at the end.
All of that can be 1 event. Also why is there a loop, parallel events already loop. All of these events are being called 60 times a second.

Put all of that into one event with erase event or a self switch at the end.
When the rain wasn't looped it would run once and then end. There's only a loop on that one. If I put erase event at the end, then won't the weather, tint, and menu access disable command all revert? It's integral to the design of the site for the changes they make to remain active.
None of it will revert until you tell it too. Weather will stay until cleared, menu access is off until turned back on etc. Parallel processes loop until turned off, so your loop does nothing it wasn't already doing, plus it doesn't have any event commands actually in the loop or a break loop command which is literally causing it to set the weather once and then loop to doing nothing indefinitely. If for some odd reason, your weather or menu access is being reset, there's another event re-enabling them.

I don't want to sound harsh, but completing some eventing tutorials may be helpful. Good luck with your project. 🙂
None of it will revert until you tell it too. Weather will stay until cleared, menu access is off until turned back on etc. Parallel processes loop until turned off, so your loop does nothing it wasn't already doing, plus it doesn't have any event commands actually in the loop or a break loop command which is literally causing it to set the weather once and then loop to doing nothing indefinitely. If for some odd reason, your weather or menu access is being reset, there's another event re-enabling them.

I don't want to sound harsh, but completing some eventing tutorials may be helpful. Good luck with your project. 🙂
You don't sound harsh at all! And man did I complete tutorials. I watched, read, and listened to 40+ hours of RPG maker tutorials while working on this project for 5+ times that, but somehow the one thing that slipped by me was how to properly end events. I had thought--'certainly rpg maker would by now have an obvious and beginner friendly event system'.

Well, it is easy, but it ain't obvious! I read into how to properly end events with self switches rather than end event or exit event processing, and it kept the map changes. So... long story short IT SEEMS TO HAVE FIXED THE LAG! (knock on wood). Thank you so much Slaughty!

Original thread: https://forums.rpgmakerweb.com/threads/web-deployment-laggy-on-raspberry-pi-4b-8gb.167420/