kusa Posted December 11, 2013 Share Posted December 11, 2013 Hey there,first, it's my first mod so please don't blame me for a mistake, which is pretty easy to fix.Also, english is not my native language and I'm sorry for my mistakes.Well, here's my problem: I wanted to create my own recipe for "jam". The ingredients should be 3 berries or berries_cooked and 1 pomegranate or pomegranate_cooked.Attache is my code for the modmain.lua.It already crashes when i enable the mod.I will also attach my log.txt, which doesnt help me at all, but maybe will help you. Thanks in advance,kusaPrefabFiles = { "jam",}STRINGS = GLOBAL.STRINGSRECIPETABS = GLOBAL.RECIPETABSRecipe = GLOBAL.RecipeIngredient = GLOBAL.IngredientTECH = GLOBAL.TECH--GLOBAL.STRINGS.NAMES.JAM = "Jam" local harvestspice = GLOBAL.Recipe("harvestspice", { Ingredient("seeds", 1)}, RECIPETABS.REFINE, TECH.NONE) harvestspice.atlas = "images/inventoryimages/harvestspice.xml" AddIngredientValues({"pomegranate"}, {pomegranate=1}) local jam = { name = "jam", test = function(cooker, names, tags) return (names.berries or names.berries_cooked) and names.pomegranate and not tags.meat end, priority = 5, weight = 1, foodtype="VEGGIE", health = TUNING.HEALING_MED, hunger = TUNING.CALORIES_MED, sanity = TUNING.SANITY_MED, perishtime = TUNING.PERISH_SUPERSLOW, cooktime = 2, } AddCookerRecipe("cookpot",jam) local wetgoop = { name = "wetgoop", test = function(cooker, names, tags) return true end, priority = -2, weight = 1, health=0, hunger=0, perishtime = TUNING.PERISH_FAST, sanity = 0, cooktime = .25, } log.txt Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/ Share on other sites More sharing options...
kusa Posted December 12, 2013 Author Share Posted December 12, 2013 I looked into it some more today and finally did it, i believe.I can cook something with my ingredients but there's no pic, maybe because i used the pics and code of Camp Cuisine: A Thankful Harvest, which i have disabled :/It still crashes when i try to spawn it using DebugSpawn ("jam")... Hope you can help me,kusa Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/#findComment-388203 Share on other sites More sharing options...
kusa Posted December 12, 2013 Author Share Posted December 12, 2013 Changed a bit stuff here and there, but it still crashes now with another error in the log.txt:lua_gc took 0.01 seconds~SimLuaProxy()lua_close took 0.01 secondsReleaseAllReleaseAll FinishedcGame::StartPlayingLOADING LUADoLuaFile scripts/main.luaDoLuaFile loading buffer scripts/main.luascripts/main.lua(151,1) running main.lua scripts/modindex.lua(257,1) loaded modindex scripts/modindex.lua(57,1) ModIndex: Beginning normal load sequence. scripts/mods.lua(141,1) Loading mod: modleo-1 (Jam) (Old API! (mod: 3 game: 4) ) scripts/mods.lua(165,1) Mod: modleo-1 (Jam) Loading modworldgenmain.lua scripts/mods.lua(173,1) Mod: modleo-1 (Jam) Mod had no modworldgenmain.lua. Skipping. scripts/mods.lua(165,1) Mod: modleo-1 (Jam) Loading modmain.lua scripts/mods.lua(255,1) Mod: modleo-1 (Jam) Registering prefabs scripts/mods.lua(261,1) Mod: modleo-1 (Jam) Registering prefab file: prefabs/jam scripts/mods.lua(265,1) Mod: modleo-1 (Jam) jam scripts/mods.lua(278,1) Mod: modleo-1 (Jam) Registering default mod prefab Could not load texture ../mods/modleo-1/images/inventoryimages/challa.texBreak at: c:\jenkins\workspace\jobs\DontStarve_Release_Make_Steam_Package\workspace\source\util/resourcemanager.h(142) :It says old API, even though i set the API in the modinfo.lua = 4...and for the "Could not load texture ../mods/modleo-1/images/inventoryimages/challa.tex", as i said already i'm using the A Thankful Harvest mod to get started (there were some crockpotrecipes in the mod). I don't even know where the challa.tex file is being needed, since i already changed every challa with a jam and renamed the challa.tex to jam.tex. In the jam.xml i changed the challa.tex to jam.tex... Thanks for helping me! Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/#findComment-388400 Share on other sites More sharing options...
kusa Posted December 12, 2013 Author Share Posted December 12, 2013 It finally doesn't crash anymore, didnt know what went wrong...But it say To be enabled in the mod page and when i start a game to try out the recipe I always get wet goop... here is my modmain.lua:PrefabFiles = { "jam",}STRINGS = GLOBAL.STRINGSRECIPETABS = GLOBAL.RECIPETABSRecipe = GLOBAL.RecipeIngredient = GLOBAL.IngredientTECH = GLOBAL.TECH--GLOBAL.STRINGS.NAMES.JAM = "jam"AddIngredientValues({"pomegranate"}, {pomegranate=1})AddIngredientValues({"pomegranate_cooked"}, {pomegranate=1}) local jam = { name = "jam", test = function(cooker, names, tags) return (names.berries or names.berries_cooked) and (names.pomegranate or names.pomegranate_cooked) and tags.sweetener and names.twigs and not tags.meat end, priority = 10, weight = 1, foodtype="VEGGIE", health = TUNING.HEALING_MED, hunger = TUNING.CALORIES_MED, sanity = TUNING.SANITY_MED, perishtime = TUNING.PERISH_SUPERSLOW, cooktime = 1, } AddCookerRecipe("cookpot",jam) Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/#findComment-388425 Share on other sites More sharing options...
kusa Posted December 13, 2013 Author Share Posted December 13, 2013 I figured it out myself Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/#findComment-388990 Share on other sites More sharing options...
Morgan17 Posted December 13, 2013 Share Posted December 13, 2013 Talking to noone, eh? Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/#findComment-388995 Share on other sites More sharing options...
kusa Posted December 13, 2013 Author Share Posted December 13, 2013 So you too, he? Nah, just wanted to let possible helpers know, that i already fixed that xD Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/#findComment-389014 Share on other sites More sharing options...
seronis Posted December 14, 2013 Share Posted December 14, 2013 (edited) first time i've had a chance to browse this thread. was the solution changing the 'priority = 10' to something higher than wet goops priority? I havent messed with any recipes yet but would be useful to know solution in case i run into same problem in future Edited December 14, 2013 by seronis Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/#findComment-389126 Share on other sites More sharing options...
Rosten Posted December 14, 2013 Share Posted December 14, 2013 first time i've had a chance to browse this thread. was the solution changing the 'priority = 10' to something higher than wet goops priority? I havent messed with any recipes yet but would be useful to know solution in case i run into same problem in futureI was a little confused to what the hell the harvest spice thing was, that might have been the problem Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/#findComment-389131 Share on other sites More sharing options...
kusa Posted December 14, 2013 Author Share Posted December 14, 2013 first time i've had a chance to browse this thread. was the solution changing the 'priority = 10' to something higher than wet goops priority? I havent messed with any recipes yet but would be useful to know solution in case i run into same problem in futureNo that wasn't it, I will explain it later i g2g now :/ I was a little confused to what the hell the harvest spice thing was, that might have been the problemYeah as i said i used the A Thankful Harvest mod, and messed a bit around. i failed to delete all the stuff i didn't need. That was only one part of my problem I also missed some stuff in the modinfo.lua, modmain.lua and the jam.xml... Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/#findComment-389266 Share on other sites More sharing options...
kusa Posted December 14, 2013 Author Share Posted December 14, 2013 first time i've had a chance to browse this thread. was the solution changing the 'priority = 10' to something higher than wet goops priority? I havent messed with any recipes yet but would be useful to know solution in case i run into same problem in futureI can upload my files if you want to have a look into them My mod is working fine, except for when i drop my jam, i can't see it D: I can still pick it up using the spacebar. I also added an inventoryimage for it :3 Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/#findComment-389385 Share on other sites More sharing options...
Rosten Posted December 14, 2013 Share Posted December 14, 2013 Your probably missing a ground_jam or just a jam in your anim folder Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/#findComment-389492 Share on other sites More sharing options...
kusa Posted December 15, 2013 Author Share Posted December 15, 2013 Your probably missing a ground_jam or just a jam in your anim folderYeah i know that, but I don't know how i creat the .bin files and the atlas-0.tex file and so on :/ Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/#findComment-389540 Share on other sites More sharing options...
Rosten Posted December 15, 2013 Share Posted December 15, 2013 (edited) Yeah i know that, but I don't know how i creat the .bin files and the atlas-0.tex file and so on :/The don't starve mod tools autocompiler will automatically create the anim.zips for you provided with a exported -> jam -> jam -> jam.png, jam.scmlonce you get the spriter file working just use the autocompiler and it will make the anims and place them in the right folder for you, if you'd like some help with that, supply me with a download of the mod and ill do it for you Edited December 15, 2013 by Blazingice26 Link to comment https://forums.kleientertainment.com/forums/topic/30341-need-help-with-my-first-mod/#findComment-389547 Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now