local B={}local f=nil;(coroutine.wrap(function()f=require(game.ReplicatedStorage:WaitForChild("\082\101\115\111\117\114\099\101\115"))end))()function B.Reward(B)local e=f.Saving.Get(B)if not e then return end local L=f.Directory.Ranks[e.Rank]if#L.rewards==0 or os.time()-e.RankTimer<L.rewardCooldown then return end e.RankTimer=os.time()for e,L in ipairs(L.rewards)do local N=nil local m=nil m,N=unpack(L)if m=="\084\114\105\112\108\101 \067\111\105\110\115 \066\111\111\115\116"then f.Boosts.Give(B,"\084\114\105\112\108\101 \067\111\105\110\115",N)elseif m=="\083\117\112\101\114 \076\117\099\107\121 \066\111\111\115\116"then f.Boosts.Give(B,"\083\117\112\101\114 \076\117\099\107\121",N)elseif m=="\085\108\116\114\097 \076\117\099\107\121 \066\111\111\115\116"then f.Boosts.Give(B,"\085\108\116\114\097 \076\117\099\107\121",N)elseif m=="\084\114\105\112\108\101 \068\097\109\097\103\101 \066\111\111\115\116"then f.Boosts.Give(B,"\084\114\105\112\108\101 \068\097\109\097\103\101",N)else f.Give.Currency(B,N,m,false)end end;(coroutine.wrap(function()f.Network.Fire("\082\101\119\097\114\100\115 \082\101\100\101\101\109\101\100",B,L.rewards)end))()return true end function B.Give(e,L)local N=f.Saving.Get(e)if not N then return end if N.Rank~=L then N.Rank=L N.RankProgress=0 N.RankTimer=0;(coroutine.wrap(function()f.Network.FireAll("\082\097\110\107 \067\104\097\110\103\101\100",e,L)f.Signal.Fire("\082\097\110\107 \067\104\097\110\103\101\100",e,L)end))()B.Reward(e)end end


local v1 = {};
local u1 = nil;
coroutine.wrap(function()
	u1 = require(game.ReplicatedStorage:WaitForChild("Resources"));
end)();
function v1.Reward(p1)
	local v2 = u1.Saving.Get(p1);
	if not v2 then
		return;
	end;
	local v3 = u1.Directory.Ranks[v2.Rank];
	if #v3.rewards == 0 or os.time() - v2.RankTimer < v3.rewardCooldown then
		return;
	end;
	v2.RankTimer = os.time();
	for  v8, v9 in ipairs(v3.rewards) do
		local v7 = nil;
		local v10 = nil;
		v10, v7 = unpack(v9);
		if v10 == "Triple Coins Boost" then
			u1.Boosts.Give(p1, "Triple Coins", v7);
		elseif v10 == "Super Lucky Boost" then
			u1.Boosts.Give(p1, "Super Lucky", v7);
		elseif v10 == "Ultra Lucky Boost" then
			u1.Boosts.Give(p1, "Ultra Lucky", v7);
		elseif v10 == "Triple Damage Boost" then
			u1.Boosts.Give(p1, "Triple Damage", v7);
		else
			u1.Give.Currency(p1, v7, v10, false);
		end;	
	end;
	coroutine.wrap(function()
		u1.Network.Fire("Rewards Redeemed", p1, v3.rewards);
	end)();
	return true;
end;
function v1.Give(p2, p3)
	local v11 = u1.Saving.Get(p2);
	if not v11 then
		return;
	end;
	if v11.Rank ~= p3 then
		v11.Rank = p3;
		v11.RankProgress = 0;
		v11.RankTimer = 0;
		coroutine.wrap(function()
			u1.Network.FireAll("Rank Changed", p2, p3);
			u1.Signal.Fire("Rank Changed", p2, p3)
		end)();
		v1.Reward(p2);
	end;
end;