Frankenmoo

  • Content Count

    6
  • Joined

  • Last visited

Community Reputation

10 Good

About Frankenmoo

  • Rank
    Junior Member
...

Badges

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Enable
  1. So i essentially copied and pasted and i got an error to be specific when I introduced the last line that listens for the event it says "attempt to index 'global' (nill value ) local function hunger_heal (inst, data) if inst.components.hunger:GetPercent() < 80 then inst.components.health:StartRegen(50,5) else inst.components.health:StopRegen() end endinst:ListenForEvent("hungerdelta", onhungerchange)I understand pretty much everything you wrote but what is "hungerdelta" i thought the event that is being listened for is on hungerchange so im confused on what is "hungerdelta" Also is there a site that you can introduce me to that explains some of the things like Dodelta and inst is? Ive checked out the tutorials that the forums have but doesn't explains these things Thank you for everything
  2. So I'm basically trying to make it so that every 5 seconds you get healed for 50 (test) if you are full. The problem is it does nothing and idk why local function hunger_heal (inst, owner)if (owner.components.health and owner.components.health:IsHurt()) and (owner.components.hunger and owner.components.hunger.current > 5 )theninst.task = inst:DoPeriodicTask(1, owner.components.health:DoDelta(50) )end endthis is basically what im trying If you are hurt and are not hungry heal for 50 every second