- Joined
- Nov 5, 2015
- Messages
- 4
- Reaction score
- 4
- First Language
- English
Introduction
If you've ever played a game like Golden Sun, you might be familiar with the concept of unleash skills. This script allows you to give weapons and skills a chance to activate a different skill in its place when used.
Features
- Allows you to specify one or more skills that can activate when using a weapon or skill.
- The chance of activation can be affected by the user's luck.
- You can create your own formula for calculating how luck (or other attributes!) affect activation chance.
How to Use
In the notes of a weapon or skill, you can specify one or more skills that have a chance of activating using the following notetag format:
<unleash: id, chance>
Where id is the id of the skill, and chance is the percent chance of it activating. For instance, <unleash: 10, 50> on a weapon would mean that there is a 50% chance of activating skill 10 in place of making a normal attack.
If you specify more than one skill, then the unleash skills are checked in order until one succeeds (or if none do, then the normal attack / skill is used instead). When making a normal attack, unleash skills for each weapon are checked (in the order that they are equipped).
Luck Factor
If you want luck to play a role in determining how often an unleash skill activates, you can instead use the following notetag format:
<unleash: id, chance, difficulty>
Where difficulty is an integer used in the following relative difference formula below:
activation_chance = base_chance * (1 + (luck - difficulty) / (luck + difficulty))
Custom Luck Factor
If you would like to use your own formula for calculating how luck affects unleash chance, you can use the Luck Eval parameter to evaluate it. The following variables might be useful to you when doing so:
user: refers to the actor using the unleash skill. You can access attributes such as user.luk from this.
diff: the difficulty of the unleash skill (0 if none is given in the notetag)
chance: the base chance of activating the skill (represented as a fraction).
Note that your final evaluated chance should probably be between 0 and 1 (where 0.0 = 0%, 0.5 = 50%, etc.).
As an example, you could enter the following in Luck Eval:
chance + user.luk * 0.01 - diff * 0.01
This would increase the base chance by 1% per point of luck, minus 1% per point of difficulty that the unleash skill has.
Compatibility
As far as I can tell, this is compatible with Yanfly's plugins. Try to have this plugin at the top if you have problems.
Update Log
(1.1) Will now also look for unleash notetags in Actor and Class Notes
(1.1) Added ability to have unleash skill only activated if they are learned by actor (see learned_unleash)
Terms of Use
You are free to use this script for any commercial or non-commercial game. Credit is not necessary, but it is appreciated!
Disclaimer
This is my first time writing in JavaScript, so bear with me!
Download
https://github.com/Vadavim/rpgmaker_mv_plugins/blob/master/VIM_Unleash.js
If you've ever played a game like Golden Sun, you might be familiar with the concept of unleash skills. This script allows you to give weapons and skills a chance to activate a different skill in its place when used.
Features
- Allows you to specify one or more skills that can activate when using a weapon or skill.
- The chance of activation can be affected by the user's luck.
- You can create your own formula for calculating how luck (or other attributes!) affect activation chance.
How to Use
In the notes of a weapon or skill, you can specify one or more skills that have a chance of activating using the following notetag format:
<unleash: id, chance>
Where id is the id of the skill, and chance is the percent chance of it activating. For instance, <unleash: 10, 50> on a weapon would mean that there is a 50% chance of activating skill 10 in place of making a normal attack.
If you specify more than one skill, then the unleash skills are checked in order until one succeeds (or if none do, then the normal attack / skill is used instead). When making a normal attack, unleash skills for each weapon are checked (in the order that they are equipped).
Luck Factor
If you want luck to play a role in determining how often an unleash skill activates, you can instead use the following notetag format:
<unleash: id, chance, difficulty>
Where difficulty is an integer used in the following relative difference formula below:
activation_chance = base_chance * (1 + (luck - difficulty) / (luck + difficulty))
Custom Luck Factor
If you would like to use your own formula for calculating how luck affects unleash chance, you can use the Luck Eval parameter to evaluate it. The following variables might be useful to you when doing so:
user: refers to the actor using the unleash skill. You can access attributes such as user.luk from this.
diff: the difficulty of the unleash skill (0 if none is given in the notetag)
chance: the base chance of activating the skill (represented as a fraction).
Note that your final evaluated chance should probably be between 0 and 1 (where 0.0 = 0%, 0.5 = 50%, etc.).
As an example, you could enter the following in Luck Eval:
chance + user.luk * 0.01 - diff * 0.01
This would increase the base chance by 1% per point of luck, minus 1% per point of difficulty that the unleash skill has.
Compatibility
As far as I can tell, this is compatible with Yanfly's plugins. Try to have this plugin at the top if you have problems.
Update Log
(1.1) Will now also look for unleash notetags in Actor and Class Notes
(1.1) Added ability to have unleash skill only activated if they are learned by actor (see learned_unleash)
Terms of Use
You are free to use this script for any commercial or non-commercial game. Credit is not necessary, but it is appreciated!
Disclaimer
This is my first time writing in JavaScript, so bear with me!
Download
https://github.com/Vadavim/rpgmaker_mv_plugins/blob/master/VIM_Unleash.js
Last edited by a moderator: