Jump to content
Calestian

Multiple Currencies

Recommended Posts

Hello, I was wondering if you could help me with this

 

I added this script to my game, added some currencies and tested it. It worked perfectly

 

I added some more scripts I was using in my game but when I tested my game again, the currencies option no longer showed up in the menu

 

I have a feeling one of the other scripts I used that added more menu options messed it up but I'm not sure and I don't know how to fix it

Edited by CristorcusHelix

Share this post


Link to post
Share on other sites

so Providing more details on what scripts you added would be helpful. Also you should make your own thread for support, not comment in here. By the time we fix your problem we will ave added 10+ posts to this thread.

Share this post


Link to post
Share on other sites

Most of yanfly's scripts sets the menus to a specific set of instructions with the option to add on other commands.

This is what you need to do, which is why I asked that you make a new thread.So we can provide you the instructions to do so, without filing up this thread with a problem that has nothing to do with this script.

Share this post


Link to post
Share on other sites

Is there a way to run the currency through a conditional branch? Im using the multi currency script for a "casino". You exchange gold for a different currency just for the casino and That money is used to play games and exchange for prizes. Think like the old Pokemon Red and Blue casino. However, I  cant see a way to run a check against the amount of the second currency to confirm whether or not you can play. Without that check, you can just play all the games for free. Hopefully, what I wrote makes sense and someone has an answer for me. I tried to run "if currency(1) >=1" as part of the conditional branch thinking it would work and it crashed my game. lol.

Share this post


Link to post
Share on other sites

I have an error. When I try to open a shop with a currency other than #0 it crashes with this error message:

"undefined method: '[]' for nil:NilClass.

and it sends me to line 244 of the script saying "$game_party.currency[currency_index]". I input the exact script call as I was told before the shop processing so what am I doing wrong?

 

Edit: I figured it out. The Shop Manager script I used was the error. I removed that script along with the shop stick script and now it's working just fine. Guess I need another way for adding a shop stock.

Edited by Yanntastic

Share this post


Link to post
Share on other sites

to fix the amount of currencies without having to keep updating the code,

change line 285 from

11.times { |i|

to

(Clstn_Currencies::Currencies.length).times { |i|

Share this post


Link to post
Share on other sites
1 hour ago, mattgowens said:

to fix the amount of currencies without having to keep updating the code,

change line 285 from

11.times { |i|

to

(Clstn_Currencies::Currencies.length).times { |i|

Brill!

Share this post


Link to post
Share on other sites
Posted (edited)

To use conditional branch for checking amount of currency

conditional branch => script => $game_party.currency[CurrencyID] >= X

X being the amount you want to check

Edit: Added a picture on a common event to auto convert currencies

Edit 2: Made some modifications to script, letting everyone have. Window changes size depending on how many currencies you have. Can change Color of the title, and can change the name of the title if you so choose.

 ---->  Pastebin <-----

Conditional Branch.png

Convert Currency.png

Edited by mattgowens
Updated Script, Added Pictures

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

×
Top ArrowTop Arrow Highlighted