Updates dye kit menu

This commit is contained in:
chardub
2025-03-15 09:37:54 -04:00
parent 88ed3c000e
commit 7012af625d
26 changed files with 88 additions and 3 deletions

View File

@@ -139,4 +139,5 @@ HAIR_HOOH = "ho-oh"
HAIR_CRESSELIA = "lunarbob"
HAIR_LYCANROC="lycanrocshorthair"
HAIR_HAPPINY="happinysuit"
HAIR_LATIAS="SpecialLatias"
HAIR_LATIAS="SpecialLatias"
HAIR_GARDEVOIR="gardevoir"

View File

@@ -10,6 +10,8 @@ class HairMartAdapter < OutfitsMartAdapter
@version = getCurrentHairVersion().to_i
@worn_hair = $Trainer.hair
@worn_hat = $Trainer.hat
@worn_hat2 = $Trainer.hat2
@hat_visible = false
@removable = true
@previous_item= find_first_item()
@@ -105,8 +107,14 @@ class HairMartAdapter < OutfitsMartAdapter
item = @previous_item if item.is_a?(Symbol)
@previous_item = find_first_item() if !item.is_a?(Symbol)
displayed_hat = @hat_visible ? @worn_hat : nil
displayed_hat2 = @hat_visible ? @worn_hat2 : nil
previewWindow.hat = displayed_hat
previewWindow.hat2 = displayed_hat2
$Trainer.hat = displayed_hat
$Trainer.hat2 = displayed_hat2
itemId = getCurrentHairId(item.id)
previewWindow.hair = itemId
$Trainer.hair = itemId
@@ -142,6 +150,8 @@ class HairMartAdapter < OutfitsMartAdapter
$Trainer.hair = @worn_hair
$Trainer.hat = @worn_hat
$Trainer.hat2 = @worn_hat2
end
def get_unlocked_items_list()

View File

@@ -1717,4 +1717,64 @@ def qmarkMaskCheck()
obtainClothes(CLOTHES_GLITCH)
end
end
end
def purchaseDyeKitMenu(hats_kit_price=0,clothes_kit_price=0)
commands = []
command_hats = "Hats Dye Kit ($#{hats_kit_price})"
command_clothes = "Clothes Dye Kit ($#{clothes_kit_price})"
command_cancel = "Cancel"
commands << command_hats if !$PokemonBag.pbHasItem?(:HATSDYEKIT)
commands << command_clothes if !$PokemonBag.pbHasItem?(:CLOTHESDYEKIT)
commands << command_cancel
if commands.length <= 1
pbCallBub(2,@event_id)
pbMessage("\\C[1]Dye Kits\\C[0] can be used to dye clothes all sorts of colours!")
pbCallBub(2,@event_id)
pbMessage("You can use them at any time when you change clothes.")
return
end
pbCallBub(2,@event_id)
pbMessage("\\GWelcome! Are you interested in dyeing your outfits different colours?")
pbCallBub(2,@event_id)
pbMessage("I make handy \\C[1]Dye Kits\\C[0] from my Smeargle's paint that can be used to dye your outfits any color you want!")
pbCallBub(2,@event_id)
pbMessage("\\GWhat's more is that it's reusable so you can go completely wild with it if you want! Are you interested?")
choice = optionsMenu(commands,commands.length)
case commands[choice]
when command_hats
if $Trainer.money < hats_kit_price
pbCallBub(2,@event_id)
pbMessage("Oh, you don't have enough money...")
return
end
pbMessage("\\G\\PN purchased the dye kit.")
$Trainer.money -= hats_kit_price
pbSEPlay("SlotsCoin")
Kernel.pbReceiveItem(:HATSDYEKIT)
pbCallBub(2,@event_id)
pbMessage("\\GHere you go! Have fun dyeing your hats!")
when command_clothes
if $Trainer.money < clothes_kit_price
pbCallBub(2,@event_id)
pbMessage("Oh, you don't have enough money...")
return
end
pbMessage("\\G\\PN purchased the dye kit.")
$Trainer.money -= clothes_kit_price
pbSEPlay("SlotsCoin")
Kernel.pbReceiveItem(:CLOTHESDYEKIT)
pbCallBub(2,@event_id)
pbMessage("\\GHere you go! Have fun dyeing your clothes!")
end
pbCallBub(2,@event_id)
pbMessage("You can use \\C[1]Dye Kits\\C[0] at any time when you change clothes.")
end