PluginName: SDJB_EnhancedWaitOptions Author: ShadowDragon Spoiler: How it works Code:
PluginName: SDJB_EnhancedWaitOptions
Author: ShadowDragon
Code:
Introduction
Íž Íž Íž Íž Íž Íž Íž Íž Íž Íž Íž Íž
Enhanced Wait Options to use plugins commands or scriptcalls
to use inside plugins or in the editor in various ways to
simplify your needs.
Plugin Commands
Íž Íž Íž Íž Íž Íž Íž Íž Íž Íž Íž Íž Íž Íž Íž
Wait 180 Frames
Wait 3 Second (or Seconds)
Wait 1 Minute (or minutes)
Wait For Route => Waits for all movement routes
Wait For Animation => Waits for all animations
Wait For Balloon => Waits for all balloon animations
Wait For Message => Waits for all messages (Best in parallel)
Wait For Transfer => Waits for map transfer
Wait For Scroll => Waits for scrolling
Wait For Gather => Waits for all followers to gather
Wait For Action => Waits for battle action
Wait For Video => Waits for all video's
Wait For Image => Waits for images to load
Wait For SE => Waits for all Sound Effects
Wait For ME => Waits for all Music Effects
Wait For Condition => Waits for custom condition
Cancel Wait => Cancels any active wait or condition
Example: Wait For Condition <condition>
Wait For Condition $gameVariables.value(3) > 5
Wait For Condition Input.isTriggered("cancel")
Script Calls
Íž Íž Íž Íž Íž Íž Íž Íž Íž Íž Íž Íž
There are 3 kinds of scriptcalls available that can be
used inside events, common events or in plugins.
waitFor(value, unit);
waitForCond(condition);
cancelWait();
The Scriptcall "waitFor(value, unit)" can be used for
a duration of time as follows: (like 3 seconds)
waitFor(180);
waitFor(180, "frames")
waitFor("180 frames")
waitFor(3, "second");
waitFor(3, "seconds");
waitFor("3 second");
waitFor("3 seconds");
The rest of the waitFor(value) are like plugin commands
waitFor("route");
waitFor("animation");
waitFor("balloon");
waitFor("message");
waitFor("transfer");
waitFor("scroll");
waitFor("gather");
waitFor("action");
waitFor("video");
waitFor("image");
waitFor("se");
waitFor("me");
For the Scriptcall "waitForCond(condition)",
condition must be in quotes:
waitForCond("Input.isTriggered('cancel')");
waitForCond("$gameSwitches.value(5)");
waitForCond("$gameVariables.value(3) > 5");
For the Scriptcall "cancelWait()" inside plugins
setTimeout(() => cancelWait(), 3000);
or
setTimeout(cancelWait, 3000);
This eliminate the conditions or timer after 3 seconds.
PS:
SRD_WaitOptions had some issues, so its a mostly rewrite with extra defensive layer and extra
feature for scriptcalls to make it even more powerful.
I had this for a while making my side game, where I needed it a lot when I encounter problems.
So it has some heavy rewrites to make it work as it should and optimized for extension.
===
TERMS OF USE ===
Free for Non-Commercial and Commercial use when credit is given.
credit one of the following:
ShadowDragon
ShadowDragonJB
===
WARNING ===
YOU ARE NOT ALLOWED TO:
* MODIFY without permission
* EXTEND without permission
* TAKE CODE without permission
* CLAIM AS YOU MADE IT
* REDISTRIBUTE but link back to the forum or itch.io
* SELL this product as standalone.
* DO NOT REMOVE THE HEADER.
(file is below as it require my base plugin (
SDJB_Base or SDJB_BaseMZ (minified version))
Download from
itch.io
=== TERMS OF USE === Free for Non-Commercial and Commercial use when credit is given. credit one of the following: ShadowDragon