Magic

Magic

190k Downloads

Spell shop, change cost

Cornelwallace opened this issue ยท 10 comments

commented

Hello, the issue i'm having is I can't figure out how to change the cost of a spell by this I mean when I use the spell shop spell or when I try to upgrade a wand, it says that I can only buy the spell with money, and im trying to buy it with emeralds instead, could you explain to me how I can do this?

Thanks! I hope you can respond to me soon.

commented

Spell shop uses SP by default, not money.

If you want to change that, try this in spells.yml:

spellshop:
  parameters:
     use_sp: false
     use_items: true

That will make it use an item-based currency, emeralds by default. Do this to any other shops you want to change.

commented

Is there a specific place I should put that in the spells.yml file? and where would I add the item I want for the cost of the spell?

commented

No, spells.yml should be empty by default, put it anywhere.

Unfortunately I think there is a bug that makes it so you can't change the item used. There is only one item- Magic shops are not barter shops, they are just able to use an emerald-based currency if you don't have anything else available.

As an alternative, I'd suggest using Vault+Gringotts.

commented

I have already added things in the spells.yml file but when I added
parameters:
use_sp: false
use_items: true
the plugin stopped working completely
(in the config i did disabled sp)

commented

Sorry, something weird happened with the formatting there. Should be:

spellshop:
  parameters:
     use_sp: false
     use_items: true

Meaning you are customizing the "spellshop" spell. Make sure indentation is spaces, of course, and there is no indentation in front of "spellshop"

commented

Alternately, you could just turn off SP. If you don't have Vault, this will make the spellshop use emeralds.

To do this you'd put this in config.yml:

sp_enabled: false

If you're not using SP to buy spells then the entire system is kind of pointless so you ought to turn it off.

commented

I added it to spells.yml hopefully correctly. Now it still says spells cost money now how do I change that?

commented

and one last question, in potterworldmc they have AC and it was apart of your balance, and they made it so you can buy spells with that, do you know how I could do that?

commented

Using the configs I provided, it should be charging emeralds. I tried it just now for myself and it worked.

spellshop:
  parameters:
    use_items: true
    use_sp: false

Produces:
Imgur

Do you want to buy spells with emeralds or currency? AC is nothing like an item, it is more like a currency.

Potterworld has their own custom economy that they've coded, the closest you can get is to just use SP (in which case this whole discussion has become irrelevant) and rename it to AC. This is what the builtin "potter" configs do. (e.g. put "example: potter" in config.yml)

commented

ok thank you for your help!