-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Input Functions Not Working with TES4JaPatch016_beta3 #198
Comments
At this point I have to ask, what do this new beta provide that the older version didn't? I will still try to fix, however if they replace the input function I'm not sure it will be possible unless extreme hackery. |
Sorry, I should have written it as you suggested. The changelog (in ReadMe.txt) for version 0.16 is as follows:
(The changelog for subsequent beta versions does not exist.) As you can see, there is no mention of any input-related changes, but the fact that it says "Modified to work as an OBSE plugin." suggests that this may be a major rewrite compared to v0.15c and earlier versions, which were distributed as patch files directly replacing Oblivion.exe itself.
Thank you for letting me know. It was helpful to know that it may be difficult to fix. |
This is a mess. First of all the address of the fix isn't 00003B91 but 10004791 (1000000 being the base). it's not using baseful addresses for it's hooks, the hooks themselves are a mess. |
The reason of the crash is bewcouse there is a null pointer access, after The call to this object is masked by an indirect call (vtable access) Also it seems to be partially incompatble with MenuQue, crashing intermittently inside obja (calls started from MenuQue modules) |
Obja hook inside the function just before xOBSE hook: Now the question is what do OBJA do with the input hook? Do you have any idea on what feature it's used for? I imagine that I can either stub the hooks, or save and replay the instruction later. I however don't know wethever the replacer is doing something important |
Ok the function in obja, basically reimplement the input handling for the mouse, in addition it do some processing If the key related to DX scancode 0x91 (DIK_AT) then set 0x21 (DIK_GRAVE), if 0x7D (DIK_YEN) put a variable to 0 and call a function, if 0x90 (DIK_CIRCUMFLEX) call another function and store it's result. maybe it's realted to these you wrote in the readme for the fix
Also for the way this hook is made it doesn't work if there is no mouse detected |
Thank you very much for going over all the details. I'm really glad!
I'm not entirely sure about my understanding, but I believe that 00003B91 refers to the address that needs to be edited when opening obja_12416.dll in the binary editor to fix the bug, and not the address for the obja_12416.dll hooks. I apologize if I'm mistaken.
In my case, MenuQue itself does not cause crashes, but when I add mods that use their own fonts (such as HUD Status Bars), it crashes. I have been able to work around it by modifying the mod to not use those fonts.
The mouse input process may be used on a Japanese input screen that can be opened with the key of DIK_CIRCUMFLEX. On this screen, you can click and drag to select characters with the mouse cursor. One thing I forgot to mention is that obja_12416.dll uses the "@/`" key, which is a unique key on the Japanese keyboard ("[/{" key on the English keyboard), to open the console. In TES4JaPatch, 0x91 (DIK_AT, JP = "@/`" : EN = "[/{") is the console open key, 0x90 (DIK_CIRCUMFLEX, JP = "^/~" : EN = "=/+") is the configuration screen open key, and 0x7D (DIK_YEN, JP = "/|" : EN = None) is used as the Japanese input screen open key. The set to 0x21 (DIK_GRAVE, JP = E/J : EN = "`/~") is probably a measure to open the console with a Japanese keyboard. On Japanese keyboards, the "`/~" key is replaced by a special key called the E/J key (a language input key, also called halfwidth/fullwidth or 半角/全角 key), so the "`/~" key is not available. Without TES4JaPatch on a Japanese keyboard, the console cannot be opened in-game. I think that the only keys used in TES4JaPatch are the three that you mentioned. If necessary, it would not be a major inconvenience to disable these overrides that TES4JaPatch016_beta3 does. |
…override in the input function. Try to solve #198
@kuroko137 Can you try with this artifact: https://github.com/llde/xOBSE/actions/runs/4237735184 Test for the functionality added by OBJA and check if it works |
I just tried your fix and the problem is solved! All inputs are now detected not only in the test ESP I provided, but in other mods. Now, I want others to try this, so I have asked users to try it on the Japanese forum where the fix method (00003B91: 75 to EB) was found. If they find any problems, I will report them here. There aren't as many people playing Oblivion in Japan as there used to be, so the number of people who will benefit from this fix may be small, but at least for me, your fix has been a lifesaver. |
Glad it's working |
Since xOBSE22.2, there is an issue that some input functions of xOBSE cannot be used when TES4JaPatch016_beta3 (the Unofficial Japanese patch v016.beta3 for Oblivion.exe) is installed.
The following functions are affected:
It appears that the function InputPollFakeHandle() in Hooks_Input.cpp is no longer called when TES4JaPatch016_beta3 is installed, possibly due to a conflict between the patch and xOBSE. Removing the patch and reverting to the English version allows InputPollFakeHandle() to be called normally, enabling all the above functions to work correctly.
You can download TES4JaPatch016_beta3 from here.
However, the original TES4JaPatch016_beta3 does not work due to a bug on Windows 10 or later. If you want to investigate the issue, please use the following link where I have applied the recently discovered fix.
https://1drv.ms/u/s!Ap8qkjiHTZQ0k1RyPYcgc7tTV0Jl?e=K9c3Gj
(I am temporarily storing it and will remove it later.)
I have created an ESP plugin to check for this problem, which logs to the console when certain controls are performed. By default, it logs when the "B" key is pressed or a "grab" control is performed.
Confirmed environment:
Note that the issue does not occur with Japanese patches prior to v016.beta3 (like v0.15c) and xOBSE 22.2 or later. It also does not occur with v016.beta3 and xOBSE 22.1 or earlier.
TES4JaPatch016_beta3 is an essential tool for playing Oblivion in Japanese on the Steam platform, but it had a compatibility issue with Windows 10 and later, causing it to malfunction for about six years due to a bug. TES4JaPatch016_beta3 was released quite a long time ago, and it was thought to be impossible to fix because the source code did not exist. However, just a few months ago, someone discovered a way to fix it, so it is now possible to make it work again.
The text was updated successfully, but these errors were encountered: