General Functions - VsFoxaTeam/FNF-Unfulfilled-Journey-Foxa-Engine GitHub Wiki
Plays a specific character animation.
-
character
- The character name, can beboyfriend
,dad
orgf
. -
anim
- The animation name to be played. -
forced
- Can be eithertrue
orfalse
, if set totrue
, it will force the animation to reset if the current animation is the same as the animation to play.
Makes character do the idle dance.
-
character
- The name of the character, can beboyfriend
,dad
orgf
.
Sets the general x position of a character from the type
parameter, this will also move all precached characters from the same type into the position you want.
-
type
- The character name, can beboyfriend
,dad
orgf
. -
value
- The x value of the character position.
Sets the general y position of a character from the type
parameter, this will also move all precached characters from the same type into the position you want.
-
type
- The name of the character, can beboyfriend
,dad
orgf
. -
value
- The y value of the character position.
Gets the general x position of a character from the type
parameter.
-
type
- The name of the character name, can beboyfriend
,dad
orgf
.
Gets the general y position of a character from the type
parameter.
-
type
- The name of the character name, can beboyfriend
,dad
orgf
.
Adds the value
parameter to the current song score total and recalculates the rating.
Adds the value
parameter to the current song miss total and recalculates the rating.
Adds the value
parameter to the current song hit total and recalculates the rating.
Adds the value
parameter to the current song health total and recalculates the rating.
Sets the value
parameter of the current song score total into a specified state and recalculates the rating.
Sets the value
parameter of the current song miss total into a specified state and recalculates the rating.
Sets the value
parameter of the current song hit total into a specified state and recalculates the rating.
Sets the value
parameter of the current song health total into a specified state and recalculates the rating.
Sets the rating percent in case you want to do your own rating calculation.
-
value
- Should go from0
to1
but can actually be whatever value you want, but it's kinda stupid to get out of the base values.
Sets the rating name to the value
parameter in case you want to do your own rating calculation.
-
value
- The rating string accuracy.
Sets the rating combo on the scoreTxt
.
-
value
- The rating combo accuracy.
Gets the current songs score total.
Gets the current songs miss total.
Gets the current songs hit total.
Gets the current songs health total.
Checks whether the sprite object exists in the currently playing song.
-
tag
- The tag of the sprite object.
Checks whether the text object exists in the currently playing song.
-
tag
- The tag of the text object.
Checks whether the sound object exists in the currently playing song.
-
tag
- The tag of the sound.
Checks the starting section of the string with the start
parameter.
-
str
- The string to be manipulate. -
start
- The start of the string.
Checks the ending section of the string with the start
parameter.
-
str
- The string to be manipulate. -
end
- The end of the string.
Splits a string into multiple string will turn it into a Table.
-
str
- The string to split. -
start
- The seperation of the string.
Example: stringSplit('Split, This, LOL!', ', ')[1]
This will print 'Split'.
Removes any unnecessary large spaces from string.
-
str
- The string to be converted.
Gets the text from different files.
-
path
- The path of the text file that you are getting. -
ignoreModFolders
- An optional parameter that ignores the mod folder with a Boolean.
Example: getTextFromFile('pathTotheFile/ExampleFile.txt')
Gets the every files inside of the folder.
-
folder
- The path to the folder
Changes the contents of file then saves it.
-
path
- The path of the file that you are getting. -
content
- The contents of the file to be saved, must be surrounded by double brackets[[]]
. -
absolute
- An optional parameter that ignores the mod folder with a Boolean.
Deletes the file you want.
-
path
- The path of the file that you are getting. -
ignoreModFolders
- An optional parameter that ignores the mod folder with a Boolean.
Checks if the file existed, its like lua exists function but its global.
-
filename
The path of the file that you are getting. -
absolute
- An optional parameter that ignores the mod folder with a Boolean.
Example: checkFileExists('mods/pathTotheFile/luafile.lua')
Note: Put the file format name to get the file you want.
-
luaFile
- The file that you want to detect that is running currently.
Example: isRunning('mods/pathTotheFile/luafile.lua')
Checks multiple scripts executing currently; use generic loop to use this.
Adds a lua script into the game.
-
path
- The path of the file that you are getting.
Removes a lua script into the game.
-
path
- The path of the file that you are getting.
Adds a library variable into the interpreter.
-
libName
- The name of the library name. -
libPackage
- The name of the library package.
Example: addHaxeLibrary('FlxTween', 'flixel.tweens')
It executes the string as a Haxe script.
-
codeToRun
- the haxe code to be executed, use double brackets[[]]
when making the haxe code.
Sets the global variable with a new value from another lua script; this will not work with local variable.
-
luaFile
- The path of the file that you are getting. -
global
- The variable to be chosen. -
val
- The new value of the variable.
Gets the current value of a global variable from another lua script; this does not work with local variables.
-
luaFile
- The path of the file that you are getting. -
global
- The variable to be chosen.
Will open your custom substate. To create a custom substate click here.
-
name
- The name of the custom substate. -
pauseGame
- An optional value, will pause your game when opening the custom substate.
Will close your custom substate.
-
name
- The name of the custom substate.
This will randomize a Int number. (Better than math.random()
)
-
min
- The lowest value. -
max
- The highest value.
This will randomize a Float number.
-
min
- The lowest value. -
max
- The highest value.
It randomizes the chance of it being true
.
-
chance
- The possibility of it beingtrue
.
Makes the camera shake.
-
camera
- The current camera state, can be eithercamGame
,camHUD
orcamOther
. -
intensity
- How much intesity will the camera shake, recommended value is0.05
. -
duration
- How long will the shake last.
Makes the camera focus on the target.
-
target
- The character type to target, can be eitherboyfriend
ordad
.
Makes the camera flash.
-
camera
- The current camera state, can be eithercamGame
,camHUD
orcamOther
. -
color
- The color of the flash. (Must be a Hexadecimal Color Code) -
duration
- How long will the camera flash. -
forced
- Whether or not restart the flash.
Makes the camera fade.
-
camera
- The current camera state, can be eithercamGame
,camHUD
orcamOther
. -
color
- The color of the fade. (Must be a Hexadecimal Color Code) -
duration
- How long will the camera fade. -
forced
- Whether or not restart the fade.
Triggers an event without having to enter it into the chart editor.
-
name
- The name of the event in the Chart editor. -
arg1
- The value on the Value 1. -
arg2
- The value on the Value 2.
Changes the health bar colors. (Must be a Hexadecimal Color Code)
-
leftHex
- The opponent health bar color. -
rightHex
- The player health bar color.
Changes the time bar colors. (Must be a Hexadecimal Color Code)
-
leftHex
- The color of the time bar. -
rightHex
- The background color of the time bar.
Gets the color from the Hexadecimal Color Code.
Example: To get orange, you should use getColorFromHex('FF7800')
or getColorFromHex('0xFFFF7800')
.
Returns the current song position, Shortcut to getPropertyClass('Conductor', 'songPosition')
.
Removes a specific note group.
-
obj
- The strum group name on the note. -
index
- The member ID of the note to be tween, Opponent:0,1,2,3
and Player:4,5,6,7
. -
dontDestroy
- An optional variable. Won't clear the member from memory, you will probably never ever use this.
Example: To remove the first spawned note from the group you should use removeFromGroup('notes', 0)
.
This command displays a debug message in the top-left corner of the screen. All of the values are optional, and you can print up to 5 of them.
Example: debugPrint("Current boyfriend character: ", getProperty('boyfriend.curCharacter')
This will print the following message: Current boyfriend character: bf
.
Stops your script in the next 100 miliseconds. And must be used in a Stage script
because it won't be used anymore.