Welcome to the official page for Partial Modification Loader, for Minecraft use!
Clients and Servers: If you don't have a mod that specifically asks for this, you will not benefit from using it.
Notice: PML uses OS-specific native code, which is written and compiled by Oracle as a part of the Java Development Kit. PML is open-source (not including the native codes' sources, which, again, should be from Oracle), and can be modified and distributed openly under its license. Furthermore, PML performs in-memory changes to base Java code by utilizing process code injection. If you do not trust a download source, then do not use it! I value system integrity and malware-free content, though the same cannot be said for all file mirrors (some are good, but others will add stuff just for the sake of being malicious). PML requires either Java 7 or 8, and cannot be used with Java 6 or lower. This is a technology requirement, not a code decision.
This does not currently support use with MultiMC. Support is being developed.
Developers: I've coded an installer for users, but need a simple Java GUI to go with it. I would appreciate it if someone would help me out with this part - it should only take about half an hour to code - I just have no patience for writing GUIs.
Note for forum Administrators/Moderators:
While PML is a mod platform/API, it is not a mod in and of itself - it is a tool/library system that alters Minecraft when Minecraft loads, without normally being for Minecraft specifically. The distinction that makes PML not belong in the Minecraft mod sub-forum is a technical one - this will technically be in the wrong place if you move it to the more "logical" mod sub-forum. While it may not seem quite "correct," PML does actually belong in this sub-forum (the tool sub-forum)!
Mods Installation Note: Mods that require PML may be distributed as '.pmlm' files (Partial Modification Loader Mod files) or '.jar' files. PML mods can be placed in the "mods" folder [if they have this extension for PML 10.0 or below] or [for PML 10.1], or can be placed in the "PMLMods" folder in any zip-based form (pmlm, zip, jar, etc.) or as extracted/loose files. PML itself is installed differently than you are used to, as documented both in the download and in the spoilers for stuff for users/developers.
Bug reporting note: Bugs involving invalid bytecode should be reported here. If it is clear what mod caused any other kind of crash, go to that mod's page. If it is not clear, you should ask here. The most useful report is the potentially massive log file(s) in the PML folder - PML's logging starts earlier than any other non-launcher logger.
About PML
What is Partial Modification Loader?
PML is a loader of "Partial Modifications," which are generally called Aspects in other AOP technologies. Compared to other Java AOP libraries, PML is more simplified and is designed to be easier to learn and use from scratch - though it's still intended for more experienced mod-makers/programmers.
PML targets Java in general, not Minecraft specifically. All of the Minecraft-related code is kept and licensed separately, but is licensed the same kind (The MIT License). PML can be used with other Java programs, given some minimal coding effort. This page is the official page of PML for Minecraft use.
PML is solely a facilitator/enabler of some higher-level modding techniques. It couples with Java, rather than Minecraft.
What is a "Partial Modification"/"Aspect?"
A "Partial Modification," also referred to as an "Aspect" among the more advanced/modern Computer Programmers, is really just a simplified explanation for what "Aspect Oriented Programming" is about. Nevertheless, it can still be confusing. To understand what they are a bit better, it may help to understand how they generally function, and how they are provided.
When trying to picture how PML provides modding hooks, it's best to think of it like the Minecraft API "Player API." Player API provides mod makers the ability to modify the execution code involving players on a per-method basis. Similarly, PML provides mod makers the ability to modify execution code in much the same way. Unlike Player API, however, PML isn't nearly as limited to what sections of code can be hooked in to - instead of only offering code for the player or some other highly specific thing, PML lets mod makers hook in to almost any execution code. Furthermore, a mod is provided significantly more access when using a PML hook compared to a Player API hook. The one thing Player API does significantly better is hooks in initialization code.
Does PML replace other APIs, such as Forge?
PML isn't a comprehensive API, since it's based on usage simplicity and isn't coded specifically for Minecraft - other, non-dynamically-generated APIs (like Forge, Bukkit, and the official API [if/when it ever comes out!]) can, and often do, offer things that PML does not, on its own. That being said, PML offers significantly more hooks than those kinds of APIs due to its nature, allowing mod makers to use hooks that could take a very long time to be added to one of those others APIs, assuming they would ever get added at all. To make things even better for mod developers, PML can be used in conjunction with other APIs - modders get to have the best of both worlds, so to speak.
Where does PML draw its inspiration?
Despite being a simplified AOP(Aspect Oriented Programming) system, PML draws most of its inspiration from OOP(Object Oriented Programming) scripting languages, such as Python. In fact, the original plan for PML was that its add-ons would be written in Java-Python (also known as "Jython"). This would have hindered initial add-on development, however, so a pure-Java language interface was used instead.
Why might a Minecraft mod use PML?
Reason 1: Forge
Forge encourages mod makers to replace blocks, items, etc. by making a new version (new class file, and new instance) of whatever it is and replacing the old one with it when loading. While this stops the game from crashing from code incompatibilities when two mods edit the same thing, a logic incompatibility easily comes up, which can frustrate users to no end. PML lets mod makers edit things without directly causing incompatibilities, both in logic and code.
Because PML edits classes by wrapping around existing [method/execution] code, a PML mod can easily sport near-perfect compatibility with other mods, regardless of source - even more so than with Forge alone.
Additionally, I found that requesting a change in Forge can take an absurdly long time for approval, even if it's an incredibly minor of a change, would not impact anybody, and is properly requested. With PML, almost every method can be hooked, without needing to wait for approval. With PML, each developer gets the power to do what needs doing, without the insanity of others putting themselves in the way.
Reason 2: Other Mods
Since PML's injected hooks are determined dynamically, PML mods can add their changes into another mods' code. This is especially useful for adding changes to items, blocks, biomes, or entities, and having those changes be applied to things added by other mods as well. This means that PML's hooks can behave like certain kinds of Bukkit hooks, except Bukkit's hooks are not as plentiful and do not work very well with mods.
PML can even hook directly into mod-added code exclusively, which lets mod makers force-add basic compatibility patches when other developers refuse to add/adopt them willingly - even a modder that isn't listened to can do what he needs, given time, patience, and practice.
Reason 3: Minecraft/Obfuscations
PML can be (and has been, in the Minecraft edition) made to partially unify all the obfuscation environments together, meaning some PML mods can be made to function under any obfuscation environment (vanilla, Forge, development, snapshots, etc.), without alternate versions or special checks and conditions. These kinds of mods are "PML Universal mods" - FML Universal mods use one version that supports both Clients and Servers, while PML Universal mods use one version that supports both Clients and Servers with any [relatable] obfuscation! These mods [PML Universal mods] are a little harder to code than regular PML mods, though, so might tend to be smaller so they're easier to maintain. In some cases, PML Universal mods can even be made to support snapshots and unreleased versions relatively easily.
Because PML doesn't have hooks in the code for development purposes, PML usually won't need to have a code update when Minecraft updates - and the update wouldn't be in PML itself, if it did need updating at all. PML would still need to have obfuscation map updates, but those are handled separately from the code, and shouldn't require users, nor modders, to download any updates.
By coupling PML's lack of a need for regular code updates [for Minecraft] with its unifying the obfuscation environments, it's possible to make a base-editing mod that works between two very different versions of Minecraft, using the same version of PML, and without using Forge!
Reason 4: Hooks
PML offers an insane number of available hooks for a standard Minecraft install, and only increases the number of available hooks as more modding APIs and mods are added - the exact opposite of typical APIs. While PML does have its limitations, the sheer quantity of hooks was more than enough to gain interest from all other modders that heard about it during its beta testing. For a standard Minecraft 1.8 install, PML offers more than seventeen THOUSAND hooks into Minecraft code - PML provides more than twice the number of hooks in vanilla alone than it has lines of source code. With Forge and other mods added, that number skyrockets even further.
TL;DR
Because PML is awesome, with a side of awesome, covered in awesomesauce.
Q & A
When will this update to [insert Minecraft version number here]?
Usually, PML's code is already compatible with a new version of Minecraft. PML mods may be waiting for updates from the Minecraft Coders Pack team for updated obfuscation maps so they can function, but that's not PML's fault. Generally with PML, though: one-edition-fits-all.
More accurately, PML itself doesn't care about Minecraft in any way. PML mods may need for PML to support a specific obfuscation, though, and the needed obfuscation maps are provided by PML mods (including the ones in the MC adaptation code) which need the obfuscations already figured out - those obfuscations being where the Minecraft Coders Pack team comes in to figure it out.
Can I include this in a modpack?
Yes. Just be sure everything else you want in your modpack permits modpacks, too. PML uses the MIT license, but that doesn't mean that mods requiring PML do, as well.
Stuff for PML Mod Users
PML isn't Minecraft-specific, but has an application-specific adaptation jar file. To make installation easier, I've included this file in the download, even though it's not technically a part of PML itself.
PML for Minecraft (runtime) can be downloaded at the bottom of this page. Please be aware of if the mod(s) you need PML for require any additional components, such as for obfuscations.
Installation steps are now located in the download zip. Installation does NOT involve placing the download zip into the mods folder.
Stuff for PML Mod Makers
Note: There's currently a bug that stops Eclipse's Debug runs from working with PML (some times? all the time?). I do not know if it only influences Eclipse. It does not stop Eclipse's regular runs from working, though. I am trying to find a solution.
Note2: This currently doesn't support usage in IDEA environments. You can develop in IDEA, just not run/test.
Installing for Mod Development Installation steps are now located in the developer's download zip.
Developing a Mod:
The following text is a shortened quick-start guide. If you need more than is in this section, then gladly I'll teach you directly. I expect most will need a little more than is here, but I'm only putting this little bit here to cut down on this post's content - less text to maintain.
PML 10.0 and above
PML 10.0 overhauls the PML API to be more modular and clearer to work with. Mods developed for pre-10.0 will not work with 10.0+, and visa-versa.
1. Make a text file named "pml.info" in the resources folder. Put the fully-qualified names of the PML mod classes you want to load from PML's bootstrap loader, each on a separate line.
2. There are three types of PML mod classes that you have access to - Obfuscation mods (PMLObfuscationMod), Editing mods (PMLEditMod), and Loading mods (PMLModFactory). Each type has access to slightly different portions of the PML API, and are viewed as portions of a larger mod -- modders are able to use multiple mod classes in tandem to accomplish their goals. Extend one of these abstract classes and either add your subclass' fully qualified name in your "pml.info" or load it from a PMLModFactory that is either directly or indirectly loaded from "pml.info" (a PMLModFactory can load additional PMLModFactory subclasses).
3. In your mod class(es), provide the abstract methods and override whatever you need from parent classes. Your mod's access to the PML APIs is obtained from your mod's "getModLoadAPI" method, provided for you. If you need to access part of PML's API from outside of your mod's class file, please pass the API via parameters, rather than make an access method in your mod class file.
4. Every component of PML's API is numbered and versioned. When using any part of an API, please check that that component is available (via the static methods found in DetailedAPI) in your mod class' init method. If not everything is available, either check backup components you may use, or throw something -- this will signal that your mod should not continue to be loaded.
5. Obfuscation and Edit mods are named (the name is set via the constructor). If more than one named, un-errored mod with the same name is present at the NamedMod postinit phase, the game will not load. An empty name String is an invalid name, as is a null String. Named mods have access to the section of PML's API dealing with inter-mod workings (checking if a mod is present, checking if a mod is active or disabled, mod communications, etc.) -- this API is not available until the postinit phase, however.
6. In your Edit mod class(es, if any,) override the applicationRecommendedLoadTime method, and register any edits you wish to apply to the code. Edits can be in any code, including mod-added or even the application's [normal] starting main method.
7.Bug Alert: For now, if you want to use an object in place of one of its subclasses (such as type Foo, where Foo extends/implements Bar), manually cast to Object then to the subclass. This is to avoid the Java Virtual Machine "helpfully" destroying PML's opportunity for hook registration (by loading the class files too early). This only applies to types not from the Java Core libraries (so not including things like ArrayList, HashMap, etc.)
PML 9.3 and below
Starting in PML 9.2, you can put the qualified name of an IPMLMod class that has a public no-arg constructor into the pml.info file - essentially making the IPMLModFactory optional (if you take advantage of this, make sure to check the program name in your IPMLMod(s)).
1. The first thing to start with is to make a class that extends IPMLModFactory. Despite the poorly chosen name, it is an abstract class rather than an interface. It was an interface until shortly before PML's first release - the name stuck for compatibility.
2. In the preinit method of the class from step 1, use the IPMLFactoryLoadAPI parameter to check if the factory API you are compiling against is the one that is being used, by calling the isDirectlyCompatible method in it, passing IPMLFactoryLoadAPI.currentAPIVersionNumber. If this returns false, throw something (ie. a new RuntimeException). This signals to PML that your mod should not be loaded any further.
3. In the same method as step 2, check if the program is "Minecraft" - [the method's parameter].getProgramInformation().programName().equals("Minecraft"). If this is false, throw something, like before - it would be bad if your Minecraft mod gets loaded for some other program and gets to cause actual problems!
4. Make a text file named "pml.info" in the resources folder. In this file, put the qualified name of the class you made in step 1, followed by a new line (a line feed character). If you decide to make more PML mod factories, list them on their own line in this file - all that are listed will get loaded.
5. Make a new class that extends IPMLMod - yes, it has the same history as IPMLModFactory. Return a new instance of this class, inside of an IPMLMod[], in your factory's loadMod method.
6. The other two methods in IPMLModFactory that you need to implement are for more advanced applications - just return null if you don't want to (or don't know how to) use them.
7. In one of the two init methods in your Mod, use the IPMLModLoadAPI to check if the Mod API is compatible, just like you did in the factory, this time passing IPMLModLoadAPI.currentAPIVersionNumber. This lets PML update in a more modular manner.
8. In your Mod class, override the applicationRecommendedLoadTime method and use it to register your hook requests (via the IHookRegistrar, obtained from the IPMLModLoadAPI) with the correct ClassLoader (the one given). This involves using reflection, or the makeObject method from IPMLMod which simplifies it for you. I suggest making a new class to register your hooks from, which helps cut down on the amount of reflection and open-ended, easily-invalid variable-argument method invocations. (Other AOP libraries/systems use the term "weaves"
9. Within your hooks' passed hook helper, param 0 is the current "this" object if the hooked method is non-static. All other parameters start at parameter 1. You can throw any exception within hooks/weaves. However, it is currently very important to not let Java "helpfully" auto-downcast for you -- for example, if you have a player entity and need to use it as an entity, cast it to an Object then to an entity (not doing this will cause Java to "helpfully" load classes long before they should be).
10. When you are ready to distribute, compile like normal; simply rename the resulting .jar to have the ".pmlm" file-type extension before distributing- this stops Forge from falsely believing it knows how to correctly load your mod right off. After PML loads the file, Forge can then load any @Mod classes in your code like you are used to, via the classpath.
Pictures of PML in action (from various Minecraft mods that use it)
Developers: If you'd like for something you've made to be added to this section, please Private Message me a picture of it in action, a URL link for it, and a brief description of how it uses PML.
The Seasons Mod utilizes PML to make all of its changes take effect - seasonal colors, seasonal temperatures, enhanced snow/ice logic, crop edits, and more.
Terms/Conditions/License/Copyright
PML and the Minecraft adaptation for PML are separate bodies of code. Both are licensed under The MIT License. PML then uses my utility code, WPUtil, which is also licensed under The MIT License, but contains code that is under separate licenses.
PML
The MIT License (MIT)
Copyright (c) 2015-2016 The_WeatherPony
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
[MC]PML (the MC adaptation code for PML)
[MC]PML's License
The MIT License (MIT)
Copyright (c) 2015-2016 The_WeatherPony
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
jopt-simple
The jopt-simple code included in the Minecraft application adaptation
code for PML is from jopt-simple build 4.9.
jopt-simple is included under its original license and copyright, and I
make no claim of ownership to any of that library's code. I have renamed
the packages and refactored imports accordingly so that an additional yet
different copy of the library may be used at the same time. The package
naming used for this copy of jopt-simple is the same as it usually is, but
with the prefixed package "weatherpony.pml_minecraft."
The included jopt-simple code's copyright/license is below.
The MIT License
Copyright (c) 2004-2015 Paul R. Holser, Jr.
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
WPUtil
WPUtil's License
The MIT License (MIT)
Copyright (c) 2015-2016 The_WeatherPony
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
ASM
ASM is included under its original license and copyright, and I make no
claim of ownership to any of that library's code. I have renamed the
packages and refactored imports accordingly so that an additional yet
different copy of their library may be used at the same time. The package
naming used for this copy of ASM is the same as it usually is, but with
the prefixed package "weatherpony.util."
The included ASM code's copyright/license is below.
ASM: a very small and fast Java bytecode manipulation framework
Copyright (c) 2000-2011 INRIA, France Telecom
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
3. Neither the name of the copyright holders nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
THE POSSIBILITY OF SUCH DAMAGE.
Gson/Json
Gson is included under its original license and copyright, and I make no
claim of ownership to any of that library's code. I have renamed the
packages and refactored imports accordingly so that an additional yet
different copy of their library may be used at the same time. The package
naming used for this copy of Gson is the same as it usually is, but with
the prefixed package "weatherpony.util."
To conform with the Apache 2.0 license that Gson uses, the following line
has been added to the included Gson library's source code files such that
there are no line number changes:
This file has been modified from its original form in the following way: package renamings and/or import reordering
Any additional changes are documented in the appropriate files.
The included Gson code's copyright/license is below.
Copyright (C) 2009 Google Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
When you download, use, share, and/or upload PML in source and/or compiled form, you are agreeing to be bound by these licenses. (The most limiting one is The MIT License - it's very permissive.)
Downloads
NOTE: Manual Installation does NOT include putting the download into the mods folder. Installation is easy, but PML is not a mod - don't put it in the mods folder! Instead, read the installation instructions inside the downloaded zip file. Now that that's over with...
The current version uses/is PML v10.3. The download was last updated on: 4th of July, 2017, for reason: fixed copy of included WPUtil to latest
Download (Users) : [with ads, manual install] [Link Removed]
Download (Developers; compiled and source) : [with ads] [Link Removed]
Previous Versions (kept for archival purposes; only the last version before an incompatible API change was made is kept here.):
pre- PML 10.0 (These require external obfuscation mods -- they are not included!)
PML 9.3: Compatible FactoryAPIs = {4}; Compatible ModAPIs = {6}. The download was last updated on: 8th of May, 2016, for reason: fixed bug that stopped use on Mac Operating Systems
*Users: Please remember to download any obfuscation map providers required by the mods you need this for. I have a couple such providers available on the page for my minor Minecraft Mods, ad-free.
**no-ad downloads and with-ad downloads download from the same URLs. If one is not functioning, neither is the other.
***If something happens to a download link to make it no longer work, I will try to get it back up quickly.
You can put them in the mods folder if they have the '.pmlm' extension like intended, or they can be put in the PMLMods folder as a .pmlm, .zip,.jar, extracted files, etc. I'll add that to the info.
I haven't used LiteLoader in ages, but it should be fine. If not, please let me know what the issue is. Installation order for the three together would be Forge, LiteLoader, then PML. PML should always be installed last, though it always gets loaded first.
Rollback Post to RevisionRollBack
If I said I'd do something and haven't, please remind me; I didn't lie, I just forgot.
I program
While it's possible to rewrite my mods so that they don't need PML (by making it so they handle what PML does for them on their own in a more Minecraft-y way), it would not be advantageous from a code perspective.
My mods tend to deal very heavily with bytecode manipulation and reflection (for example, The Seasons Mod modifies more than 100 different methods in just vanilla+Forge alone, and modifies an additional untold number of things from other mods [plus it uses reflection to access plenty of private/protected methods/fields, on top of that]). PML automates the obfuscation handling, the underlying bytecode editing, and (to a lesser extent) the reflection involved. What would normally take several thousands of lines of ASM bytecode editing and lots of time-consuming obfuscation handling by hand, PML reduces to a couple hundred lines of simple copy-paste-able framework that accepts standard development obfuscation names.
I'll promise this: If I make a mod that doesn't actually use PML, then I won't make that mod require/use it.
Rollback Post to RevisionRollBack
If I said I'd do something and haven't, please remind me; I didn't lie, I just forgot.
I program
Ahh. Sorry that I didn't pick up on your asking-[while/because]-waiting
Thank you for liking it - I focused super-heavily on ease-of-use for it; modders have enough to deal with already, without needing to learn another language (like for many other AOP libraries) or something super-complicated. Ease > Fine Control ^^
Since you said you were interested in PML for the Improved First Person mod, I'd like to let you know that PML might not have everything you're after: since PML doesn't deal with any section of code specifically, there could easily be parts that are handled better in RenderPlayer API (such as constructors). You'd need to weigh whether automated method hook creation and obfuscation handling (plus no need for regular updates) stands up better or worse compared to easier-to-install and the other little details in RenderPlayer API.
Rollback Post to RevisionRollBack
If I said I'd do something and haven't, please remind me; I didn't lie, I just forgot.
I program
It's just a mod to make you and mobs don't walk in the leaves like in the real life. When an entity go in they, it fall of them. The entities (including players) can go into they. The players can still cut them, and place them where they wan't (they can also burned and extinguished with water like in normal game). This mod just make them "ghostly" like the flowers or or short/tall grass.
To make this mod compatible with your Season mod, it's really easy, just use an ressource pack for the season mod, I could also make it.
I'm not sure why you think you'd need PML for that, since I've seen at least two mods that do it purely with Forge.
One being TerraFirmaCraft (Mod's Official Site), and another that I can't remember.
Less simple than the precedent I'm explaining you, I don't know how to make that :
1. Kill a mob=
2.The mob falls on the side, like in the game but does not disappear(the mobs don't drop items)
3.Use your knife/sword on him.
4.The mob disappear and drop it's items.
That's pretty much already been covered in RPGLoot (Curseforge Link). It shouldn't be too difficult to make an addon for it, or at least branch off that mod to make them do what you want.
This mod could add two things :
Fix the survival creative inventory black screen behind it (make it white transparent)
Fix the case rendering bugs when it when it's smaller has normal (used like buttons to go battlegear 2 mod inventory, that's an ugly bug)
Not sure what you mean here, but it could probably be done with forge as well.
DarianStephens - While vrackfall's first idea could be done through just Forge, PML would make it easier to code and expand the logic more rapidly. (Writing Forge coremods isn't all that pleasurable, and there's not very much documentation/explanation to help. Writing bytecode editing code isn't all that great either, and ends up taking longer to port, due to needing to handle obfuscations. On the other hand, PML is newer but more documented and easier to learn; it also handles the bytecode editing and obfuscations so that vrackfall wouldn't need to.) While it could be done with just Forge, it doesn't mean it would be easier with just Forge. I think vrackfall should go with what he feels is the better trade-off [even if that's not PML]).
Edit: by the way, PML, itself, used to be a Forge coremod, but was converted to be a java agent for compatibility with mods such as CodeChickenCore.
If it does, then could you please help me with this error? I think it's because MultiMC keeps the Minecraft jar in a different place or something, making PML unable to find it.
MultiMC version: 0.4.10-733
Minecraft folder is:
instances/Pimmel/minecraft
Java path is:
C:/Program Files/Java/jre1.8.0_66/bin/javaw.exe
Java Arguments:
[-javaagent:PMLCore/PMLPremain.jar=-MCSide:Client, -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump, -Xms512m, -Xmx1024m, -Duser.language=en, -jar, E:/Mods/Minecraft/Utilities/MultiMC/jars/NewLaunch.jar]
Minecraft process ID: 4296
PML: about to start logging the out stream...
PML: started logging out stream
PML: about to start logging the err stream...
PML: started logging err stream
natives/64/windows/attach.dll
PML Agent loaded!
"sun.java.command" found to be a jar
PML: normal main class found - org.multimc.EntryPoint
saving generated replacement class bytes for sun/misc/Launcher$ExtClassLoaderloaded from null
saving generated replacement class bytes for sun/misc/Launcher$AppClassLoaderloaded from null
saving generated replacement class bytes for java/net/URLClassLoaderloaded from null
saving generated replacement class bytes for sun/reflect/DelegatingClassLoaderloaded from null
altered bytecode of java/lang/Thread for modified setContextClassLoader method
saving generated replacement class bytes for java/lang/Thread
saving generated replacement class bytes for java/security/SecureClassLoaderloaded from null
about to alter java/lang/ClassLoader
PML-ClassLoaderTransformer: successfully altered ClassLoader's defineClass
saving generated replacement class bytes for java/lang/ClassLoaderloaded from null
saving generated replacement class bytes for weatherpony/util/classloading/ParentLastClassLoaderloaded from sun.misc.Launcher$AppClassLoader@14dad5dc
PML: normal main class loading
PML: main class finished transformation
PML: replacementMainThread being created
PML: replacementMainThread created
PML: replacementMainThread replacing ClassLoader
PML: replacementMainThread replaced ClassLoader
Exception in thread "Thread-0" java.lang.RuntimeException: java.lang.NoClassDefFoundError: joptsimple/OptionSpec
at weatherpony.pml.launch.PMLInitialization.preloadSequence(PMLInitialization.java:122)
at weatherpony.pml.launch.PMLRoot.preload(PMLRoot.java:73)
at weatherpony.pml.premain.ReplacementMainThread.run(ReplacementMainThread.java:84)
Caused by: java.lang.NoClassDefFoundError: joptsimple/OptionSpec
at weatherpony.pml_minecraft.detail.DetailedMinecraftPML.<init>(DetailedMinecraftPML.java:33)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at java.lang.Class.newInstance(Unknown Source)
at weatherpony.pml.launch.PMLInitialization.preloadSequence(PMLInitialization.java:120)
... 2 more
Caused by: java.lang.ClassNotFoundException: joptsimple.OptionSpec
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at weatherpony.util.classloading.ParentLastClassLoader.loadClass(ParentLastClassLoader.java:44)
at java.lang.ClassLoader.loadClass(Unknown Source)
at weatherpony.util.classloading.ParentLastClassLoader.loadClass(ParentLastClassLoader.java:44)
at java.lang.ClassLoader.loadClass(Unknown Source)
... 9 more
Process exited with code 0.
If it helps, I put the folders 'PML' and 'PMLCore' (With their contents intact) into this Minecraft instance's 'minecraft' folder.
The Meaning of Life, the Universe, and Everything.
Join Date:
1/20/2016
Posts:
53
Member Details
How would one install this/seasons into a MultiMC instance? It just crashes on startup.
I've set up a 1.7.10 instance with forge, and done the equivalent 2 steps for a normal client
extract the PML download zip folder directly into the minecraft directory you are using (usually the .minecraft folder) - copied to %instance%/minecraft
open the Minecraft launcher, and click the "edit profile" button for the profile you want to add PML to. In the "JVM Arguments" section, add the following line, then save the profile - added line to java args in instance settings
I put both the seasons mod and the PML MCP-Dev thing in the mods folder.
Would I be better trying to follow/adapt the technic instructions, or is there another solution?
Rollback Post to RevisionRollBack
Thaumeme Supreme and madman behind Thaumic Dyes (TC4 Addon), and other magical disasters.
DarianStephens and KryptonCaptain - MultiMC isn't supported yet, since they are launching the game differently than other launchers. I'll learn some of what MultiMC is doing (specifically how it's doing it) and figure out the best course of action.
Rollback Post to RevisionRollBack
If I said I'd do something and haven't, please remind me; I didn't lie, I just forgot.
I program
I tried doing both ways but none of them work. The way multimc does forge is a bit different. It's OK though, I setup a vanilla launcher thingie for the pack where I have seasons
LunariusH - looked through FTB, and I found a way to install this through their current setup for the client. Unfortunately, it isn't very user-friendly. I'll start on the server, next...
install any client dependencies you need (such as Forge) or start with an existing modpack
extract the PML download zip folder directly into the minecraft directory you are using (the modpack's/minecraft folder)
open the FTB launcher, and click the "Options" button at the top of the main window. Near the bottom of the new screen is a button labeled "Advanced Options" - click it. In the "Additional Java Parameters" box, add the following line. Go back and remove this whenever you want to switch to a pack without PML.
-javaagent:PMLCore/PMLPremain.jar=-MCSide:Client
You can then put pmlm files in either the regular mods folder like you are used to or the new PMLMods folder - it makes no difference.
Edit: FTB servers look to be just normal Forge servers... so just a stock server installation would work.
Made a tiny bugfix update to the Minecraft App component, to fix support for Minecraft Pre-Release snapshots. It's so tiny and specific of a fix that it's not worth updating unless you want to use PML with Minecraft Pre-Release snapshots (such as the brand new MC "1.9-pre1" version).
...as far as I'm aware, this is only relevant for my Mega Slimes mod, which already has 1.9-pre1 obfuscations available to it. I hope more mods will rely on this in due time...
Rollback Post to RevisionRollBack
If I said I'd do something and haven't, please remind me; I didn't lie, I just forgot.
I program
Clients and Servers: If you don't have a mod that specifically asks for this, you will not benefit from using it.
Notice: PML uses OS-specific native code, which is written and compiled by Oracle as a part of the Java Development Kit. PML is open-source (not including the native codes' sources, which, again, should be from Oracle), and can be modified and distributed openly under its license. Furthermore, PML performs in-memory changes to base Java code by utilizing process code injection. If you do not trust a download source, then do not use it! I value system integrity and malware-free content, though the same cannot be said for all file mirrors (some are good, but others will add stuff just for the sake of being malicious).
PML requires either Java 7 or 8, and cannot be used with Java 6 or lower. This is a technology requirement, not a code decision.
This does not currently support use with MultiMC. Support is being developed.
Developers: I've coded an installer for users, but need a simple Java GUI to go with it. I would appreciate it if someone would help me out with this part - it should only take about half an hour to code - I just have no patience for writing GUIs.
Note for forum Administrators/Moderators:
Bug reporting note: Bugs involving invalid bytecode should be reported here. If it is clear what mod caused any other kind of crash, go to that mod's page. If it is not clear, you should ask here. The most useful report is the potentially massive log file(s) in the PML folder - PML's logging starts earlier than any other non-launcher logger.
About PML
PML targets Java in general, not Minecraft specifically. All of the Minecraft-related code is kept and licensed separately, but is licensed the same kind (The MIT License). PML can be used with other Java programs, given some minimal coding effort. This page is the official page of PML for Minecraft use.
PML is solely a facilitator/enabler of some higher-level modding techniques. It couples with Java, rather than Minecraft.
What is a "Partial Modification"/"Aspect?"
When trying to picture how PML provides modding hooks, it's best to think of it like the Minecraft API "Player API." Player API provides mod makers the ability to modify the execution code involving players on a per-method basis. Similarly, PML provides mod makers the ability to modify execution code in much the same way. Unlike Player API, however, PML isn't nearly as limited to what sections of code can be hooked in to - instead of only offering code for the player or some other highly specific thing, PML lets mod makers hook in to almost any execution code. Furthermore, a mod is provided significantly more access when using a PML hook compared to a Player API hook. The one thing Player API does significantly better is hooks in initialization code.
Does PML replace other APIs, such as Forge?
Where does PML draw its inspiration?
Why might a Minecraft mod use PML?
Because PML edits classes by wrapping around existing [method/execution] code, a PML mod can easily sport near-perfect compatibility with other mods, regardless of source - even more so than with Forge alone.
Additionally, I found that requesting a change in Forge can take an absurdly long time for approval, even if it's an incredibly minor of a change, would not impact anybody, and is properly requested. With PML, almost every method can be hooked, without needing to wait for approval. With PML, each developer gets the power to do what needs doing, without the insanity of others putting themselves in the way.
PML can even hook directly into mod-added code exclusively, which lets mod makers force-add basic compatibility patches when other developers refuse to add/adopt them willingly - even a modder that isn't listened to can do what he needs, given time, patience, and practice.
Because PML doesn't have hooks in the code for development purposes, PML usually won't need to have a code update when Minecraft updates - and the update wouldn't be in PML itself, if it did need updating at all. PML would still need to have obfuscation map updates, but those are handled separately from the code, and shouldn't require users, nor modders, to download any updates.
By coupling PML's lack of a need for regular code updates [for Minecraft] with its unifying the obfuscation environments, it's possible to make a base-editing mod that works between two very different versions of Minecraft, using the same version of PML, and without using Forge!
TL;DR
Q & A
More accurately, PML itself doesn't care about Minecraft in any way. PML mods may need for PML to support a specific obfuscation, though, and the needed obfuscation maps are provided by PML mods (including the ones in the MC adaptation code) which need the obfuscations already figured out - those obfuscations being where the Minecraft Coders Pack team comes in to figure it out.
Can I include this in a modpack?
Stuff for PML Mod Users
PML for Minecraft (runtime) can be downloaded at the bottom of this page. Please be aware of if the mod(s) you need PML for require any additional components, such as for obfuscations.
Installation steps are now located in the download zip. Installation does NOT involve placing the download zip into the mods folder.
Stuff for PML Mod Makers
Note2: This currently doesn't support usage in IDEA environments. You can develop in IDEA, just not run/test.
Installing for Mod Development
Installation steps are now located in the developer's download zip.
Developing a Mod:
PML 10.0 and above
1. Make a text file named "pml.info" in the resources folder. Put the fully-qualified names of the PML mod classes you want to load from PML's bootstrap loader, each on a separate line.
2. There are three types of PML mod classes that you have access to - Obfuscation mods (PMLObfuscationMod), Editing mods (PMLEditMod), and Loading mods (PMLModFactory). Each type has access to slightly different portions of the PML API, and are viewed as portions of a larger mod -- modders are able to use multiple mod classes in tandem to accomplish their goals. Extend one of these abstract classes and either add your subclass' fully qualified name in your "pml.info" or load it from a PMLModFactory that is either directly or indirectly loaded from "pml.info" (a PMLModFactory can load additional PMLModFactory subclasses).
3. In your mod class(es), provide the abstract methods and override whatever you need from parent classes. Your mod's access to the PML APIs is obtained from your mod's "getModLoadAPI" method, provided for you. If you need to access part of PML's API from outside of your mod's class file, please pass the API via parameters, rather than make an access method in your mod class file.
4. Every component of PML's API is numbered and versioned. When using any part of an API, please check that that component is available (via the static methods found in DetailedAPI) in your mod class' init method. If not everything is available, either check backup components you may use, or throw something -- this will signal that your mod should not continue to be loaded.
5. Obfuscation and Edit mods are named (the name is set via the constructor). If more than one named, un-errored mod with the same name is present at the NamedMod postinit phase, the game will not load. An empty name String is an invalid name, as is a null String. Named mods have access to the section of PML's API dealing with inter-mod workings (checking if a mod is present, checking if a mod is active or disabled, mod communications, etc.) -- this API is not available until the postinit phase, however.
6. In your Edit mod class(es, if any,) override the applicationRecommendedLoadTime method, and register any edits you wish to apply to the code. Edits can be in any code, including mod-added or even the application's [normal] starting main method.
7.Bug Alert: For now, if you want to use an object in place of one of its subclasses (such as type Foo, where Foo extends/implements Bar), manually cast to Object then to the subclass. This is to avoid the Java Virtual Machine "helpfully" destroying PML's opportunity for hook registration (by loading the class files too early). This only applies to types not from the Java Core libraries (so not including things like ArrayList, HashMap, etc.)
PML 9.3 and below
1. The first thing to start with is to make a class that extends IPMLModFactory. Despite the poorly chosen name, it is an abstract class rather than an interface. It was an interface until shortly before PML's first release - the name stuck for compatibility.
2. In the preinit method of the class from step 1, use the IPMLFactoryLoadAPI parameter to check if the factory API you are compiling against is the one that is being used, by calling the isDirectlyCompatible method in it, passing IPMLFactoryLoadAPI.currentAPIVersionNumber. If this returns false, throw something (ie. a new RuntimeException). This signals to PML that your mod should not be loaded any further.
3. In the same method as step 2, check if the program is "Minecraft" - [the method's parameter].getProgramInformation().programName().equals("Minecraft"). If this is false, throw something, like before - it would be bad if your Minecraft mod gets loaded for some other program and gets to cause actual problems!
4. Make a text file named "pml.info" in the resources folder. In this file, put the qualified name of the class you made in step 1, followed by a new line (a line feed character). If you decide to make more PML mod factories, list them on their own line in this file - all that are listed will get loaded.
5. Make a new class that extends IPMLMod - yes, it has the same history as IPMLModFactory. Return a new instance of this class, inside of an IPMLMod[], in your factory's loadMod method.
6. The other two methods in IPMLModFactory that you need to implement are for more advanced applications - just return null if you don't want to (or don't know how to) use them.
7. In one of the two init methods in your Mod, use the IPMLModLoadAPI to check if the Mod API is compatible, just like you did in the factory, this time passing IPMLModLoadAPI.currentAPIVersionNumber. This lets PML update in a more modular manner.
8. In your Mod class, override the applicationRecommendedLoadTime method and use it to register your hook requests (via the IHookRegistrar, obtained from the IPMLModLoadAPI) with the correct ClassLoader (the one given). This involves using reflection, or the makeObject method from IPMLMod which simplifies it for you. I suggest making a new class to register your hooks from, which helps cut down on the amount of reflection and open-ended, easily-invalid variable-argument method invocations. (Other AOP libraries/systems use the term "weaves"
9. Within your hooks' passed hook helper, param 0 is the current "this" object if the hooked method is non-static. All other parameters start at parameter 1. You can throw any exception within hooks/weaves. However, it is currently very important to not let Java "helpfully" auto-downcast for you -- for example, if you have a player entity and need to use it as an entity, cast it to an Object then to an entity (not doing this will cause Java to "helpfully" load classes long before they should be).
10. When you are ready to distribute, compile like normal; simply rename the resulting .jar to have the ".pmlm" file-type extension before distributing- this stops Forge from falsely believing it knows how to correctly load your mod right off. After PML loads the file, Forge can then load any @Mod classes in your code like you are used to, via the classpath.
Pictures of PML in action (from various Minecraft mods that use it)
The Realistic Leaves Mod
The Realistic Leaves Mod uses PML to make it so entities (including players) can enter leaf blocks with a reduction in movement speed.
Mega Slimes
The mod uses PML to make larger slimes and to change the slimes' attack strength algorithm to be more bearable at the larger sizes.
The Seasons Mod
The Seasons Mod utilizes PML to make all of its changes take effect - seasonal colors, seasonal temperatures, enhanced snow/ice logic, crop edits, and more.
Terms/Conditions/License/Copyright
Copyright (c) 2015-2016 The_WeatherPony
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
[MC]PML (the MC adaptation code for PML)
Copyright (c) 2015-2016 The_WeatherPony
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
jopt-simple
code for PML is from jopt-simple build 4.9.
jopt-simple is included under its original license and copyright, and I
make no claim of ownership to any of that library's code. I have renamed
the packages and refactored imports accordingly so that an additional yet
different copy of the library may be used at the same time. The package
naming used for this copy of jopt-simple is the same as it usually is, but
with the prefixed package "weatherpony.pml_minecraft."
The included jopt-simple code's copyright/license is below.
Copyright (c) 2004-2015 Paul R. Holser, Jr.
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
WPUtil
Copyright (c) 2015-2016 The_WeatherPony
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
ASM
claim of ownership to any of that library's code. I have renamed the
packages and refactored imports accordingly so that an additional yet
different copy of their library may be used at the same time. The package
naming used for this copy of ASM is the same as it usually is, but with
the prefixed package "weatherpony.util."
The included ASM code's copyright/license is below.
Copyright (c) 2000-2011 INRIA, France Telecom
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
3. Neither the name of the copyright holders nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
THE POSSIBILITY OF SUCH DAMAGE.
Gson/Json
claim of ownership to any of that library's code. I have renamed the
packages and refactored imports accordingly so that an additional yet
different copy of their library may be used at the same time. The package
naming used for this copy of Gson is the same as it usually is, but with
the prefixed package "weatherpony.util."
To conform with the Apache 2.0 license that Gson uses, the following line
has been added to the included Gson library's source code files such that
there are no line number changes:
This file has been modified from its original form in the following way: package renamings and/or import reordering
Any additional changes are documented in the appropriate files.
The included Gson code's copyright/license is below.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Downloads
Remember about the Terms/Conditions/License/Copyright
The current version uses/is PML v10.3. The download was last updated on: 4th of July, 2017, for reason: fixed copy of included WPUtil to latest
Download (Users) : [with ads, manual install] [Link Removed]
Download (Developers; compiled and source) : [with ads] [Link Removed]
Previous Versions (kept for archival purposes; only the last version before an incompatible API change was made is kept here.):
Download (Developers; compiled and source) : [with ads] [Link Removed]
***If something happens to a download link to make it no longer work, I will try to get it back up quickly.
I program
You can put them in the mods folder if they have the '.pmlm' extension like intended, or they can be put in the PMLMods folder as a .pmlm, .zip,.jar, extracted files, etc. I'll add that to the info.
I haven't used LiteLoader in ages, but it should be fine. If not, please let me know what the issue is. Installation order for the three together would be Forge, LiteLoader, then PML. PML should always be installed last, though it always gets loaded first.
I program
Is this for ModPackInstaller to distribute your modpack, or is this so that the files are separate from other modpacks?
I program
I can try to get that to play better for PML9.2, along with some other oddball issues.
I program
While it's possible to rewrite my mods so that they don't need PML (by making it so they handle what PML does for them on their own in a more Minecraft-y way), it would not be advantageous from a code perspective.
My mods tend to deal very heavily with bytecode manipulation and reflection (for example, The Seasons Mod modifies more than 100 different methods in just vanilla+Forge alone, and modifies an additional untold number of things from other mods [plus it uses reflection to access plenty of private/protected methods/fields, on top of that]). PML automates the obfuscation handling, the underlying bytecode editing, and (to a lesser extent) the reflection involved. What would normally take several thousands of lines of ASM bytecode editing and lots of time-consuming obfuscation handling by hand, PML reduces to a couple hundred lines of simple copy-paste-able framework that accepts standard development obfuscation names.
I'll promise this: If I make a mod that doesn't actually use PML, then I won't make that mod require/use it.
I program
Ahh. Sorry that I didn't pick up on your asking-[while/because]-waiting
Thank you for liking it - I focused super-heavily on ease-of-use for it; modders have enough to deal with already, without needing to learn another language (like for many other AOP libraries) or something super-complicated. Ease > Fine Control ^^
Since you said you were interested in PML for the Improved First Person mod, I'd like to let you know that PML might not have everything you're after: since PML doesn't deal with any section of code specifically, there could easily be parts that are handled better in RenderPlayer API (such as constructors). You'd need to weigh whether automated method hook creation and obfuscation handling (plus no need for regular updates) stands up better or worse compared to easier-to-install and the other little details in RenderPlayer API.
I program
I'm not sure why you think you'd need PML for that, since I've seen at least two mods that do it purely with Forge.
One being TerraFirmaCraft (Mod's Official Site), and another that I can't remember.
That's pretty much already been covered in RPGLoot (Curseforge Link). It shouldn't be too difficult to make an addon for it, or at least branch off that mod to make them do what you want.
Not sure what you mean here, but it could probably be done with forge as well.
DarianStephens - While vrackfall's first idea could be done through just Forge, PML would make it easier to code and expand the logic more rapidly. (Writing Forge coremods isn't all that pleasurable, and there's not very much documentation/explanation to help. Writing bytecode editing code isn't all that great either, and ends up taking longer to port, due to needing to handle obfuscations. On the other hand, PML is newer but more documented and easier to learn; it also handles the bytecode editing and obfuscations so that vrackfall wouldn't need to.) While it could be done with just Forge, it doesn't mean it would be easier with just Forge. I think vrackfall should go with what he feels is the better trade-off [even if that's not PML]).
Edit: by the way, PML, itself, used to be a Forge coremod, but was converted to be a java agent for compatibility with mods such as CodeChickenCore.
I program
So... would this happen to support MultiMC?
If it doesn't, then maybe this won't help you.
If it does, then could you please help me with this error? I think it's because MultiMC keeps the Minecraft jar in a different place or something, making PML unable to find it.
If it helps, I put the folders 'PML' and 'PMLCore' (With their contents intact) into this Minecraft instance's 'minecraft' folder.
How would one install this/seasons into a MultiMC instance? It just crashes on startup.
I've set up a 1.7.10 instance with forge, and done the equivalent 2 steps for a normal client
I put both the seasons mod and the PML MCP-Dev thing in the mods folder.
Would I be better trying to follow/adapt the technic instructions, or is there another solution?
DarianStephens and KryptonCaptain - MultiMC isn't supported yet, since they are launching the game differently than other launchers. I'll learn some of what MultiMC is doing (specifically how it's doing it) and figure out the best course of action.
I program
You can walk through all leaves in TerraFirmaCraft, but can otherwise interact with them normally.
Problem i Had is already solved
Any Idea as to how to make it work on multimc?
KuroNeko87 - I have some ideas, but I want to be sure one of them works before I start making suggestions.
Though there wouldn't be this problem if MultiMC worked like other launchers...
I program
I tried doing both ways but none of them work. The way multimc does forge is a bit different. It's OK though, I setup a vanilla launcher thingie for the pack where I have seasons
How would one install this to an FTB server?
LunariusH - looked through FTB, and I found a way to install this through their current setup for the client. Unfortunately, it isn't very user-friendly. I'll start on the server, next...
You can then put pmlm files in either the regular mods folder like you are used to or the new PMLMods folder - it makes no difference.
Edit: FTB servers look to be just normal Forge servers... so just a stock server installation would work.
I program
Made a tiny bugfix update to the Minecraft App component, to fix support for Minecraft Pre-Release snapshots. It's so tiny and specific of a fix that it's not worth updating unless you want to use PML with Minecraft Pre-Release snapshots (such as the brand new MC "1.9-pre1" version).
...as far as I'm aware, this is only relevant for my Mega Slimes mod, which already has 1.9-pre1 obfuscations available to it. I hope more mods will rely on this in due time...
I program
So, what sort of progress has been made with MultiMC compatibility?