!!!!! YOU ONLY NEED THIS MOD IF ANOTHER MOD REQUIRES IT !!!!!
What is it?!
This is a java mod that re-enables reflection functionality that was disabled in B42.15.
The following functions have been re-enabled:
- getNumClassFields
- getNumClassFunctions
- getClassField
- getClassFieldVal
- getClassFunction
- getMethodParameter
- getMethodParameterCount
Installation
1. Assuming default Steam install location, and Project Zomboid install location, navigate to:
- Windows: C:\Program Files (x86)\Steam\steamapps\workshop\content\108600\3682136459\
- Linux: /home/<username>/.steam/steam/steamapps/workshop/content/108600/3682136459/
2. Go into: mods/reflection-enabler/
3. Copy the 'zombie' folder into the following:
- Windows: C:\Program Files (x86)\Steam\steamapps\common\ProjectZomboid\
- Linux: /home/<username>/.steam/steam/steamapps/common/ProjectZomboid/projectzomboid/
If you're in the right location, you'll see some, or all of the following folders:
- android
- jre64
- launcher
- license
- linux64
- media
- steamapps
- Workshop
4. Enable the mod in-game, so it can validate that the Java mod is installed correctly, and up to date.
Modders: How to check if the patch is enabled
Two new functions have been added to lua globally:
- getReflectionVersion() - Returns the version of this mod.
- getReflectionGameVersion() - Returns the version the patch was created for.
You can use lua's pcall function to test and get the results of these functions, to see if the patch is enabled:
local status, result = pcall(getReflectionGameVersion)
'status' will return true if the function exists, and executed.
'result' will be the return value of the function.
You can view the scripts included with this mod for further details.
You should make the lua mod a requirement, so the lua can perform the version checking.
Workshop ID: 3682136459
Mod ID: ReflectionEnabler
