Main Menu
  • Welcome to The RPG Maker Resource Kit.

1000-?=Gold (solved)

Started by StrifeUk, February 18, 2006, 09:12:56 PM

0 Members and 4 Guests are viewing this topic.

StrifeUk

There is an NPC in my game who you can talk to, to earn the amount of money you need to total 1,000 gold.

For example, if you play the game and have 300 gold, you fight the NPC and win, you will have 700 gold added to what you already have.

But how would you do this? To be more precise, how do you use constants and variables to define 1000 subtract what you already have is equal what should be gained?

Thanks in advance.

Edit: Never mind, i have solved it.

Tsunokiette

JFYI: You'll want to create a conditional branch (events) or if statement (rgss) to make it so that if 1000 - current_gold = 0 or a neg. number, ie. You already have 1000+ gold, it give you 0 gold. So that it wont add a negative number to how much gold you have ie. wont bring it down to 1000.
"The wonderful thing about Tiggers
Is Tiggers are wonderful things
Their tops are made out of rubber
Their bottoms are made out of springs

They're bouncy, trouncy, flouncy, pouncy
Fun, fun, fun, fun, fun!
But the most wonderful thing about Tiggers
Is I'm the only one, I'm the only one."