Created
October 16, 2021 18:29
-
-
Save modster/dc2cb133e1ba718ee2fde8e68853457a to your computer and use it in GitHub Desktop.
ZonePlus Example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- https://1foreverhd.github.io/ZonePlus/ | |
-- Assuming we place ZonePlus in ReplicatedStorage | |
local Zone = require(game:GetService("ReplicatedStorage").Zone) | |
local container = workspace.SafeZoneContainer | |
local zone = Zone.new(container) | |
zone.playerEntered:Connect(function(player) | |
print(("%s entered the zone!"):format(player.Name)) | |
end) | |
zone.playerExited:Connect(function(player) | |
print(("%s exited the zone!"):format(player.Name)) | |
end) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment