4.60 star(s) 179 Votes

ShirouryuuAkihito

Active Member
Apr 18, 2018
635
572
278
So what are these patches? And do I need it after downloading the main game file ? Yes i read the above post but didnt get it.
So someone plz can u explain about them?
 

kin-kun

Active Member
Modder
Jul 10, 2020
963
2,582
324
So what are these patches? And do I need it after downloading the main game file ? Yes i read the above post but didnt get it.
So someone plz can u explain about them?
So the first post is confusing. It lists 2.03.06 as a patch (it isn't) and 2.03.07 as an unofficial version. It also lists a compressed version (2.2) which is bigger than the unofficial version.

There really is only one of two different versions you might want. Either the official 2.03 or my unofficial 2.03.07.

The official version has major spelling, grammar and wording errors. I fixed a lot of those.

Also the official game has text that overlaps the user interface. Here's an example:

image_20210514_093218.png

That is fixed as well in my version.

The official version only allows your name to be 4 characters long. Mine allows 15.

The official version doesn't work with JoiPlay (an app on Android for playing some Windows games.) My version works with JoiPlay.

The official version is over 1.1 GB in size, mine is 445 MB.

The official version is supported by Kagura, who won't fix basic things like text overlapping the UI. I support my unofficial version.

Is this enough information for you to understand what version you want?
 

ShirouryuuAkihito

Active Member
Apr 18, 2018
635
572
278
So the first post is confusing. It lists 2.03.06 as a patch (it isn't) and 2.03.07 as an unofficial version. It also lists a compressed version (2.2) which is bigger than the unofficial version.

There really is only one of two different versions you might want. Either the official 2.03 or my unofficial 2.03.07.

The official version has major spelling, grammar and wording errors. I fixed a lot of those.

Also the official game has text that overlaps the user interface. Here's an example:

View attachment 1321444

That is fixed as well in my version.

The official version only allows your name to be 4 characters long. Mine allows 15.

The official version doesn't work with JoiPlay (an app on Android for playing some Windows games.) My version works with JoiPlay.

The official version is over 1.1 GB in size, mine is 445 MB.

The official version is supported by Kagura, who won't fix basic things like text overlapping the UI. I support my unofficial version.

Is this enough information for you to understand what version you want?
Thankyou so much for the info!
 

WaMaRi

Newbie
Mar 3, 2019
26
9
21
i Already Clear all Event, (Side Character, Yui and Rio)

But.. I cant unlock Miyuki Event in Hiking in Day 14 ?? How i can unlock this ??
i already bought all skill..

1627781539314.png
 

WaMaRi

Newbie
Mar 3, 2019
26
9
21
You need to have done the scene before day 14, not just get the skill.
You mean like this ? (before day 14)
Lust Full > Leak > Pants inside Washmachine > Miyuki Found it > Talk to miyuki > se*

or

Lust Full > Leak > Pants inside Washmachine > Miyuki Found it >Ask for Se* and chose HandJob

witch one ?
 

Grex

Member
Mar 22, 2018
348
208
209
You mean like this ? (before day 14)
Lust Full > Leak > Pants inside Washmachine > Miyuki Found it > Talk to miyuki > se*

or

Lust Full > Leak > Pants inside Washmachine > Miyuki Found it >Ask for Se* and chose HandJob

witch one ?
I don´t remember exactly (since i usually don´t repeat that scene) but i believe it was the first one, with two leaks IIRC.
 

scyne

Newbie
Dec 4, 2018
20
7
21
This shows the ui issues I have using your JavaScript.
View attachment 1303153

This seems to be the function that deals with loading all of the files. But I don't see any modification that would let it ignore case.

Unless I am missing something, I am more of a cpp guy, I don't really know much webdev/js
You'd want to normalise the path parameter. Make all the game files lowercase, and then (before the const key declaration)
JavaScript:
if (typeof path === 'string' && String(path).length) {path = String(path).toLowerCase()}
...assuming path is a string.
 

kin-kun

Active Member
Modder
Jul 10, 2020
963
2,582
324
View attachment 1303081

This shows the ui issues I have using your JavaScript.
View attachment 1303153

This seems to be the function that deals with loading all of the files. But I don't see any modification that would let it ignore case.

Unless I am missing something, I am more of a cpp guy, I don't really know much webdev/js
Sorry I completely missed your post. Let me explain.

loadNormalBitmap calls to Bitmap.load

JavaScript:
/**
 * Loads a image file and returns a new bitmap object.
 *
 * @static
 * @method load
 * @param {String} url The image url of the texture
 * @return Bitmap
 */
Bitmap.load = function (url) {
    const bitmap = Object.create(Bitmap.prototype);
    bitmap._defer = true;
    bitmap.initialize();

    bitmap._decodeAfterRequest = true;
    bitmap._requestImage(url);

    return bitmap;
};

Bitmap.prototype._requestImage = function (url_in) {
    let url = CS_URL.MapURL(url_in);
    if (Bitmap._reuseImages.length !== 0) {
        this._image = Bitmap._reuseImages.pop();
    } else {
        this._image = new Image();
    }

    if (this._decodeAfterRequest && !this._loader) {
        this._loader = ResourceHandler.createLoader(url, this._requestImage.bind(this, url), this._onError.bind(this));
    }

    this._url = url;
    this._loadingState = 'requesting';

    if (!Decrypter.checkImgIgnore(url) && Decrypter.hasEncryptedImages) {
        this._loadingState = 'decrypting';
        Decrypter.decryptImg(url, this);
    } else {
        this._image.src = CS_URL.MapURL(url);

        this._image.addEventListener('load', this._loadListener = Bitmap.prototype._onLoad.bind(this));
        this._image.addEventListener('error', this._errorListener = this._loader || Bitmap.prototype._onError.bind(this));
    }
};

//-----------------------------------------------------------------------------
/**
 * The static class that handles mapping case insensitive URL calls to case
 * sensitive file names
 *
 * @class CS_URL
 */
function CS_URL() {
    throw new Error('This is a static class');
}

CS_URL.urlMap = {};
CS_URL.absolutePrefix = "";

/**
 * Initializes the CS_URL static object
 * @static
 * @method Initialize
 */
 CS_URL.Initialize = function () {
    try {
        let platform;
        try {
            CS_URL.absolutePrefix = require('path').posix.dirname(window.location.pathname);
            platform = nw.process.platform;
        } catch (ex) {
            CS_URL.MapURL = function (url) { return url; };
            Utils.isNwjs = function () { return false; };
            return;
        }
        if (platform !== "linux" && platform !== "android") {
            CS_URL.MapURL = function (url) { return url; };
        }
        else {
            CS_URL.urlMap=JSON.parse(LZMA.decompress(require('fs').readFileSync("pathdata.xz")));
        }
    } catch (ex) {
        CS_URL.MapURL = function (url) { return url; };
        return;
    }
};

/**
 * Maps a case insensitive URL to a case sensitive one
 * @static
 * @method MapURL
 * @param {String} url
 * @return {String}
 */
CS_URL.MapURL = function (url) {
    let item = url;
    // URLs follow posix rules for paths regardless of platform
    const pathUtils = require('path').posix;
    try {
        item = new URL(item).pathname;
    } catch (ex) {
    }
    if (!pathUtils.isAbsolute(item)) {
        item = pathUtils.join(CS_URL.absolutePrefix, item);
    }

    let result = CS_URL.urlMap[item];
    if (result) { return result; }
    // You can enable logging here to find files that have the wrong case
    //console.log("File \"" + item + "\" not found, trying lowercase");
    result = CS_URL.urlMap[item.toLowerCase()];
    if (result) { return result; }
    if (url !== decodeURIComponent(url)) { return CS_URL.MapURL(decodeURIComponent(url)); }
    //console.log("\"" + item + "\" still not found giving up");
    return url;
};

CS_URL.Initialize();
So we have loadrequestImageMapURL

If the urlMap contains the case sensitive name, return the value
If the urlMap contains the lowercase name, return the value
If the name has URI entries like %20 decode them and try again
Otherwise return what we were given, hoping that someone else is going to mess with it further and we can catch it later on.

The urlMap is populated by decompressing and decoding the JSON in the pathdata.xz file.

That looks like:
JSON:
{
  "/www/index.html": "/www/index.html",
  "/www/package.json": "/www/package.json",
  "/www/patch notes.txt": "/www/Patch Notes.txt",
  "/www/css/111_inputform.css": "/www/css/111_InputForm.css",
  "/www/fonts/gd-dotfont-dq-ttf_0.ttf": "/www/fonts/GD-DOTFONT-DQ-TTF_0.ttf",
  "/www/fonts/jf-dot-ayu20.ttf": "/www/fonts/JF-Dot-Ayu20.ttf",
  "/www/fonts/azuki.ttf": "/www/fonts/azuki.ttf",
  "/www/fonts/jf-dot-mplush10b.ttf": "/www/fonts/JF-Dot-MPlusH10B.ttf",
  "/www/fonts/jf-dot-ayu18.ttf": "/www/fonts/JF-Dot-Ayu18.ttf",
  "/www/fonts/jf-dot-mplusq10.ttf": "/www/fonts/JF-Dot-MPlusQ10.ttf",
  "/www/fonts/jf-dot-mplush10.ttf": "/www/fonts/JF-Dot-MPlusH10.ttf"
}
And this is built with:
Python:
#!/usr/bin/env python3

import json
import os
from pathlib import PurePosixPath
import lzma

real_path = []
# Set the directory you want to start from
rootDir = 'www'
base = PurePosixPath("/")
for dir_name, _, fileList in os.walk(rootDir):
    for file_name in fileList:
        real_path.append(base.joinpath(dir_name, file_name))
file_check={}
file_map={}
for path in real_path:
    p = PurePosixPath(path)
    inputSuffix = p.suffix
    # rewrite .avif/.webp as .png as that's what will be requested
    if(inputSuffix == ".avif"):
        inputSuffix = ".png"
    if(inputSuffix == ".webp"):
        inputSuffix = ".png"
    p_str = str(p.parent.joinpath(str(p.stem)+inputSuffix))
    p_str_lc = p_str.lower()
    if p_str_lc in file_check:
        print("Upper case/lower case collision with %s" % p_str)
        exit(1)
    else:
        file_check[p_str_lc]=1
        file_map[p_str_lc]=p_str

my_filters = [
    {"id": lzma.FILTER_LZMA1, "preset": 2}
]

with lzma.open("pathdata.xz", "w",format=lzma.FORMAT_ALONE, filters=my_filters) as f:
    f.write(bytes(json.dumps(file_map, separators=(',', ':')), "utf-8"))
As for your issue, hit F12 switch to the sources tab, open up www/js/rpg_core.js and set break points at the first line of both catch statements for CS_URL.Initialize. Hit F5, do you stop at the breakpoints? If so hover over ex, what's the exception?

You'd want to normalise the path parameter. Make all the game files lowercase, and then (before the const key declaration)
JavaScript:
if (typeof path === 'string' && String(path).length) {path = String(path).toLowerCase()}
...assuming path is a string.
This unfortunately doesn't work because there are other places other files are loaded.
 
  • Like
Reactions: LongHentai2k

Flame_iscool

Member
Nov 6, 2020
102
31
87
hay can someone help me i found a starnge video while fishing and when i tried to watch it does not allow me to watch it can someone help
 

scyne

Newbie
Dec 4, 2018
20
7
21
This unfortunately doesn't work because there are other places other files are loaded.
If loadNormalBitmap is not the only function passing requests, that makes sense. The real sticking point is normalising the game files, regardless.

Since that's something that has to happen either way, it'd make more sense to parse the JSON files in a shell script, do a case insensitive match on them, and rename the file if it's not also a case-sensitive match.
 

kin-kun

Active Member
Modder
Jul 10, 2020
963
2,582
324
If loadNormalBitmap is not the only function passing requests, that makes sense. The real sticking point is normalising the game files, regardless.

Since that's something that has to happen either way, it'd make more sense to parse the JSON files in a shell script, do a case insensitive match on them, and rename the file if it's not also a case-sensitive match.
Yeah, I started down that path, but it turns out that the packaging tool cares about case sensitivity on Linux. And you can create a Web/Linux version that's incompatible with Windows by having clashing file names.

In the end I found it easier to keep the files as is (so they didn't need to be renamed all the time as versions changed and if the file name is constructed by code, deal with that as well) and instead target the loading APIs with something that normalized the name and mapped that back to the case sensitive name.
 
  • Like
Reactions: scyne
4.60 star(s) 179 Votes