Z3r0K00l

Member
Aug 30, 2022
180
430
Holy fucking shit, thanks a lot my man, but i gotta know; how did you come across this? were you going file by file looking for something that caught your eye or were you familiar with issues like this?
Also, how long have you been programming for? Like how much do you have to know for you to just read a function and say "Yea, this function on plugin #34 is causing the memory leak". Or does it just come as common sense as time goes on?
Hahaha, nah i got a bit lucky. I reasoned it was a memory leak going by how much the ram consumption keep growing, after that i spend way too many hours looking up the stack call trace and the js heap snapshot of the game. The file RBR_Core popped up way too many times there was resource intensive work, so i guessed one of the functions in the file was being called to many times, i didn't expect to find the cause of the leak right there though, that was a lucky break. I realised it was a leaking function because it instantiated an object each time it was called and it never checked if the object already existed or not.

When it comes to programming im just an amateur, i'm getting into it just now (6 months or so).
 
Aug 4, 2017
280
464
Hahaha, nah i got a bit lucky. I reasoned it was a memory leak going by how much the ram consumption keep growing, after that i spend way too many hours looking up the stack call trace and the js heap snapshot of the game. The file RBR_Core popped up way too many times there was resource intensive work, so i guessed one of the functions in the file was being called to many times, i didn't expect to find the cause of the leak right there though, that was a lucky break. I realised it was a leaking function because it instantiated an object each time it was called and it never checked if the object already existed or not.

When it comes to programming im just an amateur, i'm getting into it just now (6 months or so).
Yeah, same but im only 3 months in.
I tried out your fix, and its now playable but im still getting just around 15 fps. Whenever i open the menu or settings the game goes to 30 so i suppose there is something else in the background like the issue you just found. There was a guy earlier that claimed to have found 4 or so plugins that were the cause of the lag but idk how to disable them without breaking the game. And the dev pretty much refuses to take a look at the plugins so my guess is: either its too much of a hassle to remove those ones, or the game breaks if you take them out.
 

nefernefer

Newbie
Feb 9, 2021
23
8
could you name a few of them?
Here you go

Only in 1.1.2: audio
Only in 1.0.5: chromedriver.exe
Files 1.1.2/credits.html and 1.0.5/credits.html differ
Files 1.1.2/d3dcompiler_47.dll and 1.0.5/d3dcompiler_47.dll differ
Only in 1.1.2: data
Only in 1.1.2: debug.log
Files 1.1.2/ffmpeg.dll and 1.0.5/ffmpeg.dll differ
Only in 1.1.2: fonts
Files 1.1.2/Game.exe and 1.0.5/Game.exe differ
Only in 1.1.2: icon
Files 1.1.2/icudtl.dat and 1.0.5/icudtl.dat differ
Only in 1.1.2: img
Only in 1.1.2: index.html
Only in 1.1.2: js
Files 1.1.2/libEGL.dll and 1.0.5/libEGL.dll differ
Files 1.1.2/libGLESv2.dll and 1.0.5/libGLESv2.dll differ
Only in 1.1.2/locales: af.pak
Only in 1.1.2/locales: af.pak.info
Files 1.1.2/locales/am.pak and 1.0.5/locales/am.pak differ
Files 1.1.2/locales/am.pak.info and 1.0.5/locales/am.pak.info differ
Files 1.1.2/locales/ar.pak and 1.0.5/locales/ar.pak differ
Files 1.1.2/locales/ar.pak.info and 1.0.5/locales/ar.pak.info differ
Only in 1.1.2/locales: ar-XB.pak
Only in 1.1.2/locales: ar-XB.pak.info
Files 1.1.2/locales/bg.pak and 1.0.5/locales/bg.pak differ
Files 1.1.2/locales/bg.pak.info and 1.0.5/locales/bg.pak.info differ
Files 1.1.2/locales/bn.pak and 1.0.5/locales/bn.pak differ
Files 1.1.2/locales/bn.pak.info and 1.0.5/locales/bn.pak.info differ
Files 1.1.2/locales/ca.pak and 1.0.5/locales/ca.pak differ
Files 1.1.2/locales/ca.pak.info and 1.0.5/locales/ca.pak.info differ
Files 1.1.2/locales/cs.pak and 1.0.5/locales/cs.pak differ
Files 1.1.2/locales/cs.pak.info and 1.0.5/locales/cs.pak.info differ
Files 1.1.2/locales/da.pak and 1.0.5/locales/da.pak differ
Files 1.1.2/locales/da.pak.info and 1.0.5/locales/da.pak.info differ
Files 1.1.2/locales/de.pak and 1.0.5/locales/de.pak differ
Files 1.1.2/locales/de.pak.info and 1.0.5/locales/de.pak.info differ
Files 1.1.2/locales/el.pak and 1.0.5/locales/el.pak differ
Files 1.1.2/locales/el.pak.info and 1.0.5/locales/el.pak.info differ
Files 1.1.2/locales/en-GB.pak and 1.0.5/locales/en-GB.pak differ
Files 1.1.2/locales/en-GB.pak.info and 1.0.5/locales/en-GB.pak.info differ
Files 1.1.2/locales/en-US.pak and 1.0.5/locales/en-US.pak differ
Files 1.1.2/locales/en-US.pak.info and 1.0.5/locales/en-US.pak.info differ
Only in 1.1.2/locales: en-XA.pak
Only in 1.1.2/locales: en-XA.pak.info
Files 1.1.2/locales/es-419.pak and 1.0.5/locales/es-419.pak differ
Files 1.1.2/locales/es-419.pak.info and 1.0.5/locales/es-419.pak.info differ
Files 1.1.2/locales/es.pak and 1.0.5/locales/es.pak differ
Files 1.1.2/locales/es.pak.info and 1.0.5/locales/es.pak.info differ
Files 1.1.2/locales/et.pak and 1.0.5/locales/et.pak differ
Files 1.1.2/locales/et.pak.info and 1.0.5/locales/et.pak.info differ
Files 1.1.2/locales/fa.pak and 1.0.5/locales/fa.pak differ
Files 1.1.2/locales/fa.pak.info and 1.0.5/locales/fa.pak.info differ
Files 1.1.2/locales/fil.pak and 1.0.5/locales/fil.pak differ
Files 1.1.2/locales/fil.pak.info and 1.0.5/locales/fil.pak.info differ
Files 1.1.2/locales/fi.pak and 1.0.5/locales/fi.pak differ
Files 1.1.2/locales/fi.pak.info and 1.0.5/locales/fi.pak.info differ
Files 1.1.2/locales/fr.pak and 1.0.5/locales/fr.pak differ
Files 1.1.2/locales/fr.pak.info and 1.0.5/locales/fr.pak.info differ
Files 1.1.2/locales/gu.pak and 1.0.5/locales/gu.pak differ
Files 1.1.2/locales/gu.pak.info and 1.0.5/locales/gu.pak.info differ
Files 1.1.2/locales/he.pak and 1.0.5/locales/he.pak differ
Files 1.1.2/locales/he.pak.info and 1.0.5/locales/he.pak.info differ
Files 1.1.2/locales/hi.pak and 1.0.5/locales/hi.pak differ
Files 1.1.2/locales/hi.pak.info and 1.0.5/locales/hi.pak.info differ
Files 1.1.2/locales/hr.pak and 1.0.5/locales/hr.pak differ
Files 1.1.2/locales/hr.pak.info and 1.0.5/locales/hr.pak.info differ
Files 1.1.2/locales/hu.pak and 1.0.5/locales/hu.pak differ
Files 1.1.2/locales/hu.pak.info and 1.0.5/locales/hu.pak.info differ
Files 1.1.2/locales/id.pak and 1.0.5/locales/id.pak differ
Files 1.1.2/locales/id.pak.info and 1.0.5/locales/id.pak.info differ
Files 1.1.2/locales/it.pak and 1.0.5/locales/it.pak differ
Files 1.1.2/locales/it.pak.info and 1.0.5/locales/it.pak.info differ
Files 1.1.2/locales/ja.pak and 1.0.5/locales/ja.pak differ
Files 1.1.2/locales/ja.pak.info and 1.0.5/locales/ja.pak.info differ
Files 1.1.2/locales/kn.pak and 1.0.5/locales/kn.pak differ
Files 1.1.2/locales/kn.pak.info and 1.0.5/locales/kn.pak.info differ
Files 1.1.2/locales/ko.pak and 1.0.5/locales/ko.pak differ
Files 1.1.2/locales/ko.pak.info and 1.0.5/locales/ko.pak.info differ
Files 1.1.2/locales/lt.pak and 1.0.5/locales/lt.pak differ
Files 1.1.2/locales/lt.pak.info and 1.0.5/locales/lt.pak.info differ
Files 1.1.2/locales/lv.pak and 1.0.5/locales/lv.pak differ
Files 1.1.2/locales/lv.pak.info and 1.0.5/locales/lv.pak.info differ
Files 1.1.2/locales/ml.pak and 1.0.5/locales/ml.pak differ
Files 1.1.2/locales/ml.pak.info and 1.0.5/locales/ml.pak.info differ
Files 1.1.2/locales/mr.pak and 1.0.5/locales/mr.pak differ
Files 1.1.2/locales/mr.pak.info and 1.0.5/locales/mr.pak.info differ
Files 1.1.2/locales/ms.pak and 1.0.5/locales/ms.pak differ
Files 1.1.2/locales/ms.pak.info and 1.0.5/locales/ms.pak.info differ
Files 1.1.2/locales/nb.pak and 1.0.5/locales/nb.pak differ
Files 1.1.2/locales/nb.pak.info and 1.0.5/locales/nb.pak.info differ
Files 1.1.2/locales/nl.pak and 1.0.5/locales/nl.pak differ
Files 1.1.2/locales/nl.pak.info and 1.0.5/locales/nl.pak.info differ
Files 1.1.2/locales/pl.pak and 1.0.5/locales/pl.pak differ
Files 1.1.2/locales/pl.pak.info and 1.0.5/locales/pl.pak.info differ
Files 1.1.2/locales/pt-BR.pak and 1.0.5/locales/pt-BR.pak differ
Files 1.1.2/locales/pt-BR.pak.info and 1.0.5/locales/pt-BR.pak.info differ
Files 1.1.2/locales/pt-PT.pak and 1.0.5/locales/pt-PT.pak differ
Files 1.1.2/locales/pt-PT.pak.info and 1.0.5/locales/pt-PT.pak.info differ
Files 1.1.2/locales/ro.pak and 1.0.5/locales/ro.pak differ
Files 1.1.2/locales/ro.pak.info and 1.0.5/locales/ro.pak.info differ
Files 1.1.2/locales/ru.pak and 1.0.5/locales/ru.pak differ
Files 1.1.2/locales/ru.pak.info and 1.0.5/locales/ru.pak.info differ
Files 1.1.2/locales/sk.pak and 1.0.5/locales/sk.pak differ
Files 1.1.2/locales/sk.pak.info and 1.0.5/locales/sk.pak.info differ
Files 1.1.2/locales/sl.pak and 1.0.5/locales/sl.pak differ
Files 1.1.2/locales/sl.pak.info and 1.0.5/locales/sl.pak.info differ
Files 1.1.2/locales/sr.pak and 1.0.5/locales/sr.pak differ
Files 1.1.2/locales/sr.pak.info and 1.0.5/locales/sr.pak.info differ
Files 1.1.2/locales/sv.pak and 1.0.5/locales/sv.pak differ
Files 1.1.2/locales/sv.pak.info and 1.0.5/locales/sv.pak.info differ
Files 1.1.2/locales/sw.pak and 1.0.5/locales/sw.pak differ
Files 1.1.2/locales/sw.pak.info and 1.0.5/locales/sw.pak.info differ
Files 1.1.2/locales/ta.pak and 1.0.5/locales/ta.pak differ
Files 1.1.2/locales/ta.pak.info and 1.0.5/locales/ta.pak.info differ
Files 1.1.2/locales/te.pak and 1.0.5/locales/te.pak differ
Files 1.1.2/locales/te.pak.info and 1.0.5/locales/te.pak.info differ
Files 1.1.2/locales/th.pak and 1.0.5/locales/th.pak differ
Files 1.1.2/locales/th.pak.info and 1.0.5/locales/th.pak.info differ
Files 1.1.2/locales/tr.pak and 1.0.5/locales/tr.pak differ
Files 1.1.2/locales/tr.pak.info and 1.0.5/locales/tr.pak.info differ
Files 1.1.2/locales/uk.pak and 1.0.5/locales/uk.pak differ
Files 1.1.2/locales/uk.pak.info and 1.0.5/locales/uk.pak.info differ
Only in 1.1.2/locales: ur.pak
Only in 1.1.2/locales: ur.pak.info
Files 1.1.2/locales/vi.pak and 1.0.5/locales/vi.pak differ
Files 1.1.2/locales/vi.pak.info and 1.0.5/locales/vi.pak.info differ
Files 1.1.2/locales/zh-CN.pak and 1.0.5/locales/zh-CN.pak differ
Files 1.1.2/locales/zh-CN.pak.info and 1.0.5/locales/zh-CN.pak.info differ
Files 1.1.2/locales/zh-TW.pak and 1.0.5/locales/zh-TW.pak differ
Files 1.1.2/locales/zh-TW.pak.info and 1.0.5/locales/zh-TW.pak.info differ
Only in 1.0.5: nacl_irt_x86_64.nexe
Files 1.1.2/node.dll and 1.0.5/node.dll differ
Files 1.1.2/notification_helper.exe and 1.0.5/notification_helper.exe differ
Files 1.1.2/nw_100_percent.pak and 1.0.5/nw_100_percent.pak differ
Files 1.1.2/nw_200_percent.pak and 1.0.5/nw_200_percent.pak differ
Files 1.1.2/nw.dll and 1.0.5/nw.dll differ
Files 1.1.2/nw_elf.dll and 1.0.5/nw_elf.dll differ
Only in 1.0.5: nwjc.exe
Files 1.1.2/package.json and 1.0.5/package.json differ
Only in 1.0.5: payload.exe
Only in 1.0.5: pnacl
Only in 1.0.5: Readme_en.txt
Only in 1.1.2: Readme.txt
Files 1.1.2/resources.pak and 1.0.5/resources.pak differ
Only in 1.1.2: save
Files 1.1.2/swiftshader/libEGL.dll and 1.0.5/swiftshader/libEGL.dll differ
Files 1.1.2/swiftshader/libGLESv2.dll and 1.0.5/swiftshader/libGLESv2.dll differ
Files 1.1.2/v8_context_snapshot.bin and 1.0.5/v8_context_snapshot.bin differ
Only in 1.1.2: vk_swiftshader.dll
Only in 1.1.2: vk_swiftshader_icd.json
Only in 1.1.2: vulkan-1.dll
Only in 1.0.5: www
 
  • Like
Reactions: BobaTheOrc

Z3r0K00l

Member
Aug 30, 2022
180
430
Yeah, same but im only 3 months in.
I tried out your fix, and its now playable but im still getting just around 15 fps. Whenever i open the menu or settings the game goes to 30 so i suppose there is something else in the background like the issue you just found. There was a guy earlier that claimed to have found 4 or so plugins that were the cause of the lag but idk how to disable them without breaking the game. And the dev pretty much refuses to take a look at the plugins so my guess is: either its too much of a hassle to remove those ones, or the game breaks if you take them out.
The plugin that the dev uses to support multiple languages wastes a lot of cpu cycles at runtime, it basically searches for the appropriate line in a JSON file and loads it up & displays it in the screen as you play. taking it out would mean rewriting the entire system used to support multiple languages though.
 
Aug 4, 2017
280
464
The plugin that the dev uses to support multiple languages wastes a lot of cpu cycles at runtime, it basically searches for the appropriate line in a JSON file and loads it up & displays it in the screen as you play. taking it out would mean rewriting the entire system used to support multiple languages though.
That'd suck but, I mean, the game basically plays itself and very little dialogue is actually descriptive enough to say you are missing out.
 

Rosen King

Engaged Member
May 29, 2019
2,149
1,630
So, i found the leak and fixed it. Turns out the function which drew the time on the top right of the screen was creating a new bitmap object every frame and that resulted in massive ram usage. This leak was most noticeable in battles and caused the game to drop to one fps and crash eventually (unless you got massive amounts of ram and a SSD).
The function in questions was in line 382 of the RBR_Core.js plugin, whose name was "displayText".

JavaScript:
Sprite_Time.prototype.displayText = function () {
  this.bitmap = new Bitmap(Graphics.width, Graphics.height);
  this.bitmap.clear();
  this.opacity = 255;
  if (SceneManager._scene instanceof Scene_Battle)
    this.bitmap.drawText($lgcMgr.formatTime(), Graphics.width - 100 - 150, 60, 100, 30, 'right');
  else if (SceneManager._scene instanceof Scene_Menu)
    this.bitmap.drawText($lgcMgr.formatTime(), 130, 330, 100, 30, 'left');
I just added a conditional check to stop it from creating a new object every god damn frame:
JavaScript:
Sprite_Time.prototype.displayText = function () {
  // if the object exists dont instantiate it again.
  if(!this.bitmap) this.bitmap = new Bitmap(Graphics.width, Graphics.height);
  this.bitmap.clear();
  this.opacity = 255;
  if (SceneManager._scene instanceof Scene_Battle)
    this.bitmap.drawText($lgcMgr.formatTime(), Graphics.width - 100 - 150, 60, 100, 30, 'right');
  else if (SceneManager._scene instanceof Scene_Menu)
    this.bitmap.drawText($lgcMgr.formatTime(), 130, 330, 100, 30, 'left');
This bug is still present in version 1.1.3 and i dont know if the author fixed it in version 1.1.4 the patch notes dont mention it so im guessing no.

This means that the author can stop downgrading the graphics and give us back the HD pictures that were in the 1.0 release.

You can change the code like i did or you can just overwrite your RBR_Core.js file with mine, just unzip it and drop it in js/plugins/ and overwrite the file.

There might be more bugs left but this one was game breaking, the rest are up to the dev.
Have you let the dev know about it? I've noticed a lot of people claim to have found a fix for issues in various games but then never actually tell the dev about it, so the game never actually gets fixed. Just wanna make sure this doesn't fall into that same trap.
 
  • Like
Reactions: Susan Xandera

Z3r0K00l

Member
Aug 30, 2022
180
430
Have you let the dev know about it? I've noticed a lot of people claim to have found a fix for issues in various games but then never actually tell the dev about it, so the game never actually gets fixed. Just wanna make sure this doesn't fall into that same trap.
Yeah, i did. i think version 1.2.0 has a fix for the issue.

Screenshot from 2023-08-23 10-20-07.png
 

DiniusHS

Exhausted
Game Developer
Nov 4, 2019
82
112
Facts, more tattoos, piercings, tanlines, makeup, etc would be great. Skin colour difference, more enemy rape, gangbang, kissing, rimjobs, etc.

This is a mini Karryn's Prison lol
unfortunately dev doesn't seem to be going to add more content to the game and just gonna move on
 

esxay

Member
Nov 24, 2017
191
189
Facts, more tattoos, piercings, tanlines, makeup, etc would be great. Skin colour difference, more enemy rape, gangbang, kissing, rimjobs, etc.

This is a mini Karryn's Prison lol
Outfitting, routing and customization is slippy road for 2d devs. You will be tired to draw each variation for each outfit. Remember malice and the machine(Abandoned), defenestration(1 update per year), insexsity also suffered from this when they decided to add 2 more breast sizes(They had to edit nearly 200 animations) also bloating the game size without actual adding of content.
Tanlines? :FacePalm:
 

yurilover8

Member
Dec 1, 2018
485
291
Outfitting, routing and customization is slippy road for 2d devs. You will be tired to draw each variation for each outfit. Remember malice and the machine(Abandoned), defenestration(1 update per year), insexsity also suffered from this when they decided to add 2 more breast sizes(They had to edit nearly 200 animations) also bloating the game size without actual adding of content.
Tanlines? :FacePalm:
Fair point but this game doesn't have much content to begin with, its quality is good but quantity is low. At least we could have gotten different skin colours lol
 

esxay

Member
Nov 24, 2017
191
189
Fair point but this game doesn't have much content to begin with, its quality is good but quantity is low. At least we could have gotten different skin colours lol
It's better to add a different wearing for a special state, like rule for collar/leash when enslaved, stark naked.
 
2.90 star(s) 32 Votes