Advertisement
Anukun_Lucifer

Script Prompt (Triggered)

Oct 5th, 2022
920
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.92 KB | Gaming | 0 0
  1. local button = script.Parent
  2. local seeds = script.Parent.Parent.RiceSeedS
  3. local seedm = script.Parent.Parent.RiceSeedM
  4. local seedl = script.Parent.Parent.RiceSeedL
  5. local ricevalue = script.Parent.Parent.RiceValue
  6.  
  7. button.Triggered:Connect(function()
  8.     if ricevalue.Value == 0 then
  9.         button.Enabled = false
  10.         seeds.Transparency = 0
  11.         wait(3)
  12.         seeds.Transparency = 1
  13.         seedm.Transparency = 0
  14.         wait(3)
  15.         seedm.Transparency = 1
  16.         seedl.Transparency = 0
  17.         button.ObjectText = "ได้รับข้าว 2 กำ/เมล็ดข้าว 2 ถุง"
  18.         button.ActionText = "เก็บเกี่ยวผลผลิต"
  19.         wait(1)
  20.         button.Enabled = true
  21.         ricevalue.Value = 1
  22.     elseif ricevalue.Value == 1 then
  23.         seedl.Transparency = 1
  24.         button.ObjectText = "ใช้เมล็ดข้าว 1 ถุง"
  25.         button.ActionText = "หว่านเมล็ด"
  26.         wait(1)
  27.         ricevalue.Value = 0
  28.     end
  29. end)
Tags: Roblox
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement