GhostUtil (aka. Ghost's Utilities) is a library for Psych Engine with the objective to make programming easier. It provides a unique environment for you to mess around in.
These are the people who contributed to GhostUtil atleast once
- PEModUtils by galactic_2005
- Add the "ghostutil" folder to the main Psych Engine folder (where the
.exe
is).
- Next, drag-n-drop the
callbackhandler.lua
file tomods/scripts
.
- To use GhostUtil, you must import it's modules; you must use the
require
function.
local string = require 'ghostutil.lua-addons.string'
local math = require 'ghostutil.lua-addons.math'
local game = require 'ghostutil.game'
local outdate = require 'ghostutil.outdate-handler'
- Now you can mess around in the GhostUtil environment!
local math = require "ghostutil.lua-addons.math"
local game = require "ghostutil.game"
function onCreate()
luaDebugMode = true
game.doTweenScale("tweenScale", "boyfriend", {2, 2.1}, "expoOut")
game.doTweenPosition({"boyfriendcool", "boyfriendswag"}, "boyfriend", {
game.getPosition("boyfriend").x - 100,
math.boundto(game.getPosition("dad").y + 100, -100, 200)
}, 2, "expoOut")
end
CHECK OUT THE WIKI FOR MORE FUNCTIONS.
Psych Engine:
-
below 0.6.3: Some of the functions GhostUtil utilizes don't exist.
-
0.7.1h: It breaks GhostUtil (mostly because of
runHaxeCode
);
GhostUtil:
-
below 2.0.0a: When using the
Window
class, addwindow.init()
before doing anything with the Window class. -
below 1.0.0: Naming the variable
math
will break the script.