tech/game

21/07/31 Roblox Studio Tutorial: Starting Menu

tech-lover 2021. 7. 31. 22:37

https://youtu.be/uO2_e1YSdFM

 

```

local frame = script.Parent

local purple = script.Parent.PurpleZone

local green = script.Parent.GreenZone

 

local function greenZone()

    local player = game.Players.LocalPlayer

    player.Character.HumanoidRootPart.CFrame = CFrame.new(1820.580)

    frame.Visible = false

end

 

local function purpleZone()

    local player = game.Players.LocalPlayer

    player.Character.HumanoidRootPart.CFrame = CFrame.new(-1930.580)

    frame.Visible = false

end

 

green.MouseButton1Click:Connect(greenZone)

purple.MouseButton1Click:Connect(purpleZone)

```