-- LUA Script - precede every function and global member with lowercase name of script + '_main' -- Player Collects food function food_init(e) Scale(e,300) end function food_main(e) RotateY(e,40) PlayerDist = GetPlayerDistance(e) if PlayerDist < 80 and g_PlayerHealth > 0 then PromptDuration("Collected food",3000) PlaySound(e,0) AddPlayerHealth(e) SetPosition(e,-1000,1000,-1000) end end