Documentation
Quick InfoVersion: Alpha R8
Made for RPG Maker MZ 1.9.0
The BasicsTo set an event up as a gathering node, make a comment event command that contains the following text: CGMZ GATHERING nodeId
For example, if your node id is "stone", your comment text would be: CGMZ GATHERING stone
Important: IDs for nodes should not contain spaces
Event CommandsThe gathering events can also run other event commands. However, the event commands will only run if the player can currently harvest the node. For example, if the player does not have the profession level, required tools, or if the node is not in a harvestable stage, interacting with the event will *NOT* run the event commands in the event.
ToolsEach node can be harvested by as many different "tool tiers" as you want, with some tiers giving bonus chances to gathering success rate. This plugin will always start at the *last* tool tier in the list you have configured, and work its way back to the beginning of the tool tier list until it finds a tool tier which the player has in their inventory.
If you wanted to make, for example, a bronze pickaxe that didn't give any bonus and an iron pickaxe that gave a 5% success rate bonus, set the bronze pickaxe tool to be first in the list and the iron pickaxe tool to be second in the list.
StagesNodes automatically grow to the next stage after the set amount of frames set up via the plugin parameters. For the last stage of growth, you should set the Growth Time to 0 so it is infinite until the player gathers the node.
Further, node stages must be marked as Mature to be gatherable. You can optionally have an expired stage which will award the expired items and apply the exp penalty when gathered. The expired stage still needs to be marked as mature, the expired flag only determines whether the gather will produce the expired items or the normal items.
AnimationsEach node (and stage within each node) supports its own animation or still image. To set up the animation, create an image with each frame of the animation being an equal width then set this width as the frame width. The animation system supports an unlimited number of frames and will cycle through them from frame 0 to the max frame where it will reset to frame 0. To set how much time (in frames) before switching to the next frame, use the Animation Delay parameter.
PlantingTo start planting, use the Start Planting plugin command. All you need to do is provide the type of plantable you want to be planted in that event. The plugin will handle displaying the window of the player's inventory with seeds that can be planted there, and turn it into a gathering node. There is no need for the gathering comment if it is a plantable event.
You can optionally use the script call:
this.CGMZ_getGatheringState() === 'none';
in a conditional branch in your event. The return will be "none" when it is not yet planted, and "growing" when it is already planted. This will allow you to event different actions depending on the state the event is in.
Text CodesThe gather success and fail text in toast windows supports all standard text codes, such as \c[x] or \i[x].
Some text parameters support additional text codes.
The param "Profession Fail Message" supports the following:
- %prof: will be replaced with the profession's name.
- %level: will be replaced with the required level.
FallbacksCertain parameters exist globally as well as for each node. These are:
- Success Sound Effect
- Fail Sound Effect
- Tool Fail Message
- Profession Fail Message
For the sound effects, any node-specific sound effects will be combined with the global sound effect parameters, and a random sound effect will be chosen from this combined list.
For the messages, any node-specific message will override the global message parameter for that node. It will fall back to the global message if the node has an empty message parameter for that message type.
IntegrationsThis plugin can integrate with [CGMZ] Professions to add features:
1) Profession level requirements to harvest nodes
2) Profession success bonus for higher level than required
3) Automatic exp awarded for profession upon successful gather
This plugin can integrate with [CGMZ] Toast Manager to add features:
1) Toast window on gather fail
2) Toast window on gather success
This plugin can integrate with [CGMZ] Rumble to add features:
1) Rumble on gather success
2) Rumble on gather failure
Plugin CommandsThis plugin supports the following plugin commands:
Advance Node Stage - Advance a node's stage by 1
Reset Node - Reset a gathering node
Get Node Stage - Store a node's stage in a variable
Advance Every Node - Advance every active node's stage by 1
Saved GamesThis plugin is fully compatible with saved games. This means you can:
✓ Add this plugin to a saved game and it will work as expected.
✓ Change any plugin params and changes will be reflected in saved games.
✓ Remove the plugin with no issue to save data.
Filename
The filename for this plugin MUST remain CGMZ_Gathering.js. This is what it comes as when downloaded. The filename is used to load parameters and execute plugin commands. If you change it, things will begin behaving incorrectly and your game will probably crash. Please do not rename the js file.
Known Issues
This plugin currently has no known issues that need to be fixed. If you believe you have encountered a bug, please report it to Casper Gaming.
Compatibility
These are conflicts with other MZ plugins that have already been reported to Casper Gaming and confirmed by Casper Gaming. Casper Gaming tries to keep these to a minimum, but it is not always possible to solve a conflict. If the conflicting plugin is obfuscated, Casper Gaming believes it is the other plugin author's responsibility to fix the conflict.
If any are marked as Partial, it means you can still use the two plugins together, but some features may not work as expected.
- (Partial) VisuStella Events and Movement Core
Version HistoryVersion AlphaR2
- Added Success and Fail sound effects when gather finishes
- Added per-node tool and profession fail messages
- Added option to change the message background for messages
- Added plugin command to advance every node's stage
- Fix bug preventing gather when node had no required tools
- Fix bug with event priority not updating when first loading node
- Fix crash that could occur when loading into saved map with growing node
- This plugin will now warn instead of crash when invalid JSON is detected
- Fixed a bug that could cause the player to appear above trees
- Fixed a bug with the variance amount being 1 less than the variance given
- Added expired property to growth stages
- Added expired property to item setup
- Added exp penalty setting for expired harvests
- Added option to advance every node stage by id
- Fixed a bug with which tool tier the plugin would attempt to use
- Fixed a bug when gather failed while not using [CGMZ] Professions
- Compatibility with VS Debugger plugin
- Added customization for the gathering progress window
- Added tracking for how many of each node type has been harvested
- Added [CGMZ] Rumble integration
- Fix bug with event priority not resetting after harvest
- Added ability to plant seeds that turn into gathering nodes
- Added start delay option to rumble parameters
- Added option to advance all nodes except for specific type
- Fix bug with manual advance of node not updating priority
- Success chance can now be negative and require boosts to gather
- Map ID parameters now use new MZ 1.9.0 map select ui
- Order with [CGMZ] Toast Manager no longer important
- Added instant gathering
- Added lots of gather progress window customization features
- Fix bug with planted gather node disappearing after map transfer
- Fix bug with plantable window weird interaction with map name window
- Start Planting plugin command no longer required to wrap in conditional
- Added gathering journal
- Added [CGMZ] Window Settings integration