#Slot Selections
1 messages · Page 1 of 1 (latest)
Next time show the code lol
plz dont spam your question in every channel #📜︱scripting message
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local checkSlotData = ReplicatedStorage:WaitForChild("CheckSlotData")
local loadSlot = ReplicatedStorage:WaitForChild("LoadSlot")
local slotFolder = script.Parent:WaitForChild("Slots")
for _, slotButton in ipairs(slotFolder:GetChildren()) do
if slotButton:IsA("TextButton") or slotButton:IsA("ImageButton") then
slotButton.MouseButton1Click:Connect(function()
local slotNumber = slotButton.Name -- "Slot1", "Slot2", etc
-- Ask server if data exists
local hasData = checkSlotData:InvokeServer(slotNumber)
if hasData then
-- Load into game
loadSlot:FireServer(slotNumber)
else
-- Open character creation menu
script.Parent.Visible = false
game.Players.LocalPlayer.PlayerGui.MainMenu.CharacterCreation.Visible = true
end
end)
end
end
Thats the first script
this is the second