• The Eevee Expo Game Jam #10 has concluded, congratulations to all participants! Now it's time for the judges to play through the games, and you can play along to vote who deserves the community choice spotlight.
    You can check out the submitted games here!
    Play through the games and provide some feedback to the devs while you're at it!
  • Hi, Guest!
    Some images might be missing as we move away from using embedded images, sorry for the mess!
    From now on, you'll be required to use a third party to host images. You can learn how to add images here, and if your thread is missing images you can request them here.
    Do not use Discord to host any images you post, these links expire quickly!
Resource icon

Resource [20.1+] BP System 1.0.7

4AllNighterGrinder64

4 Sleepless nights to update to Teal Mask Part 1
Member
Joined
Nov 23, 2023
Posts
20
I assume the problem comes because both plugins edit pbEndOfBattle. I'll look at the terastallization code to see if it's the case.

Edit: Lucidious plugin does touch pbEndOfBattle but there should be no reason for my plugin to stop the terastallization from ending. I don't know why it's happening but I think I know a possible way to fix it.
I will try out the updated BP System soon. I will let you know if the conflict with terastallization is fixed.
 

Lucidious89

Champion
Member
Joined
Nov 12, 2020
Posts
1,183
I assume the problem comes because both plugins edit pbEndOfBattle. I'll look at the terastallization code to see if it's the case.

Edit: Lucidious plugin does touch pbEndOfBattle but there should be no reason for my plugin to stop the terastallization from ending. I don't know why it's happening but I think I know a possible way to fix it.
I didn't have the chance to look at the plugin before you updated it, but I imagine it was likely a load order issue, so my alias of this method was being overwritten instead of aliasing the method like it's supposed to.

Though, linking the BP acquisition to the same method that the player acquires money through seems like a much better and more logical way to go about it, anyway.

As a separate issue though, I notice that you're using the Essentials Deluxe compiler method for adding PBS info. That's fine, but unless your plugin depends on this to work, I would advise against this. Fiddling with how the compiler works is messy and very risky business, and leaves your plugin prone to compatibility issues. Which is why I abandoned that whole method of doing things in the new v21 plugin. It seems like your plugin implements all of this simply to provide an example for two items, which imo, is not worth all of that complex code when you can simply just post a picture of an example instead. But that's just my two cents.
 

LinKazamine

Champion
Member
Joined
May 24, 2023
Posts
662
I added the compiler thinking it would be easier to add the BP prices to items that way than to go through all the items in the files but if it causes trouble I have no issue taking it down and adding images on how they should be added.
 

4AllNighterGrinder64

4 Sleepless nights to update to Teal Mask Part 1
Member
Joined
Nov 23, 2023
Posts
20
I assume the problem comes because both plugins edit pbEndOfBattle. I'll look at the terastallization code to see if it's the case.

Edit: Lucidious plugin does touch pbEndOfBattle but there should be no reason for my plugin to stop the terastallization from ending. I don't know why it's happening but I think I know a possible way to fix it.
I have tested out 1.0.6 of the BP System plugin with all of the Deluxe Battle Kit plugins. Terastallization works as intended now. The plugin conflict with the previous version and the DBK Terastallization add on is now fixed. I forgot to test out Mega Evolution and Z-Moves on my end, but they were working fine before the update fixed the plugin conflict with Terastallization.
 

LinKazamine

Champion
Member
Joined
May 24, 2023
Posts
662
Well, that problem is carried from the v21 version since I didn't touch the line that causes it. I'll upload the fix but you can do it yourself by going to 02 - Shop/BP_Shop and deleting or commenting out line 341. The line in question is itemprice /= 2 if !@buying.
 

CelestialFearow

Venipede User
Member
Joined
Jul 24, 2020
Posts
200
Well, that problem is carried from the v21 version since I didn't touch the line that causes it. I'll upload the fix but you can do it yourself by going to 02 - Shop/BP_Shop and deleting or commenting out line 341. The line in question is itemprice /= 2 if !@buying.
Alright!
 

rafahbit

Trainer
Member
Joined
Oct 21, 2020
Posts
53
Hello, I wanted the BP shop to be similar to Arcky's Poké Mart, so I created a Ruby file to configure the shop outside the event. This includes a command to call different shops and a badge system, all editable within the Ruby file. You can add various items and BP shops with this setup.
Since it's practically replacing the BP shop with another one, you can also configure the vendor's messages here.

I'm not very good with programming, so I try to create things with the help of ChatGPT. I didn't have any issues with the plugin below; it worked correctly. However, I can't guarantee there are no problems. I'm sharing it here for anyone who wants to implement it.


battle_point_shops:
Expand Collapse Copy
#===============================================================================
# Battle Point Shops Plugin
#to call the shop, just place it in an event: pbOpenBPShop(shopid)
#example: pbOpenBPShop(1)
#===============================================================================

# Defines the items available in each store
BATTLE_POINT_SHOPS = {
  1 => [
    :POTION, :GREATBALL, :SUPERPOTION, :ANTIDOTE, :PARALYZEHEAL, :AWAKENING,
    :HYPERPOTION, :SUPERREPEL, :REVIVE,
    :ULTRABALL, :FULLHEAL, :MAXREPEL, :ZINC, :CARBOS, :PPUP, :PPMAX,
    :MAXPOTION, :FULLRESTORE
],
  2 => [
    :POTION,
    :TM01,:TM02,:TM03,:TM04,
    :TM05,:TM06,:TM07,:TM08,
    :TM09,:TM10,:TM11,:TM12,
    :TM13,:TM14,:TM15,:TM16,
    :TM17,:TM18,:TM19,:TM20,
    :TM21,:TM22,:TM23,:TM24,
    :TM25,:TM26,:TM27,:TM28,
    :TM29,:TM30,:TM31,:TM32,
    :TM33,:TM34,:TM35,:TM36
  ]
}


# Define the badges required to access items

BadgesForItems = {
  1 => [:GREATBALL, :SUPERPOTION, :ANTIDOTE, :PARALYZEHEAL, :AWAKENING],
  3 => [:HYPERPOTION, :SUPERREPEL, :REVIVE],
  5 => [:ULTRABALL, :FULLHEAL, :MAXREPEL, :ZINC, :CARBOS, :PPUP, :PPMAX],
  7 => [:MAXPOTION, :ZINC, :CARBOS, :PPUP, :PPMAX],
  8 => [:FULLRESTORE]
}

# Function to open a Battle Points store based on an ID

def pbOpenBPShop(shop_id)
  items = BATTLE_POINT_SHOPS[shop_id]
  if items.nil?
    pbMessage(_INTL("Shop not found."))
    return
  end

# Filter items based on player badges

  items_to_display = items.select do |item|
    # Verifica se o item é válido
    next false unless GameData::Item.exists?(item)

# Checks if the item has an associated badge

    badge_id = BadgesForItems.keys.find do |key|
      BadgesForItems[key].include?(item)
    end
   
    If the item is not associated with a badge or the player has the required badge, the item will be displayed
    badge_id.nil? || ($player.badge_count >= badge_id)
  end

  if items_to_display.empty?
    pbMessage(_INTL("No items available for you at this shop."))
    return
  end

  pbMessage(_INTL("Welcome to the BP Exchange Service!"))
  pbMessage(_INTL("We can exchange your BP for amazing items."))
 
  scene = BattlePointShop_Scene.new
  screen = BattlePointShopScreen.new(scene, items_to_display)
  screen.pbBuyScreen
 
  pbMessage(_INTL("Thank you for visiting."))
  pbMessage(_INTL("Come back when you have more BP to spend."))
 
  $game_temp.clear_mart_prices
end
 
Last edited:
Back
Top