Difference between revisions of "Compiled Index of Lua Scripts for Visionaire Studio"

From The Official Visionaire Studio: Adventure Game Engine Wiki
(Basic)
(Visionaire Studio Functions)
Line 66: Line 66:
 
| [[GetProperty_(CMS)|getProperty()]] || Retrieve various operating system (os) properties; such as: platform, system language etc...
 
| [[GetProperty_(CMS)|getProperty()]] || Retrieve various operating system (os) properties; such as: platform, system language etc...
 
|-
 
|-
| [[GetSoundId_(CMS)|getSoundId()]] || ...
+
| [[GetSoundId_(CMS)|getSoundId()]] || Retrieve id of linked sound. (only applicable for active sounds)
 
|-
 
|-
| [[GetSoundProperty_(CMS)|getSoundProperty()]] || ...
+
| [[GetSoundProperty_(CMS)|getSoundProperty()]] || Retrieve various properties of linked sound, such as: current playtime, balance, volume, loop. (only applicable for active sounds)
 
|-
 
|-
| [[GetSteamAchievement_(CMS)|getSteamAchievement]] || ...
+
| [[GetSteamAchievement_(CMS)|getSteamAchievement]] || Retrieve boolean value of linked steam achievement.
 
|-
 
|-
| [[GetSteamStat_(CMS)|getSteamStat]] || ...
+
| [[GetSteamStat_(CMS)|getSteamStat]] || Retrieve integer value of linked steam stat.
 
|-
 
|-
 
| [[GetTexts_(CMS)|getTexts()]] || Retrieve all texts associated with the linked object.
 
| [[GetTexts_(CMS)|getTexts()]] || Retrieve all texts associated with the linked object.
Line 86: Line 86:
 
| [[IsEmpty_(CMS)|isEmpty()]] || Returns true or false; depending on whether or not the linked object is empty.
 
| [[IsEmpty_(CMS)|isEmpty()]] || Returns true or false; depending on whether or not the linked object is empty.
 
|-
 
|-
| [[RegisterEventHandler_(CMS)|registerEventHandler()]] || ...
+
| [[RegisterEventHandler_(CMS)|registerEventHandler()]] || Create loops, listen out for various events; such as mouse actions, action/text started/stopped etc...
 
|-
 
|-
| [[RegisterHookFunction_(CMS)|registerHookFunction()]] || ...
+
| [[RegisterHookFunction_(CMS)|registerHookFunction()]] || Set displayed & action text positions.
 
|-
 
|-
| [[ResetSteamStats_(CMS)|resetSteamStats()]] || ...
+
| [[ResetSteamStats_(CMS)|resetSteamStats()]] || Reset the linked steam stat back to its default value.
 
|-
 
|-
| [[SetCursorPos_(CMS)|setCursorPos()]] || ...
+
| [[SetCursorPos_(CMS)|setCursorPos()]] || Set the absolute position of the mouse cursor.
 
|-
 
|-
| [[SetSoundProperty_(CMS)|setSoundProperty()]] || ...
+
| [[SetSoundProperty_(CMS)|setSoundProperty()]] || Set the properties of a linked sound, such as: current playtime position, balance, volume, loop (requires sound id)
 
|-
 
|-
| [[SetSteamAchievement_(CMS)|setSteamAchievement()]] || ...
+
| [[SetSteamAchievement_(CMS)|setSteamAchievement()]] || Set the boolean value of the linked steam achievement.
 
|-
 
|-
| [[SetSteamStat_(CMS)|setSteamStat()]] || ...
+
| [[SetSteamStat_(CMS)|setSteamStat()]] || Set the integer value of the linked steam stat.
 
|-
 
|-
| [[SetVolume_(CMS)|setVolume()]] || ...
+
| [[SetVolume_(CMS)|setVolume()]] || Adjust the volume levels for: music, sound, speech, videos, & master.
 
|-
 
|-
| [[SetWindowBrightness_(CMS)|setWindowBrightness()]] || ...
+
| [[SetWindowBrightness_(CMS)|setWindowBrightness()]] || Adjust the global window brightness value.
 
|-
 
|-
| [[SetWindowTitle_(CMS)|setWindowTitle()]] || ...
+
| [[SetWindowTitle_(CMS)|setWindowTitle()]] || Set a custom title in the window application bar (only applicable for window mode)
 
|-
 
|-
| [[StartAction_(CMS)|startAction()]] || ...
+
| [[StartAction_(CMS)|startAction()]] || Call & start the linked action.
 
|-
 
|-
| [[StartAnimation_(CMS)|startAnimation()]] || ...
+
| [[StartAnimation_(CMS)|startAnimation()]] || Play the linked animation.
 
|-
 
|-
| [[StartDefaultBrowser_(CMS)|startDefaultBrowser]] || ...
+
| [[StartDefaultBrowser_(CMS)|startDefaultBrowser]] || Launch default web browser & open the linked url in a new tab. (only launches browser if not already open)
 
|-
 
|-
| [[StartSound_(CMS)|startSound()]] || ...
+
| [[StartSound_(CMS)|startSound()]] || Play the linked sound; additional properties can also be set such as: current playtime position, balance, volume, & loop.
 
|-
 
|-
| [[StopAction_(CMS)|stopAction()]] || ...
+
| [[StopAction_(CMS)|stopAction()]] || Stop the linked action. (only applicable for active actions)
 
|-
 
|-
| [[StopAnimation_(CMS)|stopAnimation()]] || ...
+
| [[StopAnimation_(CMS)|stopAnimation()]] || Stop & unload the linked action. (only applicable for active animations)
 
|-
 
|-
| [[StopSound_(CMS)|stopSound()]] || ...
+
| [[StopSound_(CMS)|stopSound()]] || Stop the linked sound; requires sound id. (only applicable for active sounds)
 
|-
 
|-
| [[ToggleSoundPause_(CMS)|toggleSoundPause()]] || ...
+
| [[ToggleSoundPause_(CMS)|toggleSoundPause()]] || Toggle linked sound between playing & paused state; requires sound id. (only applicable for active sounds)
 
|-
 
|-
| [[UnregisterEventHandler_(CMS)|unregisterEventHandler()]] || ...
+
| [[UnregisterEventHandler_(CMS)|unregisterEventHandler()]] || Unregister the linked event handler & function.
 
|}
 
|}

Revision as of 15:30, 23 March 2014

Here you can find a list of verified working Lua scripts made by various members of the Visionaire Studio team & forum community.

Basic

Script Name By
Globally Mute/Restore Volume AFRLme

Intermediate

Script Name By
Cycle Inventory Items AFRLme
Dynamic Action Names AFRLme
Global Command Checker AFRLme
Load External Scripts Divo
Organize Inventory Items Alphabetically AFRLme
Percentage Display (real time) AFRLme

Advanced

Script Name By
Config.ini (read/write) AFRLme
Dynamic Action Names for Dragged Items AFRLme
Sliding Interfaces (based on Deponia) AFRLme
Volume Control (rail, button, percentage) AFRLme

Visionaire Studio Functions

Function Name Description
createScreenshot() Create a screenshot & save as .png to a specified folder or use the screenshot for the save game thumbnail.
getCursorPos() Retrieves the current (absolute) position of the mouse cursor.
getLink() Retrieves the data stored inside of a linked objects table.
getLinks() Retrieves grouped data stored inside of a linked objects table.
getName() Returns the "string" name value of the linked objects table.
getObject() Retrieves the data stored inside of a linked objects table.
getProperty() Retrieve various operating system (os) properties; such as: platform, system language etc...
getSoundId() Retrieve id of linked sound. (only applicable for active sounds)
getSoundProperty() Retrieve various properties of linked sound, such as: current playtime, balance, volume, loop. (only applicable for active sounds)
getSteamAchievement Retrieve boolean value of linked steam achievement.
getSteamStat Retrieve integer value of linked steam stat.
getTexts() Retrieve all texts associated with the linked object.
getTextStr() Retrieve a specific text string, based on the current game language or the included language id.
getTime() Developer command for checking time between 2 points; can be re-purposed into a crude delay or loop function.
getVolume() Retrieve volume levels for: music, sound, speech, videos, & master.
getWindowBrightness() Retrieve global window brightness value.
isEmpty() Returns true or false; depending on whether or not the linked object is empty.
registerEventHandler() Create loops, listen out for various events; such as mouse actions, action/text started/stopped etc...
registerHookFunction() Set displayed & action text positions.
resetSteamStats() Reset the linked steam stat back to its default value.
setCursorPos() Set the absolute position of the mouse cursor.
setSoundProperty() Set the properties of a linked sound, such as: current playtime position, balance, volume, loop (requires sound id)
setSteamAchievement() Set the boolean value of the linked steam achievement.
setSteamStat() Set the integer value of the linked steam stat.
setVolume() Adjust the volume levels for: music, sound, speech, videos, & master.
setWindowBrightness() Adjust the global window brightness value.
setWindowTitle() Set a custom title in the window application bar (only applicable for window mode)
startAction() Call & start the linked action.
startAnimation() Play the linked animation.
startDefaultBrowser Launch default web browser & open the linked url in a new tab. (only launches browser if not already open)
startSound() Play the linked sound; additional properties can also be set such as: current playtime position, balance, volume, & loop.
stopAction() Stop the linked action. (only applicable for active actions)
stopAnimation() Stop & unload the linked action. (only applicable for active animations)
stopSound() Stop the linked sound; requires sound id. (only applicable for active sounds)
toggleSoundPause() Toggle linked sound between playing & paused state; requires sound id. (only applicable for active sounds)
unregisterEventHandler() Unregister the linked event handler & function.