How to fire an event when I press "run" on Roblox studio

You can write your topic however you want, but you need to answer these questions:

  1. What do you want to achieve? Keep it simple and clear!
    Fire an event when I press “Run” on Roblox studio

  2. What is the issue? Include screenshots / videos if possible!
    I don’t know how to do it

  3. What solutions have you tried so far? Did you look for solutions on the Developer Hub?
    I’ve tried looking on Dev hub, but I haven’t seen any solutions.

Any thing would help, thank you.

if game:GetService("RunService"):IsRunMode() then
-- code here
end
2 Likes