Jeff the Green
Member
I'm having trouble with this snippet of code that shouldn't be so frustrating.
I created a skill that does damage to the player in exchange for more money after the battle. I linked it to a common event turning switch #1 on, and added this snippet of code:
just above $game_party.gain_gold(gold) in Scene_Battle 2 (line 179). It multiplies the amount of gold you get, but it doesn't round, so I get 252.4 gold, or whatever, after the battle. Even if I don't use the skill, it gives me 100.0 gold. I also tried gold.truncate instead of gold.round, which doesn't help. What am I doing wrong?
I created a skill that does damage to the player in exchange for more money after the battle. I linked it to a common event turning switch #1 on, and added this snippet of code:
Code:
if $game_switches[1]=1
gold *=1.4
gold.round
end