SRPG Studio Script Reference

root

Root

To manage the root information.

Method

It gets the version of the script.

{number} getScriptVersion()

Returns

{number} version


Reset the game.

resetGame()

Quit the game.

endGame()

It gets the screen state of the current application.

{number} getAppScreenMode()

Returns

{number} AppScreenMode value


true if the specified value is input, otherwise it returns false.

{boolean} isInputAction(value)

Parameters

{number} value InputType value

Returns

{boolean} Boolean


true if the specified value is continuously input, otherwise it returns false.

{boolean} isInputState(value)

Parameters

{number} value InputType value

Returns

{boolean} Boolean


In the case of 60FPS true, otherwise it returns false.

{boolean} isHighPerfMode()

Returns

{boolean} Boolean


In the case of test play true, otherwise it returns false.

{boolean} isTestPlay()

Returns

{boolean} Boolean


If you want to skip the "Opening Events" is true, otherwise it returns false.

{boolean} isOpeningEventSkip()

Returns

{boolean} Boolean


true if the attack is sure to hit, otherwise it returns false.

{boolean} isAbsoluteHit()

Returns

{boolean} Boolean


If the system configuration is valid, true, otherwise it returns false.

{boolean} isSystemSettings(type)

Parameters

{number} type SystemSettingsType value

Returns

{boolean} Boolean


To start the measurement of time.

watchTime()

Get in milliseconds, the elapsed time from calling the watchTime.

{number} getElapsedTime()

Returns

{number} elapsed time


Get the most recent FPS.

{number} getFPS()

Returns

{number} FPS


And displays a message box.

msg(text)

Parameters

{string} text message


It prints a string to the console.

log(text)

Parameters

{string} text Character string


It clears the contents of the console.

resetConsole()

Save the screen shot. HardwareAcceleration of Game.ini is valid if it is set to 1.

saveScreenShot(isMapAll)

Parameters

{boolean} isMapAll If you want the entire map to the target is true, otherwise specify the false.


Open the map for the demonstration.

{boolean} openMap(mapId)

Parameters

{number} mapId It specifies the ID of the map.

Returns

{boolean} If you open the map true, otherwise it returns false.


Close the map for the demonstration.

closeMap()

Create a resource handle.

{ResourceHandle} createResourceHandle(isRuntime, id, colorIndex, xSrc, ySrc)

Parameters

{boolean} isRuntime true in the case of runtime, false otherwise.

{number} id id to see

{number} colorIndex Index of the color

{number} xSrc Image source of x-coordinate

{number} ySrc Image source of the y coordinate

Returns

{ResourceHandle} Resource handle


Create an empty resource handle.

{ResourceHandle} createEmptyHandle()

Returns

{ResourceHandle} Resource handle


It gets a random number.

{number} getRandomNumber()

Returns

{number} random number


Set the self-switch.

setSelfSwitch(lIndex, flag)

Parameters

{number} lIndex index

{boolean} flag If you want to turn it is true, false otherwise.


Changing the background image, to erase the objects displayed in a display of the image.

resetVisualEventObject()

Draw the asynchronous event data.

drawAsyncEventData()

Draw a thumbnail image of the map.

drawMapAll(map)

Parameters

{Map} map Map you want to draw


Draw a panel to position the index points.

drawWavePanel(arr, pic, scrollCount)

Parameters

{object} arr Index array

{Image} pic Panel image

{number} scrollCount Scroll value


Change the color of the position the index points.

drawFadeLight(arr, color, alpha)

Parameters

{object} arr Index array

{number} color color

{number} alpha Alpha value


Draw the HP gauge.

drawCharChipHpGauge(x, y, unit)

Parameters

{number} x x-coordinate

{number} y y coordinate

{Unit} unit unit


Draw a "Map Unit Symbol".

drawCharChipSymbol(x, y, unit)

Parameters

{number} x x-coordinate

{number} y y coordinate

{Unit} unit unit


Draw a state icon.

drawCharChipStateIcon(x, y, unit)

Parameters

{number} x x-coordinate

{number} y y coordinate

{Unit} unit unit


It gets the object to decorate the HP of character chip.

{GraphicsDecoration} getHpDecoration(type)

Parameters

{number} type HpDecorationType value

Returns

{GraphicsDecoration} Decorative objects


It gets the object to decorate around the character chip.

{GraphicsDecoration} getSymbolDecoration(type)

Parameters

{number} type SymbolDecorationType value

Returns

{GraphicsDecoration} Decorative objects


To initiate a change in the "Change Background" of the event command.

startBackgroundChange()

Duplicate the item.

{Item} duplicateItem(*item)

Parameters

{Item} *item Replicated items

Returns

{Item} Replicated items


It gets the width of the window.

{number} getWindowWidth()

Returns

{number} The width of the window


It gets the height of the window.

{number} getWindowHeight()

Returns

{number} The height of the window


It gets the width of the game area.

{number} getGameAreaWidth()

Returns

{number} The width of the game area


It gets the height of the game area.

{number} getGameAreaHeight()

Returns

{number} The height of the game area


Gets the x-coordinate of the view port.

{number} getViewportX()

Returns

{number} x-coordinate


Gets the y-coordinate of the view port.

{number} getViewportY()

Returns

{number} y coordinate


Set the x and y coordinates of the viewport. Viewport, but represents the drawing reference position, always has the upper left corner will be the origin for the cache.

setViewportPos(x, y)

Parameters

{number} x x-coordinate

{number} y y coordinate


It gets an object that manages the information of the meta session.

{MetaSession} getMetaSession()

Returns

{MetaSession} MetaSession object


It gets an object that manages the information of the current session. If the map is open it will be returned GameSession. The current scene is in the case of SceneType.REST is returned RestSession.

{GameSession} getCurrentSession()

Returns

{GameSession} GameSession object or objects RestSession


It gets an object that manages the external data.

{ExternalData} getExternalData()

Returns

{ExternalData} MetaSession object


It gets an object that manages the information of "Database".

{BaseData} getBaseData()

Returns

{BaseData} BaseData object


It gets an object that manages the configuration information.

{ConfigInfo} getConfigInfo()

Returns

{ConfigInfo} ConfigInfo object


It gets an object that manages the user extension.

{UserExtension} getUserExtension()

Returns

{UserExtension} UserExtension object


It gets an object that manages the animation information.

{AnimePreference} getAnimePreference()

Returns

{AnimePreference} AnimePreference object


It gets an object that manages the option of "Story Settings".

{StoryPreference} getStoryPreference()

Returns

{StoryPreference} StoryPreference object


It gets an object that manages the option of "Base Settings".

{RestPreference} getRestPreference()

Returns

{RestPreference} RestPreference object


It gets an object that manages the save file.

{LoadSaveManager} getLoadSaveManager()

Returns

{LoadSaveManager} LoadSaveManager object


It gets an object that manages the drawing.

{GraphicsManager} getGraphicsManager()

Returns

{GraphicsManager} GraphicsManager object


It gets an object that manages the media.

{MediaManager} getMediaManager()

Returns

{MediaManager} MediaManager object


It gets an object that manages the material.

{MaterialManager} getMaterialManager()

Returns

{MaterialManager} MaterialManager object


It gets an object that controls the scene.

{SceneController} getSceneController()

Returns

{SceneController} SceneController object


Dynamically Gets an object to run the event.

{EventGenerator} getEventGenerator()

Returns

{EventGenerator} EventGenerator object


It gets the object you want to edit the data.

{DataEditor} getDataEditor()

Returns

{DataEditor} DataEditor object


It gets the object of screen effect.

{ScreenEffect} getScreenEffect()

Returns

{ScreenEffect} ScreenEffect object


It gets the animation of "Resource Location".

{Anime} queryAnime(key)

Parameters

{string} key Character string

Returns

{Anime} Anime object


It gets the media of "Resource Location".

{ResourceHandle} querySoundHandle(key)

Parameters

{string} key Character string

Returns

{ResourceHandle} Resource Handle objects


It gets the image of "Resource Location".

{ResourceHandle} queryGraphicsHandle(key)

Parameters

{string} key Character string

Returns

{ResourceHandle} Resource Handle objects


It gets the UI of "Resource Location".

{Image} queryUI(key)

Parameters

{string} key Character string

Returns

{Image} Image object


It gets the text UI of "Resource Location".

{InteropTextUI} queryTextUI(key)

Parameters

{string} key Character string

Returns

{InteropTextUI} TextUI object


It gets the screen of "Resource Location".

{InteropScreen} queryScreen(key)

Parameters

{string} key Character string

Returns

{InteropScreen} Screen object


It gets the command of "Resource Location".

{string} queryCommand(key)

Parameters

{string} key Character string

Returns

{string} Character string


It gets the width of "Large Face".

{number} getLargeFaceWidth()

Returns

{number} width


It gets the height of the "Large Face".

{number} getLargeFaceHeight()

Returns

{number} height


If you want to use the "Large Face" is true, otherwise it returns false.

{boolean} isLargeFaceUse()

Returns

{boolean} Boolean


If you want to darken if you do not speak it is true, otherwise it returns false.

{number} isMessageBlackOutEnabled()

Returns

{number} Boolean


If you are always displayed at the bottom of the message window is true, otherwise it returns false.

{boolean} isMessageWindowFixed()

Returns

{boolean} Boolean


It gets the default width of the character-chip resources.

{number} getCharChipWidth()

Returns

{number} width


It gets the default height of a character-chip resources.

{number} getCharChipHeight()

Returns

{number} height


It gets the default width of the icon resource.

{number} getIconWidth()

Returns

{number} width


It gets the default height of the icon resource.

{number} getIconHeight()

Returns

{number} height


It gets the default width of map-chip resources.

{number} getMapChipWidth()

Returns

{number} width


It gets the default height of the map-chip resources.

{number} getMapChipHeight()

Returns

{number} height


true if the event is currently being executed, otherwise it returns false.

{boolean} isEventSceneActived()

Returns

{boolean} Boolean


It gets an object that represents the current event command.

{object} getEventCommandObject()

Returns

{object} object


It gets the type of the current event command.

{number} getEventCommandType()

Returns

{number} EventCommandType value


It gets the index of on the event of the current event command.

{number} getEventCommandIndex()

Returns

{number} index


Exit the current event command.

endEventCommand(exitCode)

Parameters

{number} exitCode Exit code


Get the exit code of the current event.

setEventExitCode(exitCode)

Parameters

{number} exitCode Exit code


Set the end code for the current events.

{number} getEventExitCode()

Returns

{number} Exit code


Set the skip state for the current events.

setEventSkipMode(isSkipMode)

Parameters

{boolean} isSkipMode If you want to skip it is true, false otherwise.


true if the current event is a skip state, otherwise it returns false.

{boolean} isEventSkipMode()

Returns

{boolean} Boolean


Events Gets a number that has been layered.

{number} getChainEventCount()

Returns

{number} The number that has been layered


It gets the event of a specified hierarchy.

{Event} getChainEvent(index)

Parameters

{number} index index

Returns

{Event} Events


Change to a specific scene from the current scene.

changeScene(sceneType)

Parameters

{number} sceneType SceneType value


It gets the current scene. Run the event in the "Battle Prep", and call this method during the event, it will be returned SceneType.EVENT.

{number} getCurrentScene()

Returns

{number} SceneType value


Get the base scene. Run the event in the "Battle Prep", and call this method during the event, it will be returned SceneType.BATTLESETUP.

{number} getBaseScene()

Returns

{number} SceneType value


It gets the number of backlog data.

{number} getBacklogCommandCount()

Returns

{number} The number of backlog data


Get the backlog data.

{BacklogCommand} getBacklogCommand(index)

Parameters

{number} index The index of backlog data

Returns

{BacklogCommand} Backlog data


If the event background is displayed true, otherwise it returns false.

{boolean} isEventBackgroundVisible()

Returns

{boolean} Boolean


Set the mouse position.

setMousePos(x, y)

Parameters

{number} x x-coordinate

{number} y y coordinate


Gets the x coordinate of the mouse.

{number} getMouseX()

Returns

{number} x-coordinate


Gets the y coordinate of the mouse.

{number} getMouseY()

Returns

{number} y coordinate


true if the specified value is input, otherwise it returns false.

{boolean} isMouseAction(value)

Parameters

{number} value MouseType value

Returns

{boolean} Boolean


true if the specified value is continuously input, otherwise it returns false.

{boolean} isMouseState(value)

Parameters

{number} value MouseType value

Returns

{boolean} Boolean


( This page is translated by google translation. )