Stop PC/NPC Movement

Jackkel Dragon

Veteran
Veteran
Joined
Oct 15, 2012
Messages
48
Reaction score
24
First Language
English
Primarily Uses
RMMV
Stop Movement v1
RPG Maker MV Plugin
Jackkel Dragon
Introduction
A simple plugin to allow the developer to stop PC/NPC movement based on switches. (PC movement by events can still be run while player movement is restricted.)

How to Use
- Copy the plugin code into a .js file and add it to your project's "js/plugins/" folder. (Be sure to use the name given in the code's header!)
- Load the plugin in RPG Maker MV's plugin manager for your project.
- Set the switches used to stop PC/NPC movement. Set to -1 for unused.

Updates
- v1: First release. November 9th, 2015.

Plugin Code
v1
Code:
//=============================================================================// StopMovement.js//=============================================================================/*: * @plugindesc Stops player/NPC movement based on switches. * @author Jackkel Dragon * * @param PC Switch ID * @desc The ID of the switch that stops player movement. * @default -1 * * @param NPC Switch ID * @desc The ID of the switch that stops NPC movement. * @default -1 * * @help This plugin does not provide plugin commands. */(function() {    var parameters = PluginManager.parameters('StopMovement');    var PCswitchId = Number(parameters['PC Switch ID'] || -1);    var NPCswitchId = Number(parameters['NPC Switch ID'] || -1);        var _Game_Player_moveByInput = Game_Player.prototype.moveByInput;    Game_Player.prototype.moveByInput = function() {        if ($gameSwitches.value(PCswitchId))            return;        _Game_Player_moveByInput.call(this);    }        var _Game_Event_updateSelfMovement = Game_Event.prototype.updateSelfMovement;    Game_Event.prototype.updateSelfMovement = function() {        if ($gameSwitches.value(NPCswitchId))            return;        _Game_Event_updateSelfMovement.call(this);    }})();
Credits
This plugin is essentially a remake of Yanfly's VXAce script "Stop All Movement". Credit for the original script/idea goes to Yanfly.

Terms
Free to use, even for commercial projects. Credit Yanfly in your game's credits.
 
Last edited by a moderator:

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
39,949
Reaction score
13,585
First Language
English
Primarily Uses
RMMV
Shouldn't credit go to Yanfly, for the original script that you ported? And therefore, terms should match Yanfly's terms & conditions.
 

Jackkel Dragon

Veteran
Veteran
Joined
Oct 15, 2012
Messages
48
Reaction score
24
First Language
English
Primarily Uses
RMMV
Edited the opening post a bit to make it more clear that Yanfly created the VXAce script I based this on.


@Shaz: Do you know if Yanfly's terms have changed? According to the old blog that I linked to, the only real change would be crediting Yanfly in the game's credits.
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
39,949
Reaction score
13,585
First Language
English
Primarily Uses
RMMV
I believe that's the requirement, yes. But your OP says "no credit required". It should say to credit Yanfly as per Yanfly's terms, even if you don't want credit for the port.
 
Last edited by a moderator:

Jackkel Dragon

Veteran
Veteran
Joined
Oct 15, 2012
Messages
48
Reaction score
24
First Language
English
Primarily Uses
RMMV
Went ahead and linked to Yanfly's terms page, just to be safe. Hopefully that works.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

The Ace attorney series are so great games... But at the same time such a travesty.
Made a video showcasing a plugin (by Lanza) that adds 5 more weather effects to our MV games. :LZYsmile: Namely:
Ash-dust,
bloodrain,
Cherry Blossom Petals,
Hail,
and bubbles.

I just like this website:
lol

Forum statistics

Threads
103,239
Messages
998,301
Members
134,729
Latest member
Takufy
Top