What does the OptiFine installer actually do [closed]

As stated by the title, I am not exactly sure what the purpose of the optifine installer is. Looking through the code, the only thing it appears to do is extract the jar file then copy it to the Minecraft directory.

This question came from trying to help a friend install Optifine for 1.15.2 on a computer that completely refuses to run the installer.

What I am trying to do is mimic the OF installer so that my friend can get optifine. I have the libraries and the jar set up properly, but it appears that optifine requires different natives which I cannot provide due to platform differences as that is where it crashes.

Somebody please help!


Besides finding the Minecraft folder and unpacking the files, it also adds a launcher profile configured correctly for starting Minecraft with Optifine. See the installation instructions ("For Minecraft 1.6.2 and newer") at MC forum for manual installation procedures.