This is the script I developed myself:
local dice = script.Parent --localizes "dice" which is the gui button
function diceroll()
local i = math.random(2,12) -- randomizes the diceroll
wait(0.1)
print(i) --prints the result
end
dice.TouchTap:Connect(diceroll())
I'm trying to sort of make a roll dice button that will print the result, this is for a future project of mine. The script is located in starter gui linked to the "dice" maybe that's the problem, idk! Anything helps! answer asap :)
** You are now Level 1! **