Home / Region

region:fill()

region:fill(blockId [, metadata])

Fills the entire region with a specified block using the extended world fill helper.

Parameters

NameTypeDescription
blockIdnumberThe block ID to place. Use 0 for air.
metadatanumber, optionalOptional block data value.

Returns

Returns the value from the extended world.fill() helper.

Example

command('cleararena', { op = true }, function(sender)
  arenaRegion:fill(0) -- clear with air
  sender:send("Arena cleared.")
  return true
end)