-
Notifications
You must be signed in to change notification settings - Fork 0
apicompatible
apicompatible is a module used to make compatibility easier between different versions of Pysch Engine.
This module is used for both compatibility with older versions of Psych Engine, alongside newer versions when they come out and this module is updated accordingly.
Note that this module does not promise nor provides 100% compatibility, especially with complex scripts or of scripts that rely on newer content not present in older versions (object functions, RGB note colors, etc..)
-
returnClassNameDebugMessage = false
- whetherreturnCompatibleClassName
andreturnCompatibleVariableName
output a debug message if no class name was found.
Enables the HUE/Brt/Sat system that was used before 0.7.0.
Note that this function enables the system for all notes and strums.
Returns the class name that is compatible with reflection functions in the version being played.
Example:
debugPrint(apicompatible.returnCompatableClassName('PlayState'))
--[[
returns 'PlayState' if 0.6.3 or lower
returns 'states.PlayState' if 0.7.0 or higher
]]
Set returnClassNameDebugMessage
to true
if you wish to recieve debug messages when no class name is found.
Returns the variable name that is compatible with reflection functions in the version being played.
Set returnClassNameDebugMessage
to true
if you wish to recieve debug messages when no class name or variable name is found.
Returns the client preference name that is compatible with reflection functions in the version being played
In version 0.7.0 and above, you are required to prefix the client preference name with .data
or else it wouldn't work.
A version of getPropertyFromClass
that automatically converts variables using the other functions listed.
Refer to the documenation for getPropertyFromClass
for more information on this function.
A version of setPropertyFromClass
that automatically converts variables using the other functions listed.
Refer to the documenation for setPropertyFromClass
for more information on this function.