Okay so I'm trying to make a cool mod that when you kill a mob, there's a 20% chance you'll get a goodie bag(inspired by terraria's halloween event) and when you right click it, you'll get a random hat. Doesn't matter what hat. Please help me with this mod! I'll give you a heap of credit! Save a life today! The bag will have these items in it: (ATM) A ninja mask A water like hat. (I want that hat to make you invincible from water) A lava hat( makes you invulnerable from lava and makes you walk on it) A plague doctor's mask/ A jester's cap a Lampshade, (May or may not light up) a candelabra that lights up a ski mask A red masquerade ball mask A blindfold A fox mask A Witch hat. (Not wizard hat) An eyepatch Aviators A tie ninja. ( Wrapped tie around your head) A blue masquerade ball mask A penguin colored beanie A trilby A crusader helm White rimmed glasses Hylotl glasses Golden crown
You could use Pots - as a drop bag. [But not as much control] Check capsulebig as an example of a pot which drops items on destruction Or you could just drop the item directly by using drop loot Code: C:\Program Files (x86)\Steam\steamapps\common\Starbound\Assetunpacked\monsters\unique\giftmonster For example if you go to giftmosnter.monstertype It will say "Droppools" these pools are located here Code: C:\Program Files (x86)\Steam\steamapps\common\Starbound\Assetunpacked\treasure The syntax is [0.33, [ "money", 12] ] first number is chance the 2nd is the item 3rd is the amount
So if I do [0.3, ["skimask", 1], [0.3, ["jesterscap", 1] That would make it so it is possible to get one of those items if I place this one item is when you kill a mob, there's a small chance?
That would be 30% chance for each one. You can follow the examples given in the treasurepool file - its pretty straightforward to follow. You want to make sure duplication is off and you only run thorough the pool loop once.
First lets see the unique monster file Code: C:\Program Files (x86)\Steam\steamapps\common\Starbound\Assetunpacked\monsters\unique\aviansentry Code: { "type" : "aviansentry", "categories" : [ "aviansentry" ], "parts" : [ "body" ], "animation" : "aviansentry.animation", "projectiles" : "/monsters/projectiles.config", "colors" : "/monsters/colors.config", "dropPools" : [ "basicMonsterTreasure" ], <----- ..... truncated for sake of example it is saying it uses basemonstertreasurepool Which is here Code: C:\Program Files (x86)\Steam\steamapps\common\Starbound\Assetunpacked\treasure The we can see the code Code: [1, { "pool" : [ [0.36, [ "skimask", 1] ], [0.36, [ "jesterscap", 1] ], [0.18, [ "money", 25] ], [0.10, [ "alienmeat" ] ] ], "poolRounds" : [ [0.20, 0], [0.80, 1] ], "levelVariance" : [0, 0], "allowDuplication" : false } ], So now anytime you kill an avian sentry you have a 36% chance of getting a skimask in a level 1 planet. Since it uses "Basictreasurepool" any other monster that uses basic treasurepool will also drop it. So you would need to create its own unique treasurepool
Ok so if I want to make just the alien monsters drop the unique items, I will make a folder in my mod that says treasurepools and link it from there? That sounds really easy enough. Thank you for posting that, I'll be sure to make you in the thanks to folder!
How exactly will this look when it's in the folder, If you cannot describe it, please just make a download for it!
Wait a minute, the game crashed due to a duplicate monster called the fish, is there a way to bypass that?
It means you kept the file in the wrong folder. It has to be a mirror image of exactly the same location as of the original game, otherwise it won't replace the original file and think it is a different one
Let me rephrase this in my own words, So if I don't name the folder exactly called treasurepools and another called treasure? Then if I do that, Starbound won't crash.
When you are replacing \ modifying original files. It has to be exact. If you are creating your own file - you can put it where ever yo uwant
Wait, I'm getting a little confused here. Do I have to make the folder have a directory that says: mods/*mymod*/assets/unpacked/treasure/basic treasure? If that's wrong, can you tell me what to put? I'm truly confused.
No Your Modinfo file = points to your assets folder so if you put your mod info file path = "." that means where ever your modinfo filie = your assets folder. So in most cases it would be Code: starbound/mod/[mymod]/treasure