Well I decided to start my first script. and everything was going good till I tried to run my script xd.
when I tried to run it i received this error

22:38 XenoScript Error:
Script: Hive 1.0.lua
Line #: 78
Chunk: C:\Users\Jorge E\Documents\XenoBot\Scripts\Hive 1.0.lua
Error: 'end' expected (to close 'function' at line 35) near '<eof>'
This is an error with user-input and should not be reported as a bug with XenoBot.

Here is my lua script

Code:
--[[ 

The Hive 1.0 / Last updated: 
Version 1.0
	
]]

--------- BP SETUP ----------
-- [BP 1] - Main
-- [BP 2] - Products
-- [BP 3] - Rares
-- [BP 4] - Gold

--------- DP SETUP ----------
-- [DP 1] - Products
-- [DP 2] - Rares

------ REFILL SETTINGS ------
local MinMana = 100 --- How many mana potions until you leave the hunt.
local MaxMana = 600 --- How many mana potions you begin the hunt with.
local MinHealth = 20 --- How many health potions until you leave the hunt.
local MaxHealth = 50  --- How many health potions you begin the hunt with.

--------- HUNT SETTINGS ---------
local GoldBP = 8860 --- Item ID of your gold backpack.
local MinCap = 100 --- Leaves spawn when character reaches this cap.

--------- EXTRA SETTINGS --------
local LogoutStamina = true --- Do you want to logout at 16 hours? (Inside the depot)

--- DON'T CHANGE ANYTHING BELOW THIS LINE ---

registerEventListener(WALKER_SELECTLABEL, "SelectLabel")

function SelectLabel(Label)
	if (Label == "checkPotions") then
		if (Self.Cap() > MinCap and Self.ItemCount(ManaId) > MinMana) then
			gotoLabel("Hunt")
		end
	elseif (Label == "checkPotions2") then
		print("Current Manas: " .. Self.ItemCount(ManaId) .. " / " .. MaxMana)
		if (Self.ItemCount(ManaId) < MaxMana) then
			gotoLabel("Bank")
		end
	elseif (Label == "depositGold") then
		local amount = (MaxMana-Self.ItemCount(ManaId))*ManaPrice
		setWalkerEnabled(false)
		Self.SayToNpc({"hi", "deposit all", "yes"}, 65)
		if (amount > 0) then
			Self.SayToNpc({"withdraw " .. amount, "yes", "balance"}, 65)
		end
	elseif (Label == "buyManas") then
		setWalkerEnabled(false)
		Self.SayToNpc({"hi", "vial", "yes", "magic"}, 65)
		wait(2000, 3700)
		if (Self.ItemCount(ManaId) < MaxMana) then
			Self.ShopBuyItemsUpTo(ManaId, MaxMana)
		end
                setWalkerEnabled(true)
	if (labelName == "depot") then 
                Walker.Stop()
                Self.DepositItems({14083, 0}, {14225, 0}, {3010, 0}, {14080, 0}, {14081, 0}, {238, 0}, {14076, 0}, {3027, 0}, {14079, 0}, {9057, 0}, {3032, 0})
                Self.DepositItems({3279, 1}, {8084, 1}, {14087, 1}, {14089, 1}, {3326, 1}, {14088, 1})
                if (LogoutStamina) and (Self.Stamina() < 960) then
			Walker.Stop()
		else
			Walker.Start()
		end
	elseif (labelName == "resetbp") then
		Walker.Stop()
		Container.Close(GoldBP)
		wait(1000)		
		Container.GetFirst():OpenChildren(GoldBP)
		wait(1000)
		Container.GetByName(GoldBP):Minimize()
		Walker.Start()	
	end
end
Hope some one can help me thank you !