Charas-Project

Game Creation => Requests => Tutorials => Topic started by: Sephiroth rocks on June 04, 2005, 08:17:55 PM

Title: Giltoss Tut
Post by: Sephiroth rocks on June 04, 2005, 08:17:55 PM
I've found a pretty simple way to make an FF style giltoss skill that damages all enemies (rm2k3 only). I came up with this myself so if you see something similare anywhere else I haven't copied it. You'll need to understand variables:

1. Open the database and select "Class".

2. Select the class that the character you want to be able to use the Giltoss ability is and make a new skill slot called "Giltoss" and set it to be "Skill".

3. Go to "Skills" and make a new one. Set its type to Switch, make a new switch then set the skill to turn on that switch. Make sure it's set to be used in battle only.

4. Go to "Monster Groups" and make a new Battle event page and set the trigger to be if the switch that the skill toggles is on. Then make a new variable. Set it to be equal to the amount of total money held. Then show a message showing the total amount of money (by using \V[####]) and then select "Input number" and set the amount of digits to 6 and the store variable to a new variable.

5. Divide the variable that holds the amount of money spent with whatever you want to (this skill is going to hit all enemies so it shouldn't deal as much damage as money used). Then divide the other variable which holds the total money with the same number.

6. Make a new Conditional Branch and set the trigger to "If variable (money used) is greater than variable (total money)". Check the "execute else handler" box.

7.Select "Change monster HP" and set it to be decreased by the number of the variable which holds the total amount of money. Make sure that the HP reduction can kill the enemy. Paste this for each monster in the monster group (And change the targets for the HP reduction of course).

8. Change the variable which hold the total money to be equal to the total amount of money ('Cuz you've divided the variable, remember?). Then select "Change Money" and reduce it equal to the value of the variable which holds the total money (in other words reduce the money to 0). This ensures that you can't deal more damage than the amount of money you've got.

9. Go to the else handler and do exactly the same as you did in step 7 except that you deal damage to each creature equal to the amount of money spent instead. Then multiply the variable which holds the amount of money spent with the number you divided it with in step 5. Then select Change money and reduce it equal to the amount of money spent.

10. Turn the switch off again. And it's done! You should now have a working Giltoss command! The coding should look like this:

<>Variable Operation: [####: Total Money] Set, Money
<>Message: Total amount of GP: \V[####]
<>Input number: 6 Digit, [####: Money Spent]
<>Variable Operation: [####: Money Spent] / X
<>Variable Operation: [####: Total Money] / X
<>Branch if Variable [####: Money Spent] is greater than [####: Total Money]:
  <>Change Monster X: -Name-'s HP V[####: Total Money] Remove. (Copy for each monster in group)
  <>Variable Operation: [####: Total Money] Set, Money
  <>Change Money: V[####: Total Money] Remove
  <>
: Else
  <>Change Monster X: -Name-'s HP V[####: Money Spent] Remove. (Copy for each monster in group)
  <>Variable Operation: [####: Money Spent] * X
  <>Change Money: V[####: Money Spent] Remove
  <>
: End
<> Switch Operation: [####: Giltoss] OFF
<>

11. Oh of course we shouldn't forget the boring part: Copy and paste this for every monster group and make sure the settings fits each monster group!
Title:
Post by: SaiKar on June 04, 2005, 08:38:00 PM
The core seems okay, but the balance seems off. Here's an example sitaution:

Let's say that you want to throw 100 GP. The 100 is divided by 4, and so each enemy takes 25 damage. Works. Well, what if you kill an enemy? Damage would still be divided by 4, so each would still take 25 damage, and 25 gil would vanish mysteriously.

Maybe a better way to do it would be to set up "If monster X can act" conditional branches, and add to a variable. Something like...

<> Branch if 1: Monster 1 Can Act
<> Variable Oper: [Divider} +1
<> End
<> Branch if 2: Monster 2 Can Act
<> Variable Oper: [Divider} +1
<> End

And so on for all the enemies, so that each time you use the skill, the damage is divided evenly among all foes that are still alive.