Shop Gui Not Working? Working in Studio Test mode but not in Player!
Shop Gui Not Working? Working in Studio Test mode but not in Player! My Shop Gui ONLY works in studio, it displays properly in Player, but the script does not work, here is the main script on the button that alows it to work in studio, this script allows people to buy the weapon Freely,
BTW THIS IS A REGUALR SCRIPT LOCATED INSIDE OF THE BUTTON
01 | script.Parent.Text = tostring (script.Parent.ItemName.Value).. ": " .. tonumber (script.Parent.Cost.Value).. " " .. tostring (script.Parent.Currency.Value) |
02 | script.Parent.MouseButton 1 Click:connect( function () |
03 | if script.Parent.Parent.Parent.Parent.Parent.Parent:findFirstChild( "leaderstats" ) then |
04 | if script.Parent.Parent.Parent.Parent.Parent.Parent.leaderstats [ script.Parent.Currency.Value ] .Value> = tonumber (script.Parent.Cost.Value) then |
05 | script.Parent.Parent.Parent.Parent.Parent.Parent.leaderstats [ script.Parent.Currency.Value ] .Value = script.Parent.Parent.Parent.Parent.Parent.Parent.leaderstats [ script.Parent.Currency.Value ] .Value- tonumber (script.Parent.Cost.Value) |
06 | game.Lighting [ script.Parent.ItemName.Value ] :Clone().Parent = script.Parent.Parent.Parent.Parent.Parent.Parent.Backpack |
07 | game.Lighting [ script.Parent.ItemName.Value ] :Clone().Parent = script.Parent.Parent.Parent.Parent.Parent.Parent.StarterGear |
Is this the problem? Should it be a local script?
This script also has other string values like Currency,Cost, and Item Name! The weapons that this script gives to you is in Lighting! Help????