Original Source
- Original title: PlayerShiftTurn (Turnaround)
- Original author: ovate
- Original date: November 28, 2018
- Source thread: https://forums.rpgmakerweb.com/threads/playershiftturn-turnaround.102688/
- Source forum path: Game Development Engines > RPG Maker Javascript Plugins > JS Plugin Releases (RMMV)
Summary
PlayerShiftTurn - Version 1.0.1 (2016/07/09) Creator name: Triacontane Overview Player can turnaround
Archived First Post
Creator name: Triacontane
Overview
Player can turnaround
Features
- While holding a certain key [shift by default], change direction of player's facing from arrow key.
- Parameter for KeyName control (shift or control or tab)
- Player does not have to move to face a direction.
Preview
Note: this does not support touch/ mouse control
Credit and Thanks: Triacontane
Terms of Use- Free for commercial and non-commercial use.
License - MIT License: http://opensource.org/licenses/mit-license.php
You can download js file from the thread attachment or Dropbox link: https://www.dropbox.com/s/7brx858kygswug0/PlayerShiftTurn.js?dl=1
//=============================================================================
// PlayerShiftTurn.js
// ----------------------------------------------------------------------------
// Copyright (c) 2015 Triacontane
// This software is released under the MIT License.
// http://opensource.org/licenses/mit-license.php
// ----------------------------------------------------------------------------
// Version
// 1.0.1 2016/07/09 Fixed an issue with 8 direction (diagonal) movement plugin
// 1.0.0 2016/01/06 First release
// ----------------------------------------------------------------------------
// [Blog] : http://triacontane.blogspot.jp/
// [Twitter]: https://twitter.com/triacontane/
// [GitHub] : https://github.com/triacontane/
//=============================================================================
/*:
* @plugindesc Player can turnaround
* @author Triacontane
*
* @param KeyName
* @desc Holding a certain key, change direction of player's facing from arrow key.
* (shift or control or tab)
* @default shift
*
* @help Player does not have to move to face a direction.
* Holding a key and press arrow key will change direction where the player facing.
*
* Terms of Service:
* It's possible to modify and redistribute without permission from the author.
* And this plugin licensed under MIT License.
*/
(function () {
'use strict';
var pluginName = 'PlayerShiftTurn';
var getParamString = function(paramNames) {
var value = getParamOther(paramNames);
return value == null ? '' : value;
};
var getParamOther = function(paramNames) {
if (!Array.isArray(paramNames)) paramNames = [paramNames];
for (var i = 0; i < paramNames.length; i++) {
var name = PluginManager.parameters(pluginName)[paramNames[i]];
if (name) return name;
}
return null;
};
//=============================================================================
// Parameter formatting
//=============================================================================
var paramButtonName = getParamString(['KeyName', 'ボタン名称']).toLowerCase();
//=============================================================================
// Game_Player
// Holding a specified key, changes the direction without moving the player.
//=============================================================================
var _Game_Player_executeMove = Game_Player.prototype.executeMove;
Game_Player.prototype.executeMove = function(direction) {
if (Input.isPressed(paramButtonName)) {
if (direction === Input.dir4) {
this.setDirection(direction);
}
} else {
_Game_Player_executeMove.apply(this, arguments);
}
};
})();
Features Mentioned
- While holding a certain key [shift by default], change direction of player's facing from arrow key.
- Parameter for KeyName control (shift or control or tab)
- Player does not have to move to face a direction.
- Preview
- "lightbox_close": "Close",
- "lightbox_next": "Next",
- "lightbox_previous": "Previous",
- "lightbox_error": "The requested content cannot be loaded. Please try again later.",
- "lightbox_start_slideshow": "Start slideshow",
- "lightbox_stop_slideshow": "Stop slideshow",
- "lightbox_full_screen": "Full screen",
- "lightbox_thumbnails": "Thumbnails",
- "lightbox_download": "Download",
- "lightbox_share": "Share",
- "lightbox_zoom": "Zoom",
- "lightbox_new_window": "New window",
- "lightbox_toggle_sidebar": "Toggle sidebar"
- Note: this does not support touch/ mouse control
Downloads / Referenced Files
Log in, then follow the RPG Maker Developers Group to see these download links.
Log in to downloadLicense / Terms Note
Credit and Thanks: Triacontane Terms of Use- Free for commercial and non-commercial use. License - MIT License: http://opensource.org/licenses/mit-license.php You can download js file from the thread attachment or Dropbox link: https://www.dropbox.com/s/7brx858kygswug0/PlayerShiftTurn.js?dl=1
Creator 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.
Topic Summary
Loading summary...