Sign in to follow this  
UnderwearApp

Crockpot food too big and Plant Regrowth

Recommended Posts

UnderwearApp    172

Hello everyone!

 

I am trying to fix a couple of my mods from the latest updates and all is good except for the iced coconut is huge in the crockpot. See here:

 

(Sorry for the link, site says I can't embed Steam or Imgur so I gave up)

 

http://images.akamai.steamusercontent.com/ugc/419187061818621045/1B412FDAB927061581CB3ACFD6C26C4D40D40AE8/

 

Any ideas?

 

 

Also, can anyone explain what the new regrowth component applies to? It only causes crashes when I add it to the palm trees but is present in vanilla evergreens.

 

Thanks as always.

 

Prof

Edited by ProfFarnsworth

Share this post


Link to post
Share on other sites
DarkXero    2892

@ProfFarnsworth, does the coconut image have power of 2 dimensions?

If not, maybe that's what causes the issue.

 

The plantregrowth component makes evergreens, lumpy evergreens, and leafy trees, to expand, regrow.

But I think it should just not work for your stuff, not crash.

Share this post


Link to post
Share on other sites
UnderwearApp    172

@ProfFarnsworth, does the coconut image have power of 2 dimensions?

If not, maybe that's what causes the issue.

 

The plantregrowth component makes evergreens, lumpy evergreens, and leafy trees, to expand, regrow.

But I think it should just not work for your stuff, not crash.

 

Thanks DarkXero, the dimensions were 500 x 500 so I changed them to 512. Still the same issue.

 

So plantregrowth makes trees spread naturally? When I added it, it crashed due to nil reference at tuning_regrowth or something like that.

Share this post


Link to post
Share on other sites
DarkXero    2892

@ProfFarnsworth, yeah, definitely a nil somewhere, because TimeMultipliers doesn't have your prefab on it, and thus, InternalTimes wouldn't be able to generate a time for your prefab. So there's a nil floating there somewhere. Crashes on saving, at the least.

 

Also, I opened the crock pot food file. You should resize your coconut to something like that.

post-537485-0-30623600-1440697294_thumb.

  • Like 1

Share this post


Link to post
Share on other sites
UnderwearApp    172

@ProfFarnsworth, yeah, definitely a nil somewhere, because TimeMultipliers doesn't have your prefab on it, and thus, InternalTimes wouldn't be able to generate a time for your prefab. So there's a nil floating there somewhere. Crashes on saving, at the least.

 

Also, I opened the crock pot food file. You should resize your coconut to something like that.

Do you know how I can modify that table to include my trees without overwriting the file?

 

resize the image in your image editor.

I will try resizing the image, but I am not sure why this is an issue now when it used to work. By that I mean what changed that makes the game recognize the initial .png dimensions?

 

Thanks again both of you.

Share this post


Link to post
Share on other sites
UnderwearApp    172

@DarkXero

 

Resizing the image worked so thanks again. If you have any information about overwriting a table or a link, it would be appreciated. I have found some that pertains to overwriting a function in a component, would a table work the same way? i.e. Save the original and load the modified?

Share this post


Link to post
Share on other sites
DarkXero    2892

@ProfFarnsworth, if you copy and paste plantregrowth.lua into a components folder in your mod, it will overwrite completely the one in the game.

 

I suggest that you do that, but you rename your component into prof_plantregrowth. That way, if others do the same for their own plants, there won't be a conflict.

 

You would have a table for your prefabs.

local TimeMultipliers = {    ["coconut_tree"] = function()        return 1    end,}

And you would add the component prof_plantregrowth to your prefabs, and use the SetRegrowthRate, SetProduct, and SetSearchTag as if it were the original plantregrowth.

Share this post


Link to post
Share on other sites
UnderwearApp    172

@ProfFarnsworth, if you copy and paste plantregrowth.lua into a components folder in your mod, it will overwrite completely the one in the game.

 

I suggest that you do that, but you rename your component into prof_plantregrowth. That way, if others do the same for their own plants, there won't be a conflict.

 

You would have a table for your prefabs.

local TimeMultipliers = {    ["coconut_tree"] = function()        return 1    end,}

And you would add the component prof_plantregrowth to your prefabs, and use the SetRegrowthRate, SetProduct, and SetSearchTag as if it were the original plantregrowth.

 

Cool thanks again for the help. I'll give it a shot and see if it works.

 

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this