--BROUGHT TO YOU BY RobloxScripter.com!--
-- services.
local game = game;
local getService = game.GetService;
local workspace = getService(game, 'Workspace');
local players = getService(game, 'Players');
-- client&indexing.
local client = players.LocalPlayer;
local clientGuis = client.PlayerGui;
local destroy = game.Destroy;
local isA = game.IsA;
local findFirstChild = game.FindFirstChild;
-- remove annoying buying effects.
local itemGainedScript = findFirstChild(clientGuis.ItemGained, 'LocalScript', true); -- Recursive because im lazy (〃▽〃)
if itemGainedScript then
destroy(itemGainedScript);
end;
clientGuis.DescendantAdded:Connect(function(c) -- Not going to bother with indexing a signal
if c.Name == 'NoChestAnimation' or (isA(c, 'LocalScript') and c.Parent.Name == 'DisplayGainedItem') then
task.defer(destroy, c);
end;
end);
-- calculate gold? friend said you had to divide by 60 idk.
local gold = client.Data.Gold;
local calculatedGold = gold.Value / 60;
gold.Changed:Connect(function(v)
calculatedGold = v / 60;
end);
-- funny while true do!
local buy = workspace.ItemBoughtFromShop;
local invoke_server = buy.InvokeServer;
while true do
pcall(invoke_server, buy, 'Winter Chest', calculatedGold); -- Due the game actually erroring, Gift4 goofy ass shit ?
task.wait();
end;