Tutorial Unity How To Uncensor (Almost) Any Unity Game

Un Name

New Member
Oct 14, 2018
3
0
I'm trying to decensor ロレーナと遺跡の国 ~銃と魔法のトレジャーハンター~ ( Lorena and the Land of Ruins-Gun and Magic Treasure Hunter- )

It has three MonoScript files in every .assets file;
MosaicManagerSMN
MosaicGeneratorSMN
MosaicEntrySencerSMN


But removing any one of the MonoScript files breaks the game.

There is a material named Pixelation that breaks the game when modified, but it points to:
0 SInt64 m_PathID = 1035

There are three things at Path ID 1035, and one of them is an Unnamed asset shader which breaks the game when modified.
The other two things at ID 1035 don't seem to be mosaic related.

Edit: Some of the .assets files have a Mozaic material with no "_BlockSize" or "_CellSize" tag.
It points to ID 1021, which is an Unnamed asset shader that is 1.8GB in size when dumped, and cannot be opened for editing by Notepad or Notepad++.

I'm stuck. Can someone more experienced with Unity decensoring take a look?
 
Last edited:

Zippix

Well-Known Member
Sep 7, 2017
1,714
1,157
You don't have permission to view the spoiler content. Log in or register now.
IIRC, I asked something similar over at ULMF regarding the v1.021 of the game. The ID 1035 unnamed asset, shader, indeed worked for the v1.01, but due to some minor changes in the assets files bw versions, ID 1036 -to my immense shame (should've checked the neighbouring unnamed assets lol)...- needed to be dumped and then re-imported (and the sharedassets0.assets file then saved) with the 'colMasks values set to 0' method (it's in the first post here)...

So if it's v1.01, it's Path ID 1035, if it's v1.021, it's Path ID 1036, 'colMask' method (Shader Mosaic Removal' method), sharedassets0.assets.
 
  • Like
Reactions: Un Name

Prick

Engaged Member
Jul 17, 2017
2,113
1,906
Just a heads up, monoscript removal worked with only one game I've ever uncensored. Probably best used if you have exhausted all other methods, because 99% of the time it will CTD on launch.
It has three MonoScript files in every .assets file;
They are just duplicates being referenced within that asset. If you dump it, the title of the .txt will tell you which asset it came from. EG if all the assets contain the same "mosaic", you do NOT need to modify every asset. Just the "master" asset which holds the data for the mosaic.

There are three things at Path ID 1035, and one of them is an Unnamed asset shader which breaks the game when modified.
The other two things at ID 1035 don't seem to be mosaic related.

Edit: Some of the .assets files have a Mozaic material with no "_BlockSize" or "_CellSize" tag.
It points to ID 1021, which is an Unnamed asset shader that is 1.8GB in size when dumped, and cannot be opened for editing by Notepad or Notepad++.
Path ID is kinda weird, I don't know exactly why you will find multiple assets sharing the same ID. But you always want the unnamed shader. If you must know what that shader is actually named, open the same asset with UAS, for some reason UABE won't read the names of certain shaders.

If you modify a shader and it crashes your game, you've done something wrong.
If you modify a shader and it results in unusual colors or invisible body parts, you've got the wrong shader.
 

Un Name

New Member
Oct 14, 2018
3
0
ID 1035
sharedassets0.assets
colMasks values
There it is. Thank you.
For some reason I was looking in the resources.assets file (and other wrong files), assuming it was the "first" assets file or "index" for assets.

De-censor is working now. Thanks guys.
 

funog1

Member
Modder
Mar 2, 2017
429
2,397
Anyone want to point me to some censored games that run IL2CPP rather than the mono "Managed" folder?
Currently messing around with Elrit Clover and have managed a decensor, but I'm looking for more to get a better grasp on the whole situation.
 

James20001120

New Member
Apr 8, 2018
12
0
Why can't I open the files


 
Last edited:

Prick

Engaged Member
Jul 17, 2017
2,113
1,906
Why can't I open the files
If UABE is giving you a database error, it's because UABE hasn't been updated in a long time, and newer versions of Unity have some things that UABE cannot read, thus you cannot open the asset.
In any case, like dark here above me, I've already looked into this game, it's all 2D sprites and I'm not a pixel wizard.
 

herbstpoet

Active Member
Apr 18, 2018
694
1,638
So I tried my luck with "Sleeping Sister" and found pixelation and pixelation_fader in sharedassets1 and sharedassets2. Dumped both from sharedassets1, both didn't have the blocksize but the cellsize entry and changed red and green in both to 1.17549435e-038 like the tutorial said, the original value was 0.200000003. After that imported both and made sure to import each one to the right material. Saved and did the same again with sharedassets2.

Now here comes the strange part: When I saved the edited sharedassets2 it wanted to be saved as sharedassets1 but I saved it as sharedassets2. I put both back in the data folder and started the game. Everything was fine until I went to the sex gameplay part. Instead of the game scene I just got this...

image1.png

Any possible solution?
When leaving the scene the game crashed. When I edited only sharedassets1 and left sharedassets2 unchanged I get the same screen but can still leave the scene and go back to the main menu.
 
Nov 22, 2018
298
266
So I tried my luck with "Sleeping Sister" and found pixelation and pixelation_fader in sharedassets1 and sharedassets2. Dumped both from sharedassets1, both didn't have the blocksize but the cellsize entry and changed red and green in both to 1.17549435e-038 like the tutorial said, the original value was 0.200000003. After that imported both and made sure to import each one to the right material. Saved and did the same again with sharedassets2.

Now here comes the strange part: When I saved the edited sharedassets2 it wanted to be saved as sharedassets1 but I saved it as sharedassets2. I put both back in the data folder and started the game. Everything was fine until I went to the sex gameplay part. Instead of the game scene I just got this...

View attachment 995826

Any possible solution?
When leaving the scene the game crashed. When I edited only sharedassets1 and left sharedassets2 unchanged I get the same screen but can still leave the scene and go back to the main menu.
Only "pixelation" in sharedassets1 is needed to edit, according to Japanese version.
You may also see the "pixelation" in sharedassets2, but it belongs to sharedassets1.
 

herbstpoet

Active Member
Apr 18, 2018
694
1,638
Only "pixelation" in sharedassets1 is needed to edit, according to Japanese version.
You may also see the "pixelation" in sharedassets2, but it belongs to sharedassets1.
Ok, that might explain why the game crashed when editing both files but like I said just editing sharedassets1 doesn't help either.
 

funog1

Member
Modder
Mar 2, 2017
429
2,397
When I edited only sharedassets1 and left sharedassets2 unchanged I get the same screen but can still leave the scene and go back to the main menu.
If you still have an empty scene after only changing the sharedassets1 pixelation, something else was messed up. Try deleting the whole thing and start over, because changing just the pixelation in sharedassets1 is all that needs to be done. It won't help the fact that the mans junk is baked censored though...
 

herbstpoet

Active Member
Apr 18, 2018
694
1,638
If you still have an empty scene after only changing the sharedassets1 pixelation, something else was messed up. Try deleting the whole thing and start over, because changing just the pixelation in sharedassets1 is all that needs to be done. It won't help the fact that the mans junk is baked censored though...
Already did that, several times. Unfortunately I can't try the shader removal method because UABE is too old and giving me a database error when trying to export it. Maybe someone with more knowledge could take a look at this?
 

Wyrmfaust

New Member
Oct 13, 2017
4
1
So im trying to run Marcos BepInEx demosaic but im seriously stuck on the "extract.dll" step. Where can i find the demosaic.dll file? I've looked over his GitHub with the demosaic stuff, but i cant find any .dll files. Do i have to have a programing environment to run something?
 

funog1

Member
Modder
Mar 2, 2017
429
2,397
Already did that, several times. Unfortunately I can't try the shader removal method because UABE is too old and giving me a database error when trying to export it. Maybe someone with more knowledge could take a look at this?
That is odd... What version of the game do you have? I've tested both a japanese and english version, they both only need the Pixelation material (PathID 2 for both versions) to be changed. Does the game work normally without any changes?

The shader method will still work even if you can't export the shader out as a dump, you have to export the raw and do some hex editing. I will make a second post explaining that later tonight.
 
  • Like
Reactions: Prick

funog1

Member
Modder
Mar 2, 2017
429
2,397
Expanding on the "Shader Mosaic Removal" portion of the guide.
So UABE hasn't had an update in quite some time now causing newer Unity games to error on dumps.

If you see 1611365972571.png while trying to dump the shader there is still hope.
You don't have permission to view the spoiler content. Log in or register now.


So what happens if you try and open the sharedasset#.assets file in UABE and you get 1612580969289.png you ask?
Answer: Almost the exact same thing.
You don't have permission to view the spoiler content. Log in or register now.

The whole process looks daunting but is quite easy if you have even a little bit of computer knowledge or can follow directions.

WARNING: These methods will replace ALL float values of 15 and make them 0 not just the colMask if there are any. I have yet to come across a shader that has other float 15s though. Always make backups.

Edit: Change of method because me wos smooth brain during the original post.
Edit2: This isn't even my final form!(Added second method)
 
Last edited: