Coder Social home page Coder Social logo

ipa's People

Contributors

eusth avatar maz-net-au avatar quit avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ipa's Issues

Works Only on Older Games (Tested Version: 3.4.1)

I managed to use IPA in an old game named "Redrunner" (https://github.com/BayatGames/RedRunner). This was built on Unity 2017.X.

However, as for games and VR apps built using later versions of Unity, the tool does not seem to work. It got a bunch of errors at first, which I managed to solve using try/catch blocks for the line:

_Module.Write(_File.FullName);

in files patcher.cs and virtualizer.cs.

After this, the injection went through without any errors.
BUT, the console showing that is supposed to show up with the --verbose flag, simply wouldn't show up, no matter what I try. It works fine for Redrunner, btw.

Virtualisation does not work on method calls

Simple scenario:

  1. The game defines a type (U), which has been thoroughly virtualised by IPA as expected.
  2. I inherit the class (as C), override some method (M), and pass an instance of my class to a method within the game.
  3. Said method is calling the (now virtualised) method M. I expect my method (C.M) be called; but it is calling the original one (U.M).

The reason is that the IL for virtual method calls and normal calls is different. For normal method calls, no lookup is performed, and it will always go straight for the original implementation. This kinda nullifies the virtualisation of methods, because overriding them doesn't really do anything.

The behaviour is similar as if the class wasn't virtual, and I were to override the method using new. A possible "fix" would be to change the IL to adjust all method calls to virtual calls; however doing so likely incurs a performance impact, if it is even possible at all.

Error writing to Assembly-CSharp.dll

I am facing the following error, when writing to the Assembly-CSharp.dll module. Currently, the illusion plugin doesn't do anything, and is blank.

image

The error seems to happen at following line in Virtualizer.cs

image

G

G

when i drag .exe onto it this shows up

Updating files...
Architecture: x64
Successfully updated files!
ERROR: Oops! This should not have happened.

System.BadImageFormatException: Format of the executable (.exe) or library (.dll) is invalid.
at Mono.Cecil.PE.ImageReader.ReadImage()
at Mono.Cecil.PE.ImageReader.ReadImageFrom(Stream stream)
at Mono.Cecil.ModuleDefinition.ReadModule(Stream stream, ReaderParameters parameters)
at Mono.Cecil.ModuleDefinition.ReadModule(String fileName, ReaderParameters parameters)
at IPA.Patcher.VirtualizedModule.LoadModules()
at IPA.Program.Install(PatchContext context)

[Press any key to quit]

System.Reflection.ReflectionTypeLoadException: The classes in the module cannot be loaded.

[ERROR] Could not load x.dll! System.Reflection.ReflectionTypeLoadException: The classes in the module cannot be loaded.
  at (wrapper managed-to-native) System.Reflection.Assembly:GetTypes (bool)
  at System.Reflection.Assembly.GetTypes () [0x00000] in <filename unknown>:0
  at IllusionInjector.PluginManager.LoadPluginsFromFile (System.String file, System.String exeName) [0x00000] in <filename unknown>:0

Crashes when I drag any .EXE onto it

I have followed 2 image tutorials, and 1 YouTube tutorial, and despite doing every step those people are doing when I drag an .EXE onto IPA.exe it just opens and crashes. No error message is given at all?? If I run it from a console window it says this:

Unhandled Exception: System.IO.FileNotFoundException: Could not load file or ass
embly 'System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c56193
4e089' or one of its dependencies. The system cannot find the file specified.
File name: 'System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c
561934e089'
at IPA.Program.Main(String[] args)

Cannot mod game

Whenever i drag and drop a games executable onto IPA i get the following error:

Architecture: x64
Successfully updated files!
Patching UnityEngine.dll... ERROR: Oops! This should not have happened.

System.Exception: Could not find any entry type!
   at IPA.Patcher.PatchedModule.Patch()
   at IPA.Program.Install(PatchContext context)

[Press any key to quit]

Any solutions?

System.Exception: Could not find any entry type!

Updating files...
Architecture: x64
Copying C:\Games\Goblin Lord Wants me to Become a Virgin Wizard by Managing the Brothel!\Goblin Burrow Manager_Data\Managed\IllusionInjector.dll
Copying C:\Games\Goblin Lord Wants me to Become a Virgin Wizard by Managing the Brothel!\Goblin Burrow Manager_Data\Managed\IllusionPlugin.dll
Copying C:\Games\Goblin Lord Wants me to Become a Virgin Wizard by Managing the Brothel!\Goblin Burrow Manager_Data\Managed\IllusionPlugin.xml
Successfully updated files!
Patching UnityEngine.dll... ERROR: Oops! This should not have happened.

System.Exception: Could not find any entry type!
   в IPA.Patcher.PatchedModule.Patch()
   в IPA.Program.Install(PatchContext context)

[Press any key to quit]

Can I somehow solve this problem?

IllusionInjector.dll access denied?

Updating files...
Architecture: x64
Copying D:\BILDER\Uplay\Far Cryr 3\Far Cry 3 screenshots\Ny mapp\Ny mapp\Ny mapp\Ny mapp\ANIME\honey select\illusion\HoneySelect\HoneySelect_64_Data\Managed\IllusionInjector.dll
ERROR: Oops! This should not have happened.

System.UnauthorizedAccessException: Åtkomst till sökvägen D:\BILDER\Uplay\Far Cryr 3\Far Cry 3 screenshots\Ny mapp\Ny mapp\Ny mapp\Ny mapp\ANIME\honey select\illusion\HoneySelect\HoneySelect_64_Data\Managed\IllusionInjector.dll nekas.
vid System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
vid System.IO.File.InternalCopy(String sourceFileName, String destFileName, Boolean overwrite)
vid System.IO.FileInfo.CopyTo(String destFileName, Boolean overwrite)
vid IPA.Program.CopyAll(DirectoryInfo source, DirectoryInfo target, Boolean aggressive, BackupUnit backup, Func3 interceptor) vid IPA.Program.CopyAll(DirectoryInfo source, DirectoryInfo target, Boolean aggressive, BackupUnit backup, Func3 interceptor)
vid IPA.Program.Install(PatchContext context)

[Press any key to quit]

I have tried running as admin and it still won't work

Patched game doesn't run all plugins under wine.

Patched game doesn't run all plugins, in particular the ShortcutPlugin in Honey Select under wine.
The game itself works flawlessly.
I can't see any error messages in the terminal window where the application is started.
I tried the --verbose switch, but no terminal appears.
The strange thing is that the translation seems to work, which implicates some kind of functionality.
Could it be that I am using the 32 bit version?
In the past I have had issues with wine DLLs being loaded instead of those required by plugins, could that be the problem?

Error finding entry types with newer versions of UnityEngine.dll

Newer versions of UnityEngine.dll contain only references to external assemblies which gives you the error

System.Exception: Could not find any entry type!
    at IPA.Patcher.PatchedModule.Patch()
    at IPA.Program.Install(PatchContext context)

The entry points UnityEngine.Input and UnityEngine.Display have both been moved to

.assembly extern UnityEngine.CoreModule
{
  .ver 0:0:0:0
}

(excerpt from the UnityEngine.dll manifest courtesy of ildasm)

If FindEntryTypes() in IPA.Patcher returns no results for UnityEngine.dll, setting engineFile to UnityEngine.CoreModule.dll and trying to patch again works.

Wrong UnityEngine loaded in latest release

Seems like the latest release (v3.4.1) does not include commit ca30be3 as the the order in the compiled .dll is still "UnityEngine.dll", then "UnityEngine.CoreModule.dll" instead of the other way around.

Cannot patch UnityEngine.dll

It seems Unity moved to a different way of managing their .dll files in the newest versions.
This was thrown while attempting to install IPA on Beat Saber (oculus store version).

 Patching UnityEngine.dll... ERROR: Oops! This should not have happened.
 System.Exception: Could not find any entry type!
      at IPA.Patcher.PatchedModule.Patch()
      at IPA.Program.Install(PatchContext context)
 [Press any key to quit]

POSTED ON WRONG GITHUB PAGE Attempting to use with the latest release of My Summer Car on Steam brings up this message

POSTED ON WRONG GITHUB PAGE
"E:\SteamLibrary\steamapps\common\My Summer Car
Backing up 'E:\SteamLibrary\steamapps\common\My Summer Car\mysummercar_Data/globalgamemanagers'...

Unhandled Exception: System.IO.FileNotFoundException: Could not find file 'E:\SteamLibrary\steamapps\common\My Summer Car\mysummercar_Data/globalgamemanagers'.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.File.InternalCopy(String sourceFileName, String destFileName, Boolean overwrite, Boolean checkHost)
at System.IO.File.Copy(String sourceFileName, String destFileName)
at UnityVRPatcher.Program.CreateGameManagersBackup(String gameManagersPath)
at UnityVRPatcher.Program.Main(String[] args)
Press any key to close this console."

Off from searching the game files, globalgamemanagers does not appear to exist

Bug

ProgramTest.cs :
public void CopiesCorrectly(string from, string to, string nativeFolder, bool isFlat, string[] expected)
{
var outcome = Program.NativePluginInterceptor(new FileInfo(from), new FileInfo(to), new DirectoryInfo(nativeFolder), isFlat).Select(f => f.FullName).ToList();

        var expectedPaths = expected.Select(e => new FileInfo(e)).Select(f => f.FullName).ToList();
        Assert.Equal(expectedPaths, outcome);
    }

There is no last param "Architecture" to call NativePluginInterceptor function , it can't compile.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.