The PriceInRobux is working but not PriceInTickets(Line 40),why? If you need the model its here http://www.roblox.com/Help-item?id=159979067
NameOfProduct = 159913543
Item = game:GetService("MarketplaceService"):GetProductInfo(NameOfProduct)-- Gets the service Markplace
part = script.Parent
Product = script.Parent.Parent.product
clicked = false
part.MouseButton1Click:connect(function()
---------------Debounce------------------
if clicked == false--Checks if clicked is false(Which it should be,because it already been set false)
then
clicked = true-- Since it false it will turn it true(so we know it's already been clicked)
----------------Fade Out------------------
for fo = 0,10 do
wait(0.1)
part.BackgroundTransparency = fo/10--You need to divide to get the precise number(Other way won't work)
part.TextTransparency = fo/10
if fo/10 ==1
then
part.Visible = false
clicked = false --Turns it false,so it you won't able to click it.
Product.Visible = true
--------------The frame--------------------
Product:TweenSize(UDim2.new(0, 700,0, 500),"Out","Sine",1,true)--The animation
-------------MarketPlace Service-----------
Product.ProductImage.Thumbnail.Image = "http://www.roblox.com/Game/Tools/ThumbnailAsset.ashx?aid="..NameOfProduct.."&fmt=png&wd=420&ht=420"--Gets the thumbnail of the product
Product.ProductName.Text = Item.Name--Gets name of item
Product.ProductDescription.Text = "Description"..": "..Item.Description--Gets Description of item
Product.ProductRobux.Text = Item.PriceInRobux--Gets the price of Robux
------------Removes Nulls-----------------
if Product.ProductRobux.Text == "null" -- No one likes them
then
Product.RLabel.Visible = false
Product.ProductRobux.Visible = false
elseif Product.ProductRobux.Text == "null"
then
Product.RLabel.Visible = true
Product.ProductRobux.Visible = true
-------------------------------------------
print(Item.PriceInTickets)
Product.ProductTix.Text = Item.PriceInTickets--Gets the price of tix
------------Removes Nulls-----------------
if Product.ProductTix.Text == "null"
then
Product.ProductTix.Visible = false
Product.Tixlabel.Visible = false
elseif Product.ProductTix.Text == "null"
then
Product.Tixlabel.Visible = true
Product.ProductTix.Visible = true
--
-----------------------------------------
end
end
end
end
end
end)
