Dollars and cents

CrazyCrab

Veteran
Veteran
Joined
Mar 5, 2014
Messages
950
Reaction score
403
First Language
Polish
Hi everyone,

In my current game the player will be buying some mundane items and I don't want him or her to pay 50 dollars for a tomato.

Is there a way to replace the normal all integer gold system with the usual XX.xx system?

Thanks!
 

YoraeRasante

Veteran
Veteran
Joined
Jun 6, 2014
Messages
1,643
Reaction score
420
First Language
Portuguese
Primarily Uses
RMMV
You can, but things like item values in the database will suffer.

You can always make every time money is shown it appear as itself divided by 100.0? this way at least it will seem so.
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
40,098
Reaction score
13,704
First Language
English
Primarily Uses
RMMV
Can you even enter decimal numbers for item prices? Do they "stick" when you save in the editor, close and reopen it?
 

YoraeRasante

Veteran
Veteran
Joined
Jun 6, 2014
Messages
1,643
Reaction score
420
First Language
Portuguese
Primarily Uses
RMMV
that's what I meant, sorry, I'm terrible explaining
 

R4B

✨Coffee is my spirit animal✨
Veteran
Joined
Jan 6, 2014
Messages
189
Reaction score
218
First Language
Swedish
Primarily Uses
Wouldn't it be pretty easy to make a script where it ads a dot before the last 2 numbers and a '0' before any number that's lower than 100.

That way if you would set the price of an item to 2050 G it would show as 20.50 $ ingame, and 50 G would show as 0.50 $.? 
 

YoraeRasante

Veteran
Veteran
Joined
Jun 6, 2014
Messages
1,643
Reaction score
420
First Language
Portuguese
Primarily Uses
RMMV
that's what I said, a script that shows the money as divided by 100.0 would do exactly that
 

R4B

✨Coffee is my spirit animal✨
Veteran
Joined
Jan 6, 2014
Messages
189
Reaction score
218
First Language
Swedish
Primarily Uses
that's what I said, a script that shows the money as divided by 100.0 would do exactly that
Sorry, man.

I thought you meant he should divide it himself and enter result in the database normally which wouldn't work ... 
 
Last edited by a moderator:

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,365
Reaction score
7,674
First Language
German
Primarily Uses
RMMV
that's what I said, a script that shows the money as divided by 100.0 would do exactly that
A script can change the display in the game - it can not change the values in the database.
Which means that you can make a gold value of 2345 G to appear as 23.45$ in the game, but the value in the editor and the database will remain 2345.
 

YoraeRasante

Veteran
Veteran
Joined
Jun 6, 2014
Messages
1,643
Reaction score
420
First Language
Portuguese
Primarily Uses
RMMV
that's why I said "shows" Andar :p
As in, in-game
 

GrandmaDeb

Modern Exteriors Posted!
Veteran
Joined
Apr 25, 2012
Messages
4,467
Reaction score
2,942
Primarily Uses
Another possibility is to use one of the scripts which allows you to trade from one thing to another, and have "cents" and "dollars."


Charge cents for tomatoes and dollars for Gold Armor. =]


Swap cents for dollars and dollars for cents.


SCript


http://theolized.blogspot.com/2013/08/theo-crafting-system.html


note that an English Version is available in the downloads
 
Last edited by a moderator:

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD
How many parameters is 'too many'??

Forum statistics

Threads
105,862
Messages
1,017,049
Members
137,570
Latest member
fgfhdfg
Top