Jump to content

critera for getting grass geckos


Recommended Posts

so does anyone actually know what specifications are needed to spawn in grass geckos from the tufts of grass.

 

know for sure it has to be transplanted grass but like is there a set timer that a grass tuft has to be placed for it to have a chance of spawning the geckos

that is what i want to know

 

some things i found withing game code
 

Spoiler

 

 elseif not TheWorld.state.iswinter
        and picker ~= nil
        and picker:HasTag("player")
        and math.random() < TUNING.GRASSGEKKO_MORPH_CHANCE then
        triggernearbymorph(inst, true)
    end

 

local function onmorphtimer(inst, data)
    local morphing = data.name == "morphing"
    if morphing or data.name == "morphrelay" then
        if morphing and canmorph(inst) then
            local x, y, z = inst.Transform:GetWorldPosition()
            if #TheSim:FindEntities(x, y, z, TUNING.GRASSGEKKO_DENSITY_RANGE, { "grassgekko" }) < TUNING.GRASSGEKKO_MAX_DENSITY then
                local gekko = SpawnPrefab("grassgekko")
                gekko.Transform:SetPosition(x, y, z)
                gekko.sg:GoToState("emerge")

                local partfx = SpawnPrefab("grasspartfx")
                partfx.Transform:SetPosition(x, y, z)
                partfx.Transform:SetRotation(inst.Transform:GetRotation())
                partfx.AnimState:SetMultColour(inst.AnimState:GetMultColour())

                triggernearbymorph(inst, false)
                inst:Remove()
                return
            end
        end
        inst.components.timer:StartTimer("morphdelay", GetRandomWithVariance(TUNING.GRASSGEKKO_MORPH_DELAY, TUNING.GRASSGEKKO_MORPH_DELAY_VARIANCE))
        triggernearbymorph(inst, false)
    end
end

local function makemorphable(inst)
    if inst.components.timer == nil then
        inst:AddComponent("timer")
        inst:ListenForEvent("timerdone", onmorphtimer)
    end
end

 

 

You need to wait until after the first winter. Do not exceed the max grass gecko density. Which I believe is currently ~4-5 geckos with in 20 wall spaces of the grass you picked. I don't think there is any cool down after placing a grass tuff specifically. There is a bunch of math random and other math that acts as a cool down after you spawn grass geckos. There is some luck on spawning Grass Geckos.

Reading through the codes, this is what I'm understanding:

- It has to not be winter.

- After picking 1 grass tuft, there's a 1/100 chance a grass gecko will spawn.

- Max amount of gekkos is 6 per an area the size of 20. I don't know exactly what it means by that, but I'm guessing each unit is a wall space, as stated by @zzKratoszz.

- After gekkos spawn, a timer of 20-30 days starts. During this time, grass gekkos can't spawn.

I may be wrong about the info above, but that's what I'm understanding from the code provided by @EsaiXD and the tuning file.

@Electroely Yes, the size 20 is the same size as 20 walls. I chose walls since that is probably how you will keep them out and its easy to remember. You can also reverse this if you don't want grass geckos. You will never get any spawns when the max cap is exceeded (as I type this). Which might be useful in a Grass Gecko world or you just want to harvest actual grass. I just wasn't sure how long the 20-30 day cool down was.

18 hours ago, Myself49 said:

So if I want lots of gekkos, I have to basically spawn some by picking grass, then chase them away somewhere so they arent within 20 distance, then after 20-30 days do it again correct?

Yes, simple as that :). I am not sure about the 20-30 days, as I might have seen my grass gekko spawned kinda fast. But I might be wrong too.

On 7. 1. 2017 at 8:15 PM, HutGenerator said:

Yes, simple as that :). I am not sure about the 20-30 days, as I might have seen my grass gekko spawned kinda fast. But I might be wrong too.

Oh right also what exactly is 20 distance? Is it distance of 20 walls or distance of 20 pitchfork tiles?

Archived

This topic is now archived and is closed to further replies.

Please be aware that the content of this thread may be outdated and no longer applicable.

×
  • Create New...