FreeSpirit

  • Content Count

    13
  • Joined

  • Last visited

 Content Type 

Profiles

Forums

Downloads

Klei Bug Tracker

Game Updates

Hot Lava Bug Reporter

Posts posted by FreeSpirit


  1. I have a mod of my own that I'm trying to redraw the graphics on as they were in need for a remake. But when I put them in and check it out in game just to see how it looks, they appear fuzzy and have a slight white outline on them as well as noticeable tints of a color in squares around the textures.

     

    It only looks fine when it's zoomed in a lot in game. So I don't know if it's because the outlines are too thin or there's an issue with transparency.

     

    Here's a couple of screenshots:

     

    This one is after selecting my mod which shows a very close up version of it, which looks pretty ok to me.

     

    But when in game, it looks like this and makes it hardly distinguishable.

     

    Zooming in on it makes you see his face a lot better.

     

    Any help/advice?


  2. @FreeSpirit,

    Rain only makes crops from farms grow faster.

    It doesn't affect berry bushes.

    Rain is necessary for mushrooms to grow back.

     

    "Plants" is ambiguous, because they grow differently.

    Berry bushes don't need light to replenish berries.

    Farms do need light to grow the crop.

     

    So, which plants are you talking about?

     

    I was referring saying how when you have night vision, you spawn a light that has a radius of how far the light illuminates. For the ability I want this character to have, I want to have the effect be in a radius of space around it than say have it affect the entire world (like say within 30 feet from your character).

     

    As for "plants", I am just pointing to all things that grow over time, that being: Grass, Saplings, Reeds, etc.

     

    For example, if I want a few of things to grow twice as fast, I could put it as:

    GLOBAL.TUNING.BERRY_REGROW_TIME = (GLOBAL.TUNING.BERRY_REGROW_TIME * 0.5)GLOBAL.TUNING.GRASS_REGROW_TIME = (GLOBAL.TUNING.GRASS_REGROW_TIME * 0.5)GLOBAL.TUNING.SAPLING_REGROW_TIME = (GLOBAL.TUNING.SAPLING_REGROW_TIME * 0.5)GLOBAL.TUNING.REEDS_REGROW_TIME = (GLOBAL.TUNING.REEDS_REGROW_TIME * 0.5)GLOBAL.TUNING.FLOWER_SPAWN_TIME = (GLOBAL.TUNING.FLOWER_SPAWN_TIME * 0.5)

    I want this as an ability for a character that only affect "plants" around it within a set distance near it, and not the entire world.


  3. @DerpTime, no, that code what it does is the following:

     

    When a Coraline prefab gets initialized, the master_postinit gets ran to create the prefab, and modifies the tuning table values.

    Each Coraline that joins will make the values shorter, given the recursive definition there.

     

    This effect is not wanted.

     

    @FreeSpirit, what do you mean by plant growth?

    When your character runs near a bush, berries pop, or if it stands near a bush, berries will pop up in 2 days instead of 3?

     

    Also, what is the complete list of things affected by this?

    Because farms have the grower component, and bushes the pickable one.

     

    Something like that. Think of it as how rain gives a bonus to plant growth and makes takes them less time to grow. I want the character to give off like an "aura" that gives a bonus to plants near it within a certain range, much like having "night vision" where you can change how large the circle of light can be but have a circle of effect that affect plants in this case.

     

    I was also contemplating on having this character also have the ability to negate the effect of replanting stuff, making for example replanted berry bushes still act as if they haven't been replanted through the use a custom item only it can make.


  4. As the title says, I was wondering if it's possible to make a character that has the ability to affect the growth rate of plants such as berries/farms/etc. within a certain range but only affect the client (or host if the host is using that character).

     

    I tried making a mod to test out a few things (before seeing if it can be implemented into a character) like changing things such as "GLOBAL.TUNING.BERRY_REGROW_TIME" but it seems to affect all players if the host has it enabled.

     

    Any possible help?


  5.  

    Should be this, I think:

    local function updateHungerRate(inst, mult)       inst.components.hunger:SetRate(mult*TUNING.WILSON_HUNGER_RATE)end inst:WatchWorldState( "startday", function() updateHungerRate(inst, 1.5) end )inst:WatchWorldState( "startdusk", function() updateHungerRate(inst, 1) end )inst:WatchWorldState( "startnight", function() updateHungerRate(inst, 0.5) end )

     

     

    It works, but when you enter the world (joining or hosting), it does not come into effect until the next phase of time. So if I made a brand new world which starts you during the day, it does not go into effect until dusk.

     

    I tried changing the "startday" to "isday" but it didn't still didn't go into effect immediately.


  6.  

    Try something like this:

    local function updateHungerRate(inst)   if TheWorld.state.isday then      inst.components.hunger:SetRate(1.5*TUNING.WILSON_HUNGER_RATE)   end   elseif TheWorld.state.isdusk then      inst.components.hunger:SetRate(1*TUNING.WILSON_HUNGER_RATE)   end   elseif TheWorld.state.isnight then      inst.components.hunger:SetRate(0.5*TUNING.WILSON_HUNGER_RATE)   endendinst:ListenForEvent( "dusktime", function() updateHungerRate(inst) end , GetWorld())inst:ListenForEvent( "daytime", function() updateHungerRate(inst) end , GetWorld())inst:ListenForEvent( "nighttime", function() updateHungerRate(inst) end , GetWorld())

     

    It didn't work when I first pasted that in, but easily fixed it by removing the excess "end" lines:

    local function updateHungerRate(inst)	   if TheWorld.state.isday then	  inst.components.hunger:SetRate(1.5*TUNING.WILSON_HUNGER_RATE)   elseif TheWorld.state.isdusk then	  inst.components.hunger:SetRate(1*TUNING.WILSON_HUNGER_RATE)   elseif TheWorld.state.isnight then	  inst.components.hunger:SetRate(0.5*TUNING.WILSON_HUNGER_RATE)   endendinst:ListenForEvent( "dusktime", function() updateHungerRate(inst) end , GetWorld())inst:ListenForEvent( "daytime", function() updateHungerRate(inst) end , GetWorld())inst:ListenForEvent( "nighttime", function() updateHungerRate(inst) end , GetWorld())

  7. Thanks a lot! It no longer crashes the game when running with DFV.

     

    I do have another question regarding another line of code but I don't want to make another topic/thread. So I'll post it here.

     

    I have a function to give a player a slower hunger drain during the night, but a faster hunter drain during the day (both are separate), but I do not know where to place this line of code in the prefabs file to have it activate/deactivate:

     

    [codesyntax]inst:ListenForEvent( "nighttime", function() [code GOES HERE] end, GetWorld() )[/codesyntax]

     

     

    I found that snipit for someone trying to add Night Vision to their character and another member posted that to help with it activating during the night and then deactivating it during the day. But I would like it to be used for the function I want to give it above as I mentioned.


  8. I'm trying to port over a character (for just me and a friend) originally made for Don't Starve that was also compatible with Reign of Giants over to DST, but I managed to get everything working except for one particular thing.

     

    In the modmain.lua, I noticed this particular section of code was meant to give the character double the hunger value for meats:

     

    GetPlayer = GLOBAL.GetPlayerAddComponentPostInit("edible", function(Edible, inst)local oldGetHunger = Edible.GetHungerfunction Edible:GetHunger(eater)    local multiplier = 1    local character = GetPlayer()    if character:HasTag("lovesMeat") then        if self.foodtype == "VEGGIE" or self.foodtype == "SEEDS" then            multiplier = 1        elseif self.foodtype == "MEAT" then            multiplier = 2        end    end    return (multiplier * oldGetHunger(self, eater))endend)

     

    I want to get that over to the script/prefabs lua file. But I don't know how to exactly. The character runs perfectly fine and works with that left in the modmain file but it conflicts with the Display Food Values mod and ends up crashing the game.

     

    Any help would be appreciated!