Preserved forum archive. This topic stores the original first post and locally mirrored RPG Maker Web attachments when available. It is posted by the BMMPlay archive account, not by the original creator.
Original Source
- Original title: How do I give a plugin command within a script?
- Original author: MrSlippery
- Original date: November 5, 2023
- Source thread: https://forums.rpgmakerweb.com/threads/how-do-i-give-a-plugin-command-within-a-script.162676/
- Source forum path: Game Development Engines > Legacy Engine Support > RPG Maker MV Support
Summary
Hello, I apologize for all of the questions lately. I tried finding the answer to this on my own, but didn't have much luck. I looked in the "RPG Maker MV Script Call List" () but couldn't really understand what I was looking at... I just want to know how to use a "plugin command" in a script.
Archived First Post
Hello,
I apologize for all of the questions lately. I tried finding the answer to this on my own, but didn't have much luck.
I looked in the "RPG Maker MV Script Call List" () but couldn't really understand what I was looking at...
I just want to know how to use a "plugin command" in a script.
Earlier, ATT was kind enough to help me with a script to stop my screen from shaking when I get attacked:
Game_Actor.prototype.performDamage = function() {
Game_Battler.prototype.performDamage.call(this);
if (this.isSpriteVisible()) {
this.requestMotion('damage');
} /*else {
$gameScreen.startShake(5, 5, 10);
}*/
SoundManager.playActorDamage();
};
Then, I found the RMMV - Screen Shake plugin (https://theoallen.itch.io/rmmv-screenshake) from Theo that lets you shake the entire screen with the call, for example, Shake 10 45.
How can I use this "Shake 10 45" plugin command in the script that ATT gave me?
Currently, now when I get hit, thanks to ATT's script, the screen no longer shakes, but if I wanted it to shake, I would try something like this:
Game_Actor.prototype.performDamage = function() {
Game_Battler.prototype.performDamage.call(this);
if (this.isSpriteVisible()) {
this.requestMotion('damage');
} else {
ShakeScreen.pluginCommand(10, 45);
}
SoundManager.playActorDamage();
};
This results in a ReferenceError saying that "shakeScreen" is not defined.
So, how can I access the ShakeScreen script and call a command from it within another script?
Any help would be appreciated.
I apologize for all of the questions lately. I tried finding the answer to this on my own, but didn't have much luck.
I looked in the "RPG Maker MV Script Call List" () but couldn't really understand what I was looking at...
I just want to know how to use a "plugin command" in a script.
Earlier, ATT was kind enough to help me with a script to stop my screen from shaking when I get attacked:
Game_Actor.prototype.performDamage = function() {
Game_Battler.prototype.performDamage.call(this);
if (this.isSpriteVisible()) {
this.requestMotion('damage');
} /*else {
$gameScreen.startShake(5, 5, 10);
}*/
SoundManager.playActorDamage();
};
Then, I found the RMMV - Screen Shake plugin (https://theoallen.itch.io/rmmv-screenshake) from Theo that lets you shake the entire screen with the call, for example, Shake 10 45.
How can I use this "Shake 10 45" plugin command in the script that ATT gave me?
Currently, now when I get hit, thanks to ATT's script, the screen no longer shakes, but if I wanted it to shake, I would try something like this:
Game_Actor.prototype.performDamage = function() {
Game_Battler.prototype.performDamage.call(this);
if (this.isSpriteVisible()) {
this.requestMotion('damage');
} else {
ShakeScreen.pluginCommand(10, 45);
}
SoundManager.playActorDamage();
};
This results in a ReferenceError saying that "shakeScreen" is not defined.
So, how can I access the ShakeScreen script and call a command from it within another script?
Any help would be appreciated.
Downloads / Referenced Files
Log in to download
Log in, then follow the RPG Maker Developers Group to see these download links.
Log in to downloadCreator Claims / Removal
If you are the original creator and want this listing reassigned, edited, or removed, join BMMPlay and contact the moderators with proof that matches the original RPG Maker Web profile, linked GitHub, itch.io page, or another public creator identity.
Replies (0)
No replies yet.
0
replies
1
view
Topic Summary
Loading summary...