I'm trying to make a magic system in my RPG where skills gain additional effects based on a character's alignment (which is assigned to a variable), but I'm kind of unsure how to get this to work.
Magic System Question
RPG Maker VXAce SupportThere are a lot of options for this - the best way will probably depend on details about your game which we don't know.
1) you can use ruby code in the damage formula box, including if statements to check target date or using variables to scale the damage.
2) some skills can call common events for their effects, where you can check and do anything you want
3) you can use the elemental rates and states to dynamically change the damage numbers
4) there should be some scripts you can use for different effects
5) you can write your own scripts modifying anything you want.
1) you can use ruby code in the damage formula box, including if statements to check target date or using variables to scale the damage.
2) some skills can call common events for their effects, where you can check and do anything you want
3) you can use the elemental rates and states to dynamically change the damage numbers
4) there should be some scripts you can use for different effects
5) you can write your own scripts modifying anything you want.
For skills that only have their damage affected "Formula" is where you want to be looking, to the right hand side in the skills tab of the database.
You can use it to make a custom algorithm for calculating the damage of each skill.
When you want to reference an "event" variable, use $game_variables[id goes here] or its shortcut v[id goes here] .
For more complicated effects, you'll want to take advantage of notes to call on scripts. Googling turned up this post on another forum which may be helpful in that regard.
You can use it to make a custom algorithm for calculating the damage of each skill.
When you want to reference an "event" variable, use $game_variables[id goes here] or its shortcut v[id goes here] .
For more complicated effects, you'll want to take advantage of notes to call on scripts. Googling turned up this post on another forum which may be helpful in that regard.
Well, the formula box is going to be a bit small, so I recommend you start here: http://forums.rpgmakerweb.com/index.php?/topic/1143-how-to-make-the-most-of-custom-formulae-part-1/ and follow up with http://forums.rpgmakerweb.com/index.php?/topic/1716-how-to-make-the-most-of-custom-formulae-part-2/
That should get you started. 🙂
That should get you started. 🙂
Here's an example of how to add variables to your damage formula:
((a.atk*3-b.def)+v[x]*3) whereas "x" is the variable number.
((a.atk*3-b.def)+v[x]*3) whereas "x" is the variable number.
Original thread: https://forums.rpgmakerweb.com/threads/magic-system-question.39907/