Tile Grafter System VisuStella MZ

From Yanfly.moe Wiki
Jump to navigation Jump to search

Welcome to the wiki! This is where you can find resources from Yanfly.moe, Ækashics.moe,
VisuStella, Caz Wolf, Fallen Angel Olivia, Atelier Irina, and other affiliated content creators.



Download

System

This is a plugin created for RPG Maker MZ.

InstallPluginsMz.png

UpdatePlugins.png

Troubleshooting.jpg

Click here for help on how to install plugins and an explanation on the Tier Hierarchy System.

Click here to learn how to update plugins.

Click here for how to troubleshoot plugins if you get an error.


Masterarbeit Writer


TileGrafterSystem Preview1.gif

TileGrafterSystem Preview2.gif

TileGrafterSystem Preview3.gif

TileGrafterSystem Preview4.gif

Required Plugins

The following plugins are required in order to use this plugin.

Place the following plugins above this plugin located in the Plugin Manager.


VisuStella MZ

This plugin is a part of the VisuStella MZ Plugin Library.

Click here if you want to help support VisuStella on Patreon.

Introduction

Ever wanted to insert tiles onto one map from another in-game? And have them retain those changes? The Tile Grafter System allows for exactly that, so that you can make HUB-like maps containing evolving architecture overtime without the need to make lots of map variants. Take them exactly or by certain tile layers only.

Features include all (but not limited to) the following:

  • Tiles from one map can be inserted into another map via Plugin Commands in the form of tile grafting.
  • These tiles can be inserted exactly or layer by layer depending on how you configure the Plugin Commands.
  • Returning to maps with changed tiles will have their changes retained.
  • Don't want these changes to be permanent? You can revert them or clean them up even.
  • Grafting tiles can optionally work with autotiles as well.
  • Insert shadows and even alter region IDs as well.
  • If allowed, events from the source map can be grafted into the current map as preserved spawned events. Likewise, those spawned events can be removed when cleared or reverted.


Requirements

This plugin is made for RPG Maker MZ. This will not work in other iterations of RPG Maker.

Required Plugin List

This plugin requires the above listed plugins to be installed inside your game's Plugin Manager list in order to work. You cannot start your game with this plugin enabled without the listed plugins.


Tier 2

This plugin is a Tier 2 plugin. Place it under other plugins of lower tier value on your Plugin Manager list (ie: 0, 1, 2, 3, 4, 5).

This is to ensure that your plugins will have the best compatibility with the rest of the VisuStella MZ Plugin library.



Major Changes

This plugin adds some new hard-coded features to RPG Maker MZ's functions. The following is a list of them.

---

Map Tileset Data

TileGrafterSystem Preview1.gif

Tile Grafting will change up the tile data found present in the current map. As a result, $dataMap.data will have its values changed and adjusted appropriately to reflect the new changes made. This means that map collision and the like will be changed, too.

When grafting, the tiles that will be imported from the source map will be changed to whatever the current map's tileset is. This means that you CANNOT use a different tilemap on a source map and expect it to remain the same when inserting into the current map. Instead, it will convert whatever tiles are being used into the current map's tileset instead.

Upon leaving and returning to the map, the tile data will remain changed until reverted by a Plugin Command.

  • NOTE* When grafting from a source map for the first time, the game will

need to load said map. This may cause the game to wait a few frames before continuing. Therefore, it's best to preload these source maps if possible using the Plugin Commands.

---

Autotiles

TileGrafterSystem Preview2.gif

If you decide to graft using autotiles, autotiles will be applied slightly differently than how they're done in the RPG Maker MZ editor in order to preserve more of the game map. This is done INTENTIONALLY and is not a bug.

Autotiles will only affect their own tiles and not surrounding tiles that aren't matching. In the editor, some road tiles will connect to one another regardless if they're the same type. That does not happen here in order to make more sense in the context of the game.

When grafting an autotile to a coordinate, it will affect matching autotile types in the surrounding 8 tiles, too. This is to make sure that all of the pieces will connect properly.

---

Grafted Events

TileGrafterSystem Preview4.gif

If you allow grafting the event layer (L7: Events), you can spawn any matching events from the source map as long as the locations coincide. These events will be spawned into the map as preserved spawns.

When importing, if there are any normal events already existing on the grafting target location, they will be preserved in order to prevent a map desynchronization. Keep this in mind as you prepare for spawning. On the flip side, if there are any spawned events already existing on the target location, they will be despawned.

If you want to make sure there are no events in the grafting target area before applying the grafting, use the

When using the Clear and Revert Plugin Commands, currently existing spawned events (if the L7: Events layer is affected) will be removed from the target location. Both Clear and Revert function the same for the L7: Events layer.

Clear and Revert will NOT remove any already existing normal events from the target location in order to ensure the game map does not desync. However, it will remove any spawned events that may have wandered into the area. Due to this clearing process, the "Revert" function will NOT restore any spawned events that may have been removed through grafting. Keep this in mind.

---


VisuStella MZ Compatibility

While this plugin is compatible with the majority of the VisuStella MZ plugin library, it is not compatible with specific plugins or specific features. This section will highlight the main plugins/features that will not be compatible with this plugin or put focus on how the make certain features compatible.

---

Lighting Effects VisuStella MZ

The VisuStella MZ Lighting Effects plugin has "Anti-Light" and "Auto-Light" functions tied to region IDs. If these regions match a grafted tile's region then the map will fade out and fade back in to properly show the newly added "Anti-Light" and "Auto-Light" effects.

---

Visual Fogs VisuStella MZ

The VisuStella MZ Visual Fogs plugin has fogs that can be applied to only certain regions on the map. If these regions match a grafted tile's region, then the map will fade out and fade back in to properly show the fog being applied to that region.

---

Visual Parallaxes VisuStella MZ

The VisuStella MZ Visual Parallaxes plugin has water reflections that can be applied to only certain regions on the map. If these regions match a grafted tile's region, then the map will fade out and fade back in to properly show the parallax reflection being applied to that region.

---

TileD VisuStella MZ

This plugin does not work with TileD.

---


Plugin Commands

PluginCommandsMZ.png

Plugin Commands are event commands that are used to call upon functions added by a plugin that aren't inherently a part of RPG Maker MZ.

Here is a list of Plugin Command(s) that you may use:

---


The following are Plugin Commands that come with this plugin. They can be accessed through the Plugin Command event command.

---

Graft Plugin Commands

TileGrafterSystem Preview1.gif

---

TileGrafterSystem Command1.png

Graft: Import Tiles Exactly
- Import and graft exact tiles from source map to current map.
- Must be used on the map scene!

  Source Map ID:
  - Insert the number of the map. Use 0 for current map.
  - You can use JavaScript code.

    Source X:
    - Insert source map's X location to start importing from.
    - You can use JavaScript code.

    Source Y:
    - Insert source map's Y location to start importing from.
    - You can use JavaScript code.

  Current Map:

    Target X:
    - Insert current map's X location to import to.
    - You can use JavaScript code.

    Target Y:
    - Insert current map's Y location to import to.
    - You can use JavaScript code.

    Width:
    - What is the width of the area to import?
    - You can use JavaScript code.

    Height:
    - What is the height of the area to import?
    - You can use JavaScript code.

  Import Layers:

    L1: Ground:
    - Utilize this layer? This is the ground layer.

    L2: Lower:
    - Utilize this layer? This is the lower layer.

    L3: Middle:
    - Utilize this layer? This is the middle layer.

    L4: Upper:
    - Utilize this layer? This is the upper layer.

    L5: Shadow:
    - Utilize this layer? This is the shadow layer.

    L6: Region:
    - Utilize this layer? This is the region layer.

    L7: Events:
    - Utilize this layer? This is the events layer.
    - Existing spawned events will be cleared before grafting.

---

TileGrafterSystem Command2.png

Graft: Import Tiles with Autotile
- Import and graft with autotiles from source map to current map.
- Must be used on the map scene!

  Source Map ID:
  - Insert the number of the map. Use 0 for current map.
  - You can use JavaScript code.

    Source X:
    - Insert source map's X location to start importing from.
    - You can use JavaScript code.

    Source Y:
    - Insert source map's Y location to start importing from.
    - You can use JavaScript code.

  Current Map:

    Target X:
    - Insert current map's X location to import to.
    - You can use JavaScript code.

    Target Y:
    - Insert current map's Y location to import to.
    - You can use JavaScript code.

    Width:
    - What is the width of the area to import?
    - You can use JavaScript code.

    Height:
    - What is the height of the area to import?
    - You can use JavaScript code.

  Import Layers:

    L1: Ground:
    - Utilize this layer? This is the ground layer.

    L2: Lower:
    - Utilize this layer? This is the lower layer.

    L3: Middle:
    - Utilize this layer? This is the middle layer.

    L4: Upper:
    - Utilize this layer? This is the upper layer.

    L5: Shadow:
    - Utilize this layer? This is the shadow layer.

    L6: Region:
    - Utilize this layer? This is the region layer.

    L7: Events:
    - Utilize this layer? This is the events layer.
    - Existing spawned events will be cleared before grafting.

---

Preload Plugin Commands

TileGrafterSystem Preview2.gif

---

TileGrafterSystem Command3.png

Preload: Preload Source Map
- Preload a source map to use for grafting.
- Must be used on the map scene!

  Source Map ID:
  - Insert the number of the map.
  - You can use JavaScript code.

---

Restore Plugin Commands

TileGrafterSystem Preview3.gif

---

TileGrafterSystem Command4.png

Restore: Clear Tiles for Map
- Clears tiles on current map to empty tiles.
- Must be used on the map scene!

  Current Map:

    Target X:
    - Insert current map's X location to start clearing.
    - You can use JavaScript code.

    Target Y:
    - Insert current map's Y location to start clearing.
    - You can use JavaScript code.

    Width:
    - What is the width of the area to clear?
    - You can use JavaScript code.

    Height:
    - What is the height of the area to clear?
    - You can use JavaScript code.

  Clear Layers:

    L1: Ground:
    - Utilize this layer? This is the ground layer.

    L2: Lower:
    - Utilize this layer? This is the lower layer.

    L3: Middle:
    - Utilize this layer? This is the middle layer.

    L4: Upper:
    - Utilize this layer? This is the upper layer.

    L5: Shadow:
    - Utilize this layer? This is the shadow layer.

    L6: Region:
    - Utilize this layer? This is the region layer.

    L7: Events:
    - Utilize this layer? This is the events layer.
    - Existing spawned events will be cleared.

---

TileGrafterSystem Command5.png

Restore: Revert Tiles for Map
- Revert tiles on current map to their original tiles.
- Must be used on the map scene!

  Current Map:

    Target X:
    - Insert current map's X location to start reverting.
    - You can use JavaScript code.

    Target Y:
    - Insert current map's Y location to start reverting.
    - You can use JavaScript code.

    Width:
    - What is the width of the area to revert?
    - You can use JavaScript code.

    Height:
    - What is the height of the area to revert?
    - You can use JavaScript code.

  Revert Layers:

    L1: Ground:
    - Utilize this layer? This is the ground layer.

    L2: Lower:
    - Utilize this layer? This is the lower layer.

    L3: Middle:
    - Utilize this layer? This is the middle layer.

    L4: Upper:
    - Utilize this layer? This is the upper layer.

    L5: Shadow:
    - Utilize this layer? This is the shadow layer.

    L6: Region:
    - Utilize this layer? This is the region layer.

    L7: Events:
    - Utilize this layer? This is the events layer.
    - Existing spawned events will be cleared.

---

Switch Plugin Commands

TileGrafterSystem Preview4.gif

---

TileGrafterSystem Command6.png

Switches: Check for Events in Area
- Checks area for any events of various types.
- Must be used on the map scene!

  Switches

    ID for Normal Events:
    - This switch will turn ON if any normal events are found within the
      target area vicinity.
    - OFF otherwise.

    ID for Non-Graft Spawns:
    - This switch will turn ON if any non-grafted spawned events are found
      within the target area vicinity.
    - OFF otherwise.

    ID for Grafted Spawns:
    - This switch will turn ON if any grafted spawned events are found
      within the target area vicinity.
    - OFF otherwise.

  Target Checked Area

    Target X:
    - Insert current map's X location to check.
    - You can use JavaScript code.

    Target Y:
    - Insert current map's Y location to check.
    - You can use JavaScript code.

    Width:
    - What is the width of the area to check?
    - You can use JavaScript code.

    Height:
    - What is the height of the area to check?
    - You can use JavaScript code.

---


Plugin Parameters

General Settings

TileGrafterSystem Preview3.gif

There's a single Plugin Parameter that can be adjusted here.

---

TileGrafterSystem Param1.png

Parameters

 Nonmatch Tileset Warning:
 - Turn on warnings when using nonmatching tileset IDs.
 - This is because when grafting, the tiles that will be imported from the
   source map will be changed to whatever the current map's tileset is.
 - This means that you CANNOT use a different tilemap on a source map and
   expect it to remain the same when inserting into the current map.
 - Instead, it will convert whatever tiles are being used into the current
   map's tileset instead.

---



Terms of Use

1. These plugins may be used in free or commercial games provided that they have been acquired through legitimate means at VisuStella.com and/or any other official approved VisuStella sources. Exceptions and special circumstances that may prohibit usage will be listed on VisuStella.com.

2. All of the listed coders found in the Credits section of this plugin must be given credit in your games or credited as a collective under the name: "VisuStella".

3. You may edit the source code to suit your needs, so long as you do not claim the source code belongs to you. VisuStella also does not take responsibility for the plugin if any changes have been made to the plugin's code, nor does VisuStella take responsibility for user-provided custom code used for custom control effects including advanced JavaScript notetags and/or plugin parameters that allow custom JavaScript code.

4. You may NOT redistribute these plugins nor take code from this plugin to use as your own. These plugins and their code are only to be downloaded from VisuStella.com and other official/approved VisuStella sources. A list of official/approved sources can also be found on VisuStella.com.

5. VisuStella is not responsible for problems found in your game due to unintended usage, incompatibility problems with plugins outside of the VisuStella MZ library, plugin versions that aren't up to date, nor responsible for the proper working of compatibility patches made by any third parties. VisuStella is not responsible for errors caused by any user-provided custom code used for custom control effects including advanced JavaScript notetags and/or plugin parameters that allow JavaScript code.

6. If a compatibility patch needs to be made through a third party that is unaffiliated with VisuStella that involves using code from the VisuStella MZ library, contact must be made with a member from VisuStella and have it approved. The patch would be placed on VisuStella.com as a free download to the public. Such patches cannot be sold for monetary gain, including commissions, crowdfunding, and/or donations.

7. If this VisuStella MZ plugin is a paid product, all project team members must purchase their own individual copies of the paid product if they are to use it. Usage includes working on related game mechanics, managing related code, and/or using related Plugin Commands and features. Redistribution of the plugin and/or its code to other members of the team is NOT allowed unless they own the plugin itself as that conflicts with Article 4.

8. Any extensions and/or addendums made to this plugin's Terms of Use can be found on VisuStella.com and must be followed.

Terms of Use: Japanese


『VisuStella MZ』利用規約

1. これらのプラグインは、VisuStella.comおよび/または公式に承認されたVisuStellaのソースから合法的な手段で入手したものである限り、フリーゲームや商用ゲームに使用することができます。例外的に使用が禁止される場合については、VisuStella.comの記載をご確認ください。

2. 本プラグインの「クレジット」部分に記載されているすべてのコーダーの名前は、ゲーム内にクレジット表記を行うか、もしくは「VisuStella」という名前の下にまとめて表記する必要があります。

3. ソースコードを自分のものだと主張しない限りは、必要に応じて編集することが可能です。ただしプラグインのコードに変更が加えられた場合、VisuStellaはそのプラグインに対して一切の責任を負いません。高度なJavaScriptのノートタグやJavaScriptコードを許可するプラグインのパラメータを含む、カスタムコントロールエフェクトに使用される、ユーザー提供のカスタムコードについても、VisuStellaは一切の責任を負いません。

4. これらのプラグインやプラグイン内のコードを、「自分のもの」として再配布したり使用したりすることはできません。これらのプラグインとそのコードは、VisuStella.comおよび、その他の公式/承認済みVisuStellaソースからのみダウンロードすることができます。公式/承認済みのソースのリストは、VisuStella.comでご確認いただけます。

5. VisuStellaは、意図しない使用方法による問題、VisuStella MZライブラリ以外のプラグインとの非互換性の問題、プラグインのバージョンが最新でないことによる問題、第三者による互換性パッチが適切に動作していないことなどが原因でゲーム内で発生した問題については、一切の責任を負いません。VisuStellaは、高度なJavaScriptのノートタグやJavaScriptコードを許可するプラグインのパラメータを含む、カスタムコントロールエフェクトに使用される、ユーザー提供のカスタムコードに起因するエラーについても、一切の責任を負いません。

6. VisuStella MZライブラリのコードを使用した互換性パッチをVisuStellaとは関係のない第三者を通じて作成する必要がある場合は、まずVisuStellaのメンバーと連絡を取り、承認を得る必要があります。パッチはVisuStella.comに公開され、誰でも無料でダウンロードすることができるようになります。このようなパッチを、制作発注やクラウドファンディングの対象にしたり、寄付などの金銭的な利益を得るために販売することはできません。

7. このVisuStella MZプラグインが商用製品である場合、プロジェクトチームのすべてのメンバーは、それを使用するため、それぞれ製品を購入しなければなりません。使用方法には、関連するゲームメカニクスの作業、関連するコードの管理、および/または関連するプラグインコマンドや機能の使用、が含まれます。プラグインそのものやそのコードをチームの他のメンバーに再配布することは第4項に抵触するため、そのメンバーがプラグインそのものを所有していない限りは許可されません。

8. このプラグインの利用規約の追加項目や補足については、VisuStella.comに掲載されていますので、それを参照し従ってください。


Credits

If you are using this plugin, credit the following people in your game:

Team VisuStella


Changelog

Version 1.02: August 29, 2024

  • Compatibility Update!
    • Added compatibility for Core Engine's version 1.84 new notetag: Taller by x: id.


Version 1.01: February 15, 2024

  • Bug Fixes!
    • Fixed a function clash with the Save Core. Fix made by Olivia.


Version 1.00 Official Release Date: February 23, 2024

  • Finished Plugin!

See Also


End of Helpfile