RobloxScripterAI
Discord ↗
Link Copied to Clipboard
×
"make rock paper siccsors"
-- Here's a basic script for a rock paper scissors game local player = game.Players.LocalPlayer local mouse = player:GetMouse() local rock = script.Parent.Rock local paper = script.Parent.Paper local scissors = script.Parent.Scissors local choices = {"Rock", "Paper", "Scissors"} local function play(choice) local computerChoice = choices[math.random(1,3)] if choice == computerChoice then print("It's a tie!") elseif choice == "Rock" and computerChoice == "Scissors" or choice == "Paper" and computerChoice == "Rock" or choice == "Scissors" and computerChoice == "Paper" then print("You win!") else print("You lose!") end end rock.MouseButton1Click:Connect(function() play("Rock") end) paper.MouseButton1Click:Connect(function() play("Paper") end) scissors.MouseButton1Click:Connect(function() play("Scissors") end)