Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Save Terrain
- local savedTerrain = workspace.Terrain:CopyRegion(workspace.Terrain.MaxExtents)
- savedTerrain.Name = "SavedTerrain"
- savedTerrain.Parent = workspace
- -- Load terrain
- local savedTerrainData = workspace:findFirstChild("SavedTerrain")
- if savedTerrainData then
- local pasteLocation = workspace.Terrain.MaxExtents.Min
- local pasteEmptyCells = false
- workspace.Terrain:Clear()
- workspace.Terrain:PasteRegion(savedTerrainData,pasteLocation,pasteEmptyCells)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement