I have a problem with this script;
local button = script.Parent
local HatchingFrame = script.Parent.Parent.Parent:WaitForChild("HatchingMoment")
local HatchedImage = script.Parent.Parent:WaitForChild("HatchedImage")
local HatchedName = script.Parent.Parent:WaitForChild("Name")
local Slot1 = game.Players.LocalPlayer.PlayerGui.MenuGui.InventoryMain.InventoryFrame.InventoryBackground:WaitForChild("ElementSlot1")
local Image = game.Players.LocalPlayer.PlayerGui.MenuGui.InventoryMain.InventoryFrame.InventoryBackground.ElementSlot1:WaitForChild("ElementImage")
local amount = game.Players.LocalPlayer.PlayerGui.MenuGui.InventoryMain.InventoryFrame.InventoryBackground.ElementSlot1.ElementImage:WaitForChild("Amount")
local element = game.Players.LocalPlayer.PlayerGui.EggSellGui.MainFrame.ShopFrame.BuggyEgg:WaitForChild("Element")
local slot1currentimage = game.Players.LocalPlayer.PlayerGui.MenuGui.InventoryMain.InventoryFrame.InventoryBackground.ElementSlot1.ElementImage:WaitForChild("CurrentImage")
local purpleterriaimage = game.ServerStorage.PurpleTerria:WaitForChild("Image")
local purpleterrianame = game.ServerStorage.PurpleTerria:WaitForChild("Name")
button.MouseButton1Down:connect(function()
if HatchingFrame.Visible == true then
HatchingFrame.Visible = false
button.Visible = false
HatchedImage.Image = ""
HatchedName.Text = ""
if element.Value == "Purple Terria" then
Slot1.Visible = true
wait(0.1)
slot1currentimage.Value = purpleterriaimage.Value
wait(0.1)
Image.Image = slot1currentimage.Value
amount:WaitForChild("NumberAmount").Value = amount:WaitForChild("NumberAmount").Value + 1
end
end
end)
Error says; ServerStorage is not a valid member of DataMode
So in the script this line has an error;
local purpleterriaimage = game.ServerStorage.PurpleTerria:WaitForChild("Image")
Any idea how to fix? Error on line 10, please help!

2 comments
I don't know what RemoteFunctions/Events are but I will try ReplicatedStorage
They're super useful for dealing with server/client interactions. I changed it to a link in my post.