cfcohen Posted February 24, 2012 Share Posted February 24, 2012 Hello everyone, I'm new to modding Skyrim, but not so much for programming and game development in general. I'm primarily interested in crafting, game balance, realism and immersion mods. I've been playing with the Creation Kit for a week or two now, and still have some issues that I can't get to the bottom of. I'll try to make this topic a mixture of what I think I already know (but haven't seen posted), and questions about what I don't know in hopes that more people will read this and discuss it... :wink: The crafting equipment is defined as form=Furniture, type=Workbench. When editing the form, there's an opportunity to define which of the crafting menus opens (Bench Type) and which skill affects the result (Uses Skill), both of which are under "Workbench Data". The obvious bench types are "Enchanting" and "Alchemy". The "Smithing Armor" and "Smithing Weapon" types are for tempering armor and weapons respectively. The "Create Object" menu is for creating new objects and is used by the forge, tanning rack, cooking pot, and smelter by default. So far so good. Questions: Has anyone succeeded in getting the "Alchemy Experiment" and "Enchanting Experiment" to do anything? My attempts to use them resulted in no menu, and an inability to escape from the object without using the console. I assume it is not possible to create new bench types, and I'm not sure if you'd even need/want to -- has anyone? What do the isAlchemy, is Smelter, etc. keywords really do? The recipes themselves are stored as Constructible Object forms. There are fields for the created object and count, as well as a list of consumed items and their counts. The "Workbench Keyword" comes from a list of "CraftingXXX" keywords, which importantly determines which type of crafting workbench uses the recipe. For example, the recipe will only appear at cooking pots if the "CraftingCookpot" is select. Somewhat confusingly, these same keywords are present on the workbench furniture themselves, but don't seem to do anything important. It IS possible for armor recipies to appear at cook pots, cooking recipies at the smelter and so on. Finally, there's a set of "Match Conditions" that can be used to prevent recipes from appearing until a perk is obtained or specific requirement is met. This is used to sometimes hide recipes for which the player does not have the required components by calling GetItemCount. Questions: The recipies are pretty straight forward, so I have but a few questions... How does the CrafingXXX keyword get associated with the correct workbench type? Is it magic native code? A script that I can't find? Some relation with the "isXXX" keywords? Since there is no mechanism for differentiating between "Object Creation" recipies and "Tempering" recipes except that the latter use one of the tempering workbench types, I presume it is not possible mix and match tempering menus in the same way that items can be moved between the object creation menus for various workbench types. Questions: Has anyone suceeded in doing this? For those following closely, you've now figured out that by creating new workbench furniture and new recipes associated with that furniture, you can create arbitrary new crafting tools. Witness the excellent Crafting Complete mod. Now we get to the real details that have taken some digging. :wink: What determines where the recipe ends up in the object creation menu? The answer appears to be the "XXXMaterialXXX" keyword on the object that is created by the recipe. I would have found this much clearer if the keyword was on the recipe, but oh well. In particular, it is possible to move recipes around on the object creation menu by changing these types. For example, you can put leather and hide armor both under "LEATHER" in the forge menu. If you move dwarven armor creation to the cooking pot, the "DWARVEN" entry will appear in the leftmost part of the cooking pot menu. Questions: How are the material type keywords associated with the menus? Obviously, the names largely matche up, but I can see no programatic relationship. Has anyone managed to create new material type keywords and get them to do anything? My attempts have resulted in all new materials being listed under "MISC". If I change an armor from one material type keyword to another, what other places in the game will be affected? Who else other than the crafting code uses these keywords? I assume that it is not possible to create new material type keywords because there are not translation strings associated with the keyword itself, so there must be some other code required to make that happen (see next section). Does anyone know otherwise? At this point I was pleased to find that it was possible to "rebalance" the distribution of creation menus so that instead of having more than a dozen on the forge, and one each on the other crafting workbenches, it was possible to have a few on each. I was not pleased that the translation text of the crafting menus appeared to be fixed, since making Draugr items on the cooking pot does not sound yummy. As it turns out, the translations are not fixed. They're stored in the game settings as strings in the form sXXX, where XXX is the material type. Since there's no clear connection between the material type keywords and they're translations, I've had to flail a little to find what is probably still an incomplete list: Armor Materials: Daedric, Dragonplate, Dragonscale, Dwarven, Ebony, Elven, ElvenGilded, Glass, Hide, Imperial Heavy, Imperial Light, Imperial Studded, Iron, Iron Banded, Orcish, Scaled, Steel, SteelPlate, Stormcloak, and Studded. Weapon Materials: Daedric, Draugr, DraugrHoned, Dwarven, Ebony, Elven, Falmer, Falmer Honed, Glass, Imperial, Iron, Orcish, Silver, Steel, Wood Creation Menu Top-level Catgories (based on game settings that look suspiciously material like): Amber(?), Apparel(?), Daedric, Dragon, Draugr, Dwarven, Ebony, Elven, Falmer, Food, Glass, Hide, Imperial, Iron, Jewelry, Leather, Misc, Orcish, Repair(?), Steel, Studded, White(?), Wood It is possible to change these strings in the Game Settings menu, for example to make them mixed case, or perhaps more importantly to rename an unused category (Draugr? Falmer?) to something else (Arrows or Soups?). There are many inconsistencies, such as the merging of dragonplate and dragonscale, or light and heavy Imperial armors. Misc seem to have no material keyword, and is where all objects lacking a recognized keyword end up. Jewelry is apparently set by the "ArmorJewelry" keyword. Questions: How are the game setting translation strings determined from material keywords? Has anyone gotten Amber, Apparel, Silver, or White to appear in the object creation menu? Several of the material keywords are associated with the "MaterialsArmor" and "MaterialsWeapon" form lists. This would be an excellent candidate for somehow driving the determination of which keywords were material keywords, but sadly I can find no connection, and have been unable to even modify the list to conduct any tests. Questions: How do you modify a form list? Does anyone know what the material form lists are for? Has anyone modified it to achieve anythin useful? At this point I have almost everything I need/want for my crafting mod, execpt that there's not enough menu choices and corresponding material keywords. While I can probably squeeze by with reusing a few of the more esoteric matierals, I'd really like to be reasonbly free of such constraints. The near solution lies in finding a way to modify the translation strings dynamically during execution, perhaps by using a OnActivate() event papyrus script that relabels the categories when the player activates the crafting workbench. Then you could potentially rename the material types into MenuCat01, MenuCat02, etc. And label them "Soups", "Roasts", "Deserts", etc. in the cooking pot, "Leather", "Hide", "Studded", etc. in the tanning rack, and more like the defaults at forge. Obviously, an unlimited number of additional categories would be available for newly created crafting workbenches. Sadly it is not so. :( While the SetGameSeeting console command works perfectly, there does not appear to be anyway to script the desired behavior. MOST IMPOTANT Questions: Why the :wallbash: is there no SetGameSetting() papyrus call? How hard would it be to create one in SKSE? How would you go about doing it? Would SetINISetting work in any way? Can anyone else see a workaround to create new materials, relabel the menus, etc? And ultimately... How would a SkyUI rewrite affect all of this? Is all of the missing logic connecting the various pieces contained native code, a script, a flash UI app? If I dig into how SkyUI rewrote the inventory menu, and apply that to the create oject menu, will I eventually find the queries that get the menu strings, select the material keywords, etc? For some of the earlier questions, I can probably conduct yet more tests to get the answers myself, but for the last ones, I have absolutely no idea, and would greatly appreciate help. My guess is that anyone who know how SkyUI really works could tell me where to look to find answers for many of these questions, and I would be very grateful. Sorry for the "Lengendary" length rant, but I've been accumulating a lot of questions as I learned about how the existing crafting system really works. While I could have gotten to my real questions more directly, I hope this posting will be of value to others interested in crafting mods. A similar posting may follow shortly on tempering. Link to comment Share on other sites More sharing options...
ingraved Posted February 27, 2012 Share Posted February 27, 2012 From my experience the only way I know how to modify a FormList in the CK is to drag items into to add them and delete them with Delete key. Thats all I had the patience to reply on sorry Link to comment Share on other sites More sharing options...
cfcohen Posted February 28, 2012 Author Share Posted February 28, 2012 From my experience the only way I know how to modify a FormList in the CK is to drag items into to add them and delete them with Delete key. Thats all I had the patience to reply on sorry Thanks for responding ingraved. I obviously hadn't figured out dragging and dropping a keyword onto the form list. Does drag and drop work in a lot of places? I probably would have figured out to press delete if I'd been trying to delete something, but I never would have guessed that drag and drop was the right way to add an item. :confused: As for the patience, I surely understand -- it was a long post. In keeping with my plan to contribute in hopes of getting more views and answers, I'll offer my latest discoveries. The form list apparently has no impact on the displayed menus. Neither removing nor adding material keywords from the form list has an impact. I've confirmed that you can have all of the following menu items (simultaneously) on each of the four object creation devices (Cook Pot, Forge, Smelter and Tanning Rack): Wood, Hide, Draugr, Iron, Studded, Imperial, Steel, Leather, Dwarven, Elven, Falmer, Orcish, Ebony, Glass, Dragon, Daedric, Jewelry, Food, Misc This seems to confirm that they all use the same "object creation" menu code wherever that is. There are a few oddities however. For example, Falmer Armor shows up under Misc even if you associate the armor objects with the ArmorMaterialFalmer keyword. It's likely that this is just a bug in the code. Attaching WeapMaterialFalmer to the armor causes them to show up under the correct menu. The armor was originally marked as ArmorMaterialSteel in error. Also, there doesn't appear to be any customization of the tempering menus. Even if you associate a weapon tempering recipe with the armor workbench, it won't show, probably because there's a form type filter on the tempering device. Even after attaching the right/wrong material keywords, they won't show up. Everyone please read the original thread, and answer any questions if you're able, although with the inability to control which menu food shows under I'm less concerned about automatically changing the labels. :( Thanks again to ingraved for helping keep my thread alive. Link to comment Share on other sites More sharing options...
richmondb Posted March 23, 2012 Share Posted March 23, 2012 Hey great thread, I'm sorry I have nothing to contribute, but I wanted to say thank you for documenting everything you learned on this. I was able to catch up to where you are so m uch more quickly thanks to this thread. Thanks again. Link to comment Share on other sites More sharing options...
Milkmanic Posted March 24, 2012 Share Posted March 24, 2012 I wonder why that topic is not so popular. One of the most anoying things in the crafting system. And of course with so much weapon and armormods out there a very hot topic you might believe.I had expirienced the same issues like you. What i dont understand is, are the given menu options some sort of hardcoded? Or why is it that you cant add more to that exisiting list. And why is it that even in vanilla scaled armor that is tagged "hide02AA" is listed under steel in the menu. I also believe that in some sort of way the smithing perks have an impact on the keywords appropriate to each item but i dont see any reference that can be edited. i would but i cant and that keeps bugging me Link to comment Share on other sites More sharing options...
NovaCameron Posted March 30, 2012 Share Posted March 30, 2012 (edited) Actually you can add alchemy to that list. They all use the craftingmenu.swf I'm just looking into this on the side of my Crafting Overhaul. look at CraftSmithing.psc for the keywordlist, though this just deals with the keyword list and how it relates to the smithing skill. What intrigues me is the DOBJ DefaultObjectManager. It only links to the smelter and forge. Thought it may be nothing... Also there are IDLE _____root items. also wonder if it's limited there. EDIT: Yup DOBJ DefaultObjectManager holds the Keywords. I have no clue WHAT the DefaultObjectManager is though.... If we crack that I bet we can gain more control over the inner workings of the forge and smelter at least/ Edited March 30, 2012 by NovaCameron Link to comment Share on other sites More sharing options...
MoonSweets Posted March 31, 2012 Share Posted March 31, 2012 I'll surely need to re-read this first post but the information sounds great and very helpful, thank you very much for sharing it!As I'd like to change the cooking menu into something more like the alchemy/enchanting menus to be able to discover new recipes through the combination of ingredients (including several samples of a same food ingredient) I assume I'll get a better idea of how to do it. Link to comment Share on other sites More sharing options...
FOenthusiast Posted April 1, 2012 Share Posted April 1, 2012 I downloaded a combine potions mod made by savagemoonlight, but all the work still shows under Misc in the cooking pot. When I opened it up in the CK I found (after copying savagemoon's work) that if the "Food" checkbox is checked then it won't show up in "Misc," but in "Food." This I'm sure is not too surprising to most reading this, after-all most everyone who commented here knows that you can get any constructible object under any EXISTING category. So I think creating or renaming a category probably lies beyond the immediate capabilities of the CK. Anyway, I think the point is that without someone with great computer skill and perhaps even the proper resources, we may just be out of luck. Is there any evidence to the contrary? Does anyone know of ANY mod that has effected the crafting menus? Also, what about other menus? I know that there are plenty of mods that effect other menus. If one could be manipulated, (or a new one made altogether) perhaps it could activated at a workbench. I don't even know where to start with this, just a thought to through out there. Link to comment Share on other sites More sharing options...
shadevar Posted April 15, 2012 Share Posted April 15, 2012 I've tried to look for this myself, with no luck. It does appear that crafting keywords for categories are hardcoded.I also looked at the source code for CraftingMenu.swf but all I could find was a reference to a categories list from which the menu is built, which I assume comes out of the DOBJ.You can see the DOBJ in the Gameplay menu of the CK ("Default Objects"), where you can alter the value of keyword entries, but you can't add any new ones. There are also 2 FormLists linked to the DOBJ: MaterialsArmor and MaterialsWeapons, but adding any new category keywords to these lists did not add the categories to the game for me, so there must still be a hardcoded function in between or I am still missing something. The keyword for Falmer armor is not in the MaterialsArmor list, so that's probably why the above poster could not see Falmer Armor show up as a category. I haven't tested yet if Falmer would be recognized by adding it to the list. I did however manage to simulate a sort of menu management using different furnitures. I created new furnitures and added a custom keyword to those, then linked recipes to those furniture keywords instead. This took the recipe out of the original furniture and made it craftable in the new furniture menu. For example, at first I had made soulgems craftable at the forge. I then created a new furniture called Gem Cutter, took the soulgem recipes, and changed their related furniture keyword to the Gem Cutter instead. This made them not show up in the Forge menu anymore, but they did show up in the Gem Cutter menu and were perfectly craftable. The items still show in their original keyworded categories (i.e Misc, Iron, etc) but you do achieve some form of list management that works if you're willing to create different furnitures. For myself, to save space and keep immersion, I scaled these furnitures to a small size and put them on a shelf or on top of the original furniture, for instance my Gem Grinder is now a small dwemer looking contraption placed on the tabletop of an enchanting furniture. What you have to do to make this work is create a copy of an existing furniture (I took the Blacksmith Anvil). The important part is that the original furniture's keywords are preserved EXCEPT for the keyword that starts with Crafting. E.g. for the anvil, the keywords are: FurnitureSpecial, FurnitureForce3rdPerson, CraftingSmithingForge, WICraftingSmithing, isBlackSmithAnvil. The WICraftingSmithing keyword seems to determine which menu needs to be shown, while the CraftingSmithingForge keyword determines the list that will populate the menu based on linked recipes. Remove CraftingSmithingForge from the furniture and replace it with you own keyword, then link all recipes you want to craft on this furniture to your new keyword. I also found that if you remove IsBlackSmithAnvil (or IsBlackSmithForge) this will break the crafting menu (it crashed the game for me when I used the linked furniture) - so whatever kind of crafting furniture you make, the game must think that it the original furniture linked to the menu you're showing for this to work. Hope this helps. Link to comment Share on other sites More sharing options...
eltucu Posted April 15, 2012 Share Posted April 15, 2012 My half educated guess is that the names themselves arent hardcoded but the amount of memory they use (the record size), since it isnt dynamic but a fixed size, you cant add more categories. So either they're into the ESM and have a fixed size, or they're in the .exe. It does looks weird that they would integrate such element at the engine level rather than leaving it to some higher level, like say, items or actors that can be modified, added, removed, etc without trouble. Hell, at first i had thought that the whole crafting system was made solely with papyrus and that they had embellished the messageboxes that you could display with Oblivion's/FO3's scripting language. Link to comment Share on other sites More sharing options...
Recommended Posts