Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How do I make a script that gives points when you sit on a chair?

I'm currently making a game where you sit on a chair and you gain points. But I'm having some trouble making this script. How would I make a script that gives you one point, every two seconds sitting on a chair but whenever you die or get off, it stops giving you points, until you get back on?

1 answer

I have an Idea:

local hum = game.Players.LocalPlayer.Character:WaitForChild(“Humanoid“)
local points = game.Players.LocalPlayer.Points <— there your point value

while wait() do
      if hum.Sit == true then
             points.Value = points.Value +5 <— there your earnings
             wait(20) <— How long you have to sit for the coins 
      end
end

2 comments

0

Where would I put the script? In the seat? Or in the workspace?

0

do it into StarterGui, then it is just for one Person

This discussion is preserved as it was. New answers, comments, and votes are closed.