An open library of RPG Maker MZ plugins, powered by the community.

PGMZ - The Community-Driven Plugin Library for RPG Maker MZ

MZ plugins

MNKR DP Map Zoom MZ - MNKR_DP_MapZoomMZ.js

Plugin desc : Controls the magnification of the map.

License : MIT License

Author : munokura

Website : http://x.com/munokura

Desc page : https://raw.githubusercontent.com/munokura/MNKR-MZ-plugins/master/MNKR_DP_MapZoomMZ.js

File name : MNKR_DP_MapZoomMZ.js

Help of plugin :

@target MZ
@url https://raw.githubusercontent.com/munokura/MNKR-MZ-plugins/master/MNKR_DP_MapZoomMZ.js
@plugindesc Controls the magnification of the map.
@author munokura
@license MIT License

@help
============================================================================
About
========================================================================
This controls the map scene’s magnification by reflecting the magnification
calculations in various coordinate processing.
It also specifies that the camera should follow specified events.
The default focus target is the leading player.

============================================================================
Knowing issue
==========================================================================================
When zooming in too small on a large map,
processing slows down in canvas mode and causes map clipping issues in WebGL
mode.
This is a limitation of the PIXI library, and we are currently investigating a
solution.

==================================================================================
How To Use
= ... ◆ Plugin Commands

(1) Zoom Function
dpZoom {Zoom factor} {Number of frames to change} {Target event ID / this /
player}
Changes the screen magnification while focusing on the specified event.
If the third argument is empty, the zoom will be centered on the screen.

Example:
In the plugin command, specifying ”this” or ”this event” in the target event
section
specifies the object currently executing the event.
dpZoom 2 360 this
For example, the above command doubles the zoom factor over 6 seconds,
centering the event.
<Deprecated> mapSetZoom is supported but deprecated.

(2) Focus Function
dpFocus {Target event ID / this / player} {Number of frames to change}
Focus on the specified event without changing the screen magnification.

==============================================================================
Settings
========================================================================
Base Scale
Specifies the initial zoom level at the start of the game.
Set a zoom level of 0 or higher.

Encount Effect
Specifies whether to replace the encounter effect.
Set this to false if you are replacing it with the original effect.
In that case, you will need to adjust the screen zoom level accordingly.

Camera Control
If false, camera control during zoom, including event-specific zoom, will not
function.
Use this when controlling the camera with another plugin.

Weather Patch
If true, this will correct the weather sprite generation range,
distributing weather sprites evenly even after changing the zoom ratio.
Set this to false if you are controlling weather effects with another plugin.

Picture Size Fixation
If true, the picture will be excluded from the zoom process.

Old Focus
If true, this will perform focus processing similar to the old DP_MapZoom.js.
This focus processing is based on the coordinate deviation to the target
event,
so it does not track the movement of the event.

Easing Function
You can set an expression that returns the easing effect when zooming, mainly
between 0 and 1.
The argument t represents the zoom progress, between 0 and 1. JavaScript.

==============================================================================
Technical information
======================================================================================
The current screen zoom ratio can be obtained using $gameScreen.zoomScale().
This is a built-in function regardless of whether a plugin is used.
If the ”screenX” or ”screenY” used by another plugin is incorrect,
multiply ”screenX” and ”screenY” by $gameScreen.zoomScale() respectively.

This plugin controls $gameScreen.

The specified zoom setting is stored in $gameMap._dp_scale.
The scroll amount when leaving a scene is stored in $gameMap._dp_pan.
Map focus events are stored in $gameMap._dp_target.

# Contact Information
This is a plugin originally created for RPG Maker MV ported for MZ.
Please contact the modifier for any inquiries.

# Terms of Use
MIT License.
http://opensource.org/licenses/mit-license.php
You may modify and redistribute this without permission from the author, and
there are no restrictions on its use (commercial, 18+, etc.).

@param Base Scale
@text Basic Magnification
@desc Set the basic magnification ratio (0 or more).
@default 1

@param Encount Effect
@text Encounter effect reflected
@desc Encounter effects now reflect magnification
@type boolean
@default true

@param Camera Controll
@text Centering control during enlargement processing
@desc This plugin controls centering during enlargement processing.
@type select
@default true
@option ON
@value true
@option OFF
@value false
@option Minimum
@value minimum

@param Weather Patch
@text Weather sprite generation range
@desc Applies a fix to increase the range of weather sprite generation.
@type boolean
@default true

@param Picture Size Fixation
@text Picture Exclusion
@desc Select pictures to exclude from map zoom processing.
@type select
@default true
@option Enlarge all pictures
@value false
@option Exclude All Pictures
@value true
@option $ excludes pictures at the beginning of the file name
@value $
@option Exclude pictures with screen_ at the beginning of the file name
@value screen_
@option fix_ excludes pictures at the beginning of filenames
@value fix_

@param Old Focus
@text Use focus without tracking
@desc Uses the older version of focus without tracking.
@type boolean
@default false

@param Easing Function
@text Animation Easing Formula
@desc The easing formula for the animation.
@type string
@default t

@command dpZoom
@text Change the screen magnification
@desc You can change the screen magnification while keeping the focus on the specified event.
@arg focusScale
@text magnification
@desc Screen magnification
@default 1
@arg focusFlame
@text Number of frames
@desc Number of frames to change
@default 1
@arg focusTarget
@text subject
@desc Zoom target
@type combo
@default this
@option this
@option player

@command dpFocus
@text Focus on the subject
@desc Focuses on the specified event without changing the screen magnification.
@arg focusTarget
@text subject
@desc Focus target
@type combo
@default this
@option this
@option player
@arg focusFlame
@text Number of frames
@desc Number of frames to change
@default 1

スポンサードリンク

-MZ plugins

Copyright© PGMZ - The Community-Driven Plugin Library for RPG Maker MZ , 2026 All Rights Reserved.