Модификации:Головные уборы

Материал из Stardew Valley Wiki
Перейти к навигации Перейти к поиску

Индекс

На этой странице объясняется, как игра хранит и анализирует данные головных уборов. Это расширенное руководство для разработчиков модов.

Источник

Головные уборы хранятся в Content\Data\hats.xnb, могут быть извлечены для редактирования. Вот исходные данные по состоянию на 1.5.1 для примера:

Данные 
{
  "0": "Cowboy Hat/The leather is old and cracked, but surprisingly supple. It smells musty./false/true",
  "1": "Bowler Hat/Made from smooth felt./false/true",
  "2": "Top Hat/A gentleman's classic./false/true",
  "3": "Sombrero/A festively decorated hat made from woven straw./фfalse/true",
  "4": "Straw Hat/Light and cool, it's a farmer's delight./false/true",
  "5": "Official Cap/Looks like it belonged to a postman or policeman. Either way, it's still very soft and smells okay./false/true",
  "6": "Blue Bonnet/Harken back to simpler times with this prairie bonnet./false/true",
  "7": "Plum Chapeau/Looks alright./false/true",
  "8": "Skeleton Mask/The red eyes are glowing mysteriously./true/true",
  "9": "Goblin Mask/Freak out the neighborhood with this creepy mask. Rubber ear joints for effect./true/true",
  "10": "Chicken Mask/You'll be sure to get them grinning with this one./true/true",
  "11": "Earmuffs/Keep your ears toasty. Lined with artisanal velvet from Castle Village./true/false",
  "12": "Delicate Bow/Little pink jewels glisten as you examine it./true/false",
  "13": "Tropiclip/It's shaped like a little palm tree./true/false",
  "14": "Butterfly Bow/This one is very soft./true/false",
  "15": "Hunter's Cap/The wool lining should stay warm deep into the forest./false/true",
  "16": "Trucker Hat/Mesh in the back to keep your head cool./false/true",
  "17": "Sailor's Cap/It's fresh and starchy./false/true",
  "18": "Good Ol' Cap/A floppy old topper with a creased bill. Looks like it's been through a lot./false/true",
  "19": "Fedora/A city-slicker's standard./false/true",
  "20": "Cool Cap/It looks really faded, but it used to be a vibrant blue./false/true",
  "21": "Lucky Bow/The middle is made of solid gold./true/false",
  "22": "Polka Bow/This one's sure to be turn heads./true/false",
  "23": "Gnome's Cap/This gnome had a very large head./false/true",
  "24": "Eye Patch/You can't tell if it's real or just from a costume shop./true/true",
  "25": "Santa Hat/Celebrate the magical season./false/true",
  "26": "Tiara/This one has a big amethyst encircled by gold./true/true",
  "27": "Hard Hat/Keep your dome in one piece./false/true",
  "28": "Sou'wester/The shape helps to keep sailors dry during storms./false/true",
  "29": "Daisy/A fresh spring daisy to put in your hair./true/false",
  "30": "Watermelon Band/The color scheme was inspired by the beloved summer melon./true/false",
  "31": "Mouse Ears/Made from synthetic fibers./true/true",
  "32": "Cat Ears/Whiskers included./true/true",
  "33": "Cowgal Hat/The band is studded with fake diamonds./false/true",
  "34": "Cowpoke Hat/For dairy experts./false/true",
  "35": "Archer's Cap/Fashionable whether you're an archer or not./false/true",
  "36": "Panda Hat/A lovely panda hat./false/true",
  "37": "Blue Cowboy Hat/A denim cowboy hat in cool blue./false/true",
  "38": "Red Cowboy Hat/An eye-catching cowboy hat in red suede./false/true",
  "39": "Cone Hat/A curiosity from a distant land./false/true",
  "40": "Living Hat/It absorbs moisture from your scalp. No watering needed!/false/true",
  "41": "Emily's Magic Hat/Made with love by Emily. It's 100% organic!/false/true",
  "42": "Mushroom Cap/It smells earthy./false/true",
  "43": "Dinosaur Hat/A hat fashioned to look like a small dinosaur./false/true",
  "44": "Totem Mask/Don't worry, it won't warp your face.../true/true",
  "45": "Logo Cap/A red cap with a logo on the front./false/true",
  "46": "Wearable Dwarf Helm/A slightly larger, human sized version of the helmets worn by dwarves./hide/true",
  "47": "Fashion Hat/A fashionable hat with a feather in the brim./false/true",
  "48": "Pumpkin Mask/This must have been a pretty big pumpkin once.../hide/true",
  "49": "Hair Bone/A prehistoric version of the hair bow./true/false",
  "50": "Knight's Helmet/It looks just like the real thing!/hide/true",
  "51": "Squire's Helmet/The face is exposed to increase air flow./hide/true",
  "52": "Spotted Headscarf/A red polka-dot scarf tied around the head./hide/true",
  "53": "Beanie/A warm hat with a pretty tight fit./hide/true",
  "54": "Floppy Beanie/A warm hat with a looser fit./hide/true",
  "55": "Fishing Hat/The wide brim keeps you shaded when you're fishing on the riverbank./false/true",
  "56": "Blobfish Mask/Just as spongy as the real thing!/true/true",
  "57": "Party Hat/A goofy red hat that makes any celebration more fun./false/true",
  "58": "Party Hat/A goofy blue hat that makes any celebration more fun./false/true",
  "59": "Party Hat/A goofy green hat that makes any celebration more fun./false/true",
  "60": "Arcane Hat/The type of cowboy hat worn by a wizard./false/true",
  "61": "Chef Hat/The traditional hat worn by a head chef./hide/true",
  "62": "Pirate Hat/A captain's hat with a horrible skull on the front./false/true",
  "63": "Flat Topped Hat/An old style of hat once considered very fashionable./false/true",
  "64": "Elegant Turban/A fine black silk turban with gold trim./false/true",
  "65": "White Turban/A fine white silk turban with blue trim./false/true",
  "66": "Garbage Hat/It's a garbage can lid 'upcycled' into a hat.../false/true",
  "67": "Golden Mask/A faithful recreation of the Calico Desert relic!/true/true",
  "68": "Propeller Hat/A goofy hat with a propeller on top./false/true",
  "69": "Bridal Veil/The traditional headwear for a bride./false/true",
  "70": "Witch Hat/A pointy hat popular with witches./false/true",
  "71": "Copper Pan/You place the copper pan on your head.../false/true",
  "72": "Green Turban/A green silk turban with a gold ornament on the front./false/true",
  "73": "Magic Cowboy Hat/It's shimmering with prismatic energy/false/true/Prismatic",
  "74": "Magic Turban/It's shimmering with prismatic energy/false/true/Prismatic",
  "75": "Golden Helmet/It's half of a golden coconut./false/true",
  "76": "Deluxe Pirate Hat/Only the most infamous pirate could pull off this look./false/true",
  "77": "Pink Bow/This huge bow makes quite a statement!/true/false",
  "78": "Frog Hat/A slimy friend that lives on your dome./hide/true",
  "79": "Small Cap/It's a more aerodynamic style of cap./false/true",
  "80": "Bluebird Mask/Wear this to look just like your favorite island trader./hide/true",
  "81": "Deluxe Cowboy Hat/A cowboy hat with a more extreme shape./false/true",
  "82": "Mr. Qi's Hat/A replica of Mr. Qi's iconic hat./false/true",
  "83": "Dark Cowboy Hat/A cowboy hat in fashionable black./false/true",
  "84": "Radioactive Goggles/Doesn't actually provide any protection from radiation./true/true",
  "85": "Swashbuckler Hat/The classic swashbuckler look./false/true",
  "86": "Qi Mask/???/hide/true",
  "87": "Star Helmet/A red hat with stars on it./false/true",
  "88": "Sunglasses/These give you a relaxed look./true/true",
  "89": "Goggles/These will make you look very safe./true/true",
  "90": "Forager's Hat/It's a forager's delight./false/true",
  "91": "Tiger Hat/Makes you look like a beautiful tiger./hide/true",
  "92": "???/???/hide/true",
  "93": "Warrior Helmet/An Ostrich eggshell repurposed into a helmet./false/true"
}

Формат

Шляпы имеют жестко закодированную категорию -95 (Hats.cs::Load)

Индекс Поле Пример значения
0 Name
Название
Trucker Hat
1 Description
Описание
Mesh in the back to keep your head cool.
2 skipHairDraw
Пропустить изменение причёски
false
3 ignoreHairstyleOffset
Игнорировать причёску при позиционировании шляпы
true
4 Name (for language files other than English)
Наименование (для языковых файлов, отличных от английского)
Бейсболка

Если skipHairDraw "true", то игра не изменит прическу персонажа, когда он наденет шляпу. Если установлено значение "false", прическа игрока может измениться, когда он наденет шляпу.

Если для параметра ignoreHairstyleOffset установлено значение "true", это означает, что игра будет позиционировать шляпу независимо от прически вашего персонажа. Например, для такой шляпы, как Бант-бабочка, вы захотите установить его в положение "false", чтобы бант регулировал положение, которое будет прикреплено к выбранной прическе вашего персонажа. Однако для чего-то вроде повязки на глазу она должна оставаться в одном и том же положении на голове вашего персонажа независимо от того, какие волосы вы выбрали, поэтому для нее должно быть установлено значение "true".