FANDOM


(Gallery)
m (Added external links)
 
(46 intermediate revisions by 23 users not shown)
Line 1: Line 1:
[[File:Terrain.jpg|400px|thumb|The '''Terrain''' object.]]
+
{{Infobox class
The '''Terrain''' object is an object that is customizable using functions and the [[Terrain plugin]].
+
| explorer order = 0
  +
| tags = notCreatable}}
   
==Terrain==
+
Object representing a high performance bounded grid of static 4x4 parts. This class cannot be [[instantiated]].
The Terrain object allows for a player to use more blocks per game. The Terrain is made up of many individual BaseParts acting as a single BasePart, unlike most complex shapes which are usually made of [[Mesh]]es. The blocks are anchored when you step on them, but an explosion dettaches the bricks and renders them unanchored. This provides a simple way to create craters ingame. In ROBLOX Studio the [[Terrain plugin|Terrain]] [[Plugins|plugin]] allows you to create craters or mountains etc, or you could just randomize it using the [[Terrain Generator]] script in the plugin. Read more about the terrain generator [http://blog.roblox.com/?s=terrain+generator here.]
 
   
==Features==
+
== Properties ==
*Vast voxel-based grid of boxes and wedges.
 
*Integrated with the ROBLOX physics engine.
 
*Sand & Grass environments currently available.
 
*Destructible terrain
 
*It is fully scriptable in Lua (but API will change before release).
 
*Editable with ROBLOX and user-made Studio plugins.
 
*First version out in September.
 
   
===Terrain Types===
 
#Grass
 
#Sand
 
#Brick
 
#Granite
 
#Asphalt
 
#Iron Plate
 
#Aluminum Plate
 
#Gold
 
#Wood Planks
 
#Logs
 
#Gravel
 
#Cinderblock
 
#Mossy Rock
 
#Concrete
 
#Red Plastic
 
#Blue Plastic
 
#Water
 
   
==Hacks==
 
When the Terrain object was released, people had the ability to hack [[ROBLOX]] [[games]], by [[Terrain Generator|generating Terrain]] over the existing [[place]]. This makes the place hard to play or ruined because of the terrain that was not supposed to be in the level. The place could even be [[Water|flooded]]. However, now there are some scripts that prevent terrain hacks from occuring. However, not all hacks are yet resolved.
 
   
==Criticism==
+
=== {{property|readonly|name=IsSmooth|type=bool|deprecated}} ===
Many people thought that the terrain were resembling Minecraft's terrain, however they are not similar in any way. It was also criticized for the amount of lag in places and lack of effort in building bases in places.
 
   
==History==
+
Returns whether or not this game has smooth terrain. Flat terrain was removed in January 2017, so this is always true.
In an update, more Terrain Voxel textures were introduced, bringing the number up to sixteen.
 
   
[[File:Imagewater.jpg|thumb|[[Water]] was added to Terrain.]]
+
=== {{property|readonly|name=MaxExtents|type=Region3int16}} ===
   
On December 7, 2013, an update was added that increased the size of the Terrain from 512x64x512 to 64000x64000x64000. This allowed players to add Terrain Water to existing places that are very large.
+
=== {{property|name=WaterColor|type=Color3}} ===
   
==Gallery==
+
The color of the [[Water]] material.
<gallery>
 
File:Terrain 1.jpg
 
File:Terrain 2.jpg
 
File:Terrain 3.jpg
 
File:Terrain 4.jpg
 
File:Terrain Materials.jpg
 
File:Water.jpg
 
File:Water 2.jpg
 
File:Water 3.jpg
 
</gallery>
 
   
[[Category:Terrain]]
+
=== {{property|name=WaterReflectance|type=float}} ===
  +
  +
The reflectance of the [[Water]] material.
  +
  +
=== {{property|name=WaterTransparency|type=float}} ===
  +
  +
The transparency of the [[Water]] material.
  +
  +
=== {{property|name=WaterWaveSize|type=float}} ===
  +
  +
The maximum size [[Water]] waves can be.
  +
  +
=== {{property|name=WaterWaveSpeed|type=float}} ===
  +
  +
The speed of the [[Water]] material.
  +
  +
== Methods ==
  +
  +
  +
  +
=== {{method|deprecated|bool|name=AutowedgeCell|int x|int y|int z}} ===
  +
  +
=== {{method|deprecated|void|name=AutowedgeCells|Region3int16 region}} ===
  +
  +
=== {{method|Vector3|name=CellCenterToWorld|int x|int y|int z}} ===
  +
  +
=== {{method|Vector3|name=CellCornerToWorld|int x|int y|int z}} ===
  +
  +
=== {{method|void|name=Clear}} ===
  +
  +
Removes all smooth terrain from the game.
  +
  +
=== {{method|PluginSecurity|void|name=ConvertToSmooth|deprecated}} ===
  +
  +
Converts the game from flat to smooth terrain.
  +
  +
=== {{method|Instance|name=CopyRegion|Region3int16 region}} ===
  +
  +
Copies the given region and returns a {{Class link|TerrainRegion}}.
  +
  +
=== {{method|int|name=CountCells}} ===
  +
  +
Counts the amount of terrain cells.
  +
  +
=== {{method|void|name=FillBall|Vector3 center|float radius|Material material}} ===
  +
  +
Creates a ball of terrain that reaches out from the given center point.
  +
  +
=== {{method|void|name=FillBlock|CoordinateFrame cframe|Vector3 size|Material material}} ===
  +
  +
Creates a block of terrain from the given CoordinateFrame and goes out by size.
  +
  +
=== {{method|void|name=FillRegion|Region3 region|float resolution|Material material}} ===
  +
  +
Fills a region with the given material.
  +
  +
=== {{method|deprecated|Tuple|name=GetCell|int x|int y|int z}} ===
  +
  +
Returns CellMaterial, CellBlock, CellOrientation
  +
  +
=== {{method|deprecated|Tuple|name=GetWaterCell|int x|int y|int z}} ===
  +
  +
Returns hasAnyWater, WaterForce, WaterDirection
  +
  +
=== {{method|Color3|name=GetMaterialColor|Material material}} ===
  +
Retrives the color of a material previously set with [[#SetMaterialColor|SetMaterialColor]]
  +
  +
=== {{method|void|name=PasteRegion|Instance region|Vector3int16 corner|bool pasteEmptyCells}} ===
  +
  +
Pastes the given {{Class link|TerrainRegion}}, with the corner being a corner.
  +
  +
=== {{method|Tuple|name=ReadVoxels|Region3 region|float resolution}} ===
  +
  +
=== {{method|void|name=SetMaterialColor|Material material|Color3 value}} ===
  +
  +
=== {{method|deprecated|void|name=SetCell|int x|int y|int z|CellMaterial material|CellBlock block|CellOrientation orientation}} ===
  +
  +
=== {{method|deprecated|void|name=SetCells|Region3int16 region|CellMaterial material|CellBlock block|CellOrientation orientation}} ===
  +
  +
=== {{method|deprecated|void|name=SetWaterCell|int x|int y|int z|WaterForce force|WaterDirection direction}} ===
  +
  +
  +
  +
=== {{method|Vector3|name=WorldToCell|Vector3 position}} ===
  +
  +
=== {{method|Vector3|name=WorldToCellPreferEmpty|Vector3 position}} ===
  +
  +
=== {{method|Vector3|name=WorldToCellPreferSolid|Vector3 position}} ===
  +
  +
=== {{method|void|name=WriteVoxels|Region3 region|float resolution|Array materials|Array occupancy}} ===
  +
  +
== External links ==
  +
  +
* {{DevHub class link}}
  +
* {{Roblox API Reference class link}}

Latest revision as of 03:09, March 3, 2019

Object representing a high performance bounded grid of static 4x4 parts. This class cannot be instantiated.

Properties Edit

Pubfield bool IsSmooth [readonly] [deprecated] Edit

Returns whether or not this game has smooth terrain. Flat terrain was removed in January 2017, so this is always true.

Pubfield Region3int16 MaxExtents [readonly] Edit

Pubfield Color3 WaterColor Edit

The color of the Water material.

Pubfield float WaterReflectance Edit

The reflectance of the Water material.

Pubfield float WaterTransparency Edit

The transparency of the Water material.

Pubfield float WaterWaveSize Edit

The maximum size Water waves can be.

Pubfield float WaterWaveSpeed Edit

The speed of the Water material.

Methods Edit

Pubmethod bool AutowedgeCell(int x, int y, int z) [deprecated] Edit

Pubmethod void AutowedgeCells(Region3int16 region) [deprecated] Edit

Pubmethod Vector3 CellCenterToWorld(int x, int y, int z) Edit

Pubmethod Vector3 CellCornerToWorld(int x, int y, int z) Edit

Pubmethod void Clear() Edit

Removes all smooth terrain from the game.

Protmethod void ConvertToSmooth() [deprecated] [PluginSecurity] Edit

Converts the game from flat to smooth terrain.

Pubmethod Instance CopyRegion(Region3int16 region) Edit

Copies the given region and returns a ExplorerImageIndex 65TerrainRegion.

Pubmethod int CountCells() Edit

Counts the amount of terrain cells.

Pubmethod void FillBall(Vector3 center, float radius, Material material) Edit

Creates a ball of terrain that reaches out from the given center point.

Pubmethod void FillBlock(CoordinateFrame cframe, Vector3 size, Material material) Edit

Creates a block of terrain from the given CoordinateFrame and goes out by size.

Pubmethod void FillRegion(Region3 region, float resolution, Material material) Edit

Fills a region with the given material.

Pubmethod Tuple GetCell(int x, int y, int z) [deprecated] Edit

Returns CellMaterial, CellBlock, CellOrientation

Pubmethod Tuple GetWaterCell(int x, int y, int z) [deprecated] Edit

Returns hasAnyWater, WaterForce, WaterDirection

Pubmethod Color3 GetMaterialColor(Material material) Edit

Retrives the color of a material previously set with SetMaterialColor

Pubmethod void PasteRegion(Instance region, Vector3int16 corner, bool pasteEmptyCells) Edit

Pastes the given ExplorerImageIndex 65TerrainRegion, with the corner being a corner.

Pubmethod Tuple ReadVoxels(Region3 region, float resolution) Edit

Pubmethod void SetMaterialColor(Material material, Color3 value) Edit

Pubmethod void SetCell(int x, int y, int z, CellMaterial material, CellBlock block, CellOrientation orientation) [deprecated] Edit

Pubmethod void SetCells(Region3int16 region, CellMaterial material, CellBlock block, CellOrientation orientation) [deprecated] Edit

Pubmethod void SetWaterCell(int x, int y, int z, WaterForce force, WaterDirection direction) [deprecated] Edit

Pubmethod Vector3 WorldToCell(Vector3 position) Edit

Pubmethod Vector3 WorldToCellPreferEmpty(Vector3 position) Edit

Pubmethod Vector3 WorldToCellPreferSolid(Vector3 position) Edit

Pubmethod void WriteVoxels(Region3 region, float resolution, Array materials, Array occupancy) Edit

External links Edit

Community content is available under CC-BY-SA unless otherwise noted.