Jehree added a new file:
QuoteDisplay MorePlease feel free to upload any case you create using this framework! You have my permission!
I took a commonly used custom case mod (this one) and modified it to connect everything to a config file, and added a few new features for good measure!
With this mod you can do the following things with only config settings and a few other simple folder path/ file edits:
- Create your own custom case that can have multiple separate cells similar to a rig.
- Set up a unique filter for one or more of the cells to allow them to hold different items than the rest of the case.
- An example of this would be a Documents Case that has a separate 1x1 cell that can hold a keytool.
- Pick your own trader, loyalty level, price, and currency (including simple 1 item barter trades) to balance how and when you can obtain your case.
- Choose if your case can be equipped in any equipment slots (Armband, backpack, etc).
- Push your case into included or excluded filters for vanilla items in the game
- i.e. decide if your case is allowed in secure containers, backpacks, specifically a SICC case, etc.
Example Case Included:
- The included case is a simple 3 cell 1x1x1 case that can be equipped to your armband slot.
Installation:
- Put the 'zCase Framework' folder in your user/mods folder.
- With that said, please review the 'Setting up your own case' and 'Understanding the Config' tabs for documentation on how to create multiple cases using this mod, setting up your bundle files and paths, etc.
- Also, I recommend making sure your case mods created using this framework keep a z in front of their name. Some mods like SVM work best if they are loaded before this mod.
[tabmenu]
Follow these steps to set up your own case:
- Copy the 'zCase Framework' folder and rename it to 'zYour Case Name'. I highly recommend keeping 'z' as the first letter to make sure it loads near to last in your mod list to avoid conflicts with AIO mods like SVM.
- Open the package.json file in the 'zYour Case Name' folder with a text editor and edit the "name": field to include your case name. This isn't required, but will stop the server from throwing duplicate mod warnings.
- Decide on an ID. This needs to be a unique name for the server to recognize your case. Open your 'zYour Case Name' folder and in config/config.json set the very first field, "id": to your ID.
- Using the Understanding the Config tab and the configREADME.json file, set up the settings for your case in the config.json file.
- Next, go into the 'zYourCaseName'/bundles folder and rename the CustomCase folder to the ID you decided on. (case sensitive!)
- Follow the Setting up your Bundle file tab instructions to get a Vanilla EFT item model set up for your case.
- If you are using a custom bundle file, you should be able to just place it in the bundles>'YourCaseIDHere' folder and rename it to case.bundle.
- Profit! You should now have your very own case that you designed with tons of tweakable options. Feel free to repeat this process as many times as you want for new cases, just make sure each time that you use a unique ID/ path to your bundle file. Feel free to upload your creations!
[tabmenu]
This framework is designed to make as much as possible configurable directly from the config file so you can design a case to suited your needs without needing to touch anything code related. More options could come in the future.
PLEASE NOTE: The configREADME.json file can be used as the actual config if you'd prefer to have the notes and settings next to each other. Simply delete/ rename the config.json file to something else, and rename the configREADME.json file to be "config.json" in its place.
Config options and what they do:
- "id"
- It is incredibly important that you set this option FIRST and then NEVER change it again to avoid future id conflict issues. This option will set the unique item ID for the server to use to identify it when loading trader assortments, your stash, etc. For those reasons, it is crucial that you pick something unique. It doesn't need to be crazy, just try to pick something similar to your case name. "Ammo_Pouch", "Attachment_Case_Big" , "Keytool_Level2" are all good examples. Once you have decided on an id, set it in the config and save it because we will be using it later when we set up our bundle file for the in game model for the case.
- "item_name", "item_short_name", "item_description"
- Self explanatory, these set the name, short name, and description of your item as it will be seen in game.
- "trader" and trader related options
- These options allow you to choose which trader can sell the item, at what loyalty level they will, for what price and currency/ barter trade, limit the stock, etc.
- For traders and currency, you can enter the trader or money type name in lower case in these config options. If you want to use a modded trader, add their trader id instead. If you want the currency to be an item and not money, add that item's id instead.
- Examples:
- "trader": "skier"
- "currency": "euros"
- "allow_in_slots"
- This option allows you to set one or more equipment slots that your case can be equipped to. This can be used to make cases that can be equipped in armband slots, weapon slots, etc. It can also be used to create new backpacks, or rigs (limited to only 1 row of cells).
- Review the configREADME.json for a list of equipment slots you can add here.
- If your case can be equipped to multiple of these three slots (SecuredContainer, TacticalVest, and Backpack), only the last one listed in your config will allow ctrl clicking into it when looting.
- Note about equipping your case regarding bundle files:
- If the slot you are equipping to renders on the player, using a bundle file that was originally made for that slot will cause it to render in the correct location.
- Example: If you want to make a case for your armband slot, using an armband bundle will cause it to actually render on your arm visually as that armband would. Search the EFT files for these bundles or the SPT AKI website for custom ones if (don't redistribute files without permission though), or create your own custom ones if you are savvy enough.
- "external_size"
- Self explanatory, set the external size of your case item.
- "internal_size"
- These options set up your case's internal cells/ their sizes. You can set up as many horizontal cells as you'd like here by separating them by commas. Think of these each comma separated number as size x by y of each cell.
- Example: setting it to look like this will produce a case with 3 1x1 cells:
"horizontal_cells": [1,1,1],
"vertical_cells": [1,1,1]
- "included_filter" and "excluded_filter"
- This is where you can set up what is allowed and disallowed from being placed in your case. Enter item ID's or parent ID's here to set up a case tailored to your needs.
- Note: leaving "included_filter" blank will default it to including everything. This means that if you leave both "included_filter" and "excluded_filter" fields blank, they will allow anything to be placed inside them.
- "cell_to_apply_filters_to" and the unique cell filter options
- These settings allow you to set up a unique filter for one or more of the cells of your case, allowing them to hold different items than the rest of the case
- Setting "cell_to_apply_filters_to" to be equal to 0 will disable this section if you are not interested in using it.
- "cell_to_apply_filters_to"
- If this field is equal to a number, that number will coordinate to the order of the cells of your case from left to right (1 = 1st, 2 = 2nd, so on).
- If you want multiple cells to inherit the unique filter, you can use a series of bracketed "y"s and "n"s instead. Example: ["y", "n", "y"] would make the 1st and 3rd cell take the unique filter, while the middle cell would take the default "included_filter" and "excluded_filter" settings.
- the "unique_included_filter" and "unique_excluded_filter" fields take item ID's or parent ID's the same as the standard "included_filter" and "excluded_filter" fields.
- "allow_in_secure_containers" and "allow_in_backpacks"
- Self explanatory, allows or disallows your case to be placed in secure containers and/or backpacks.
- "case_allowed_in" and "case_disallowed_in"
- These fields also are pretty self explanatory, add item ID's here to allow or disallow your case to be placed inside those items.
- Example: use these fields to make your case allowed to be placed inside a keytool.
- Note: only use item specific ID's here, parent ID's will not work.
[tabmenu]
These steps go through how to take take a model from the EFT assets folders and set it up as the model for your case:
Before picking a bundle file, consider if your case is able to be equipped to an equipment slot. If it is an armband case, for example, and you give it an IFAK model, then you will have an IFAK awkwardly sticking in your PMC's neck. If instead, you use an actual armband bundle, then it will render correctly on your player. This also works in the case of a backpack in your weapon slots, rig slot, etc.
So in short, if you want to be able to equip your case to a slot that shows on your PMC, try to pick a model that is supposed to be equipped.
- Find your bundle file and copy it
- The method I generally use is to search this website for the item with the bundle I want, and copy the bundle name from the "Prefab": "Path": section.
- Then, go to SPT-AKI>EscapeFromTarkov_Data>StreamingAssets>Windows>assets and use the windows search to find the file. CTRL+C or right click- copy the file.
- Paste your bundle file in the bundles>YourCaseIDHere folder of the mod, and rename it to case.bundle.
- Use this tool to generate new CAB ID's so your bundle will load along side the Tarkov item it was actually made for. Open the tool, go to file>open, find your case.bundle file and open it. Click 'Generate New CAB IDs', and your done. You can close the tool.
- In your custom case mod folder, open the bundles.json file
- The first thing to do here is make sure that the path in the "key": field is "YourCaseIDHere>case.bundle".
- Then, go to this site and search the original item your bundle is for. Copy the "dependencyKeys" and paste them in that same section of your bundles.json file.
- You're done!
Troubleshooting:
- If your case's icon is incorrect, but the model in the inspect view is fine, using the 'Clean Temp Files' in the SPT launcher settings should clear the cache and get that to update.
- If you inspect your case and there is no model there at all, there's a good chance your dependency keys are wrong. Double check that those are correct.
- If when inspecting the case you see a doge cube, double check that your case ID in the config, your bundles/'YourCaseIDHere' folder, and the path in "key": in the bundles.json are all matching.
[tabmenu]
Credits:
I used this mod as a base and modified it to create this framework, thank you to these peeps for contributing to that!