97 lines
3.5 KiB
Lua
97 lines
3.5 KiB
Lua
---@meta
|
|
|
|
---@class Region : ScriptRegion
|
|
Region = {
|
|
--- Returns the region's opacity.
|
|
--- @return number alpha The opacity of the region.
|
|
--- @example
|
|
--- local alpha = myRegion:GetAlpha()
|
|
GetAlpha = function(self) end,
|
|
|
|
--- Returns the layer in which the region is drawn.
|
|
--- @return string layer The layer of the region.
|
|
--- @return number sublayer The sublayer of the region.
|
|
--- @example
|
|
--- local layer, sublayer = myRegion:GetDrawLayer()
|
|
GetDrawLayer = function(self) end,
|
|
|
|
--- Returns the scale of the region after propagating from its parents.
|
|
--- @return number effectiveScale The effective scale of the region.
|
|
--- @example
|
|
--- local effectiveScale = myRegion:GetEffectiveScale()
|
|
GetEffectiveScale = function(self) end,
|
|
|
|
--- Returns the scale of the region.
|
|
--- @return number scale The scale of the region.
|
|
--- @example
|
|
--- local scale = myRegion:GetScale()
|
|
GetScale = function(self) end,
|
|
|
|
--- Returns the vertex color shading of the region.
|
|
--- @return number colorR The red component of the vertex color.
|
|
--- @return number colorG The green component of the vertex color.
|
|
--- @return number colorB The blue component of the vertex color.
|
|
--- @return number colorA The alpha component of the vertex color.
|
|
--- @example
|
|
--- local r, g, b, a = myRegion:GetVertexColor()
|
|
GetVertexColor = function(self) end,
|
|
|
|
--- Returns true if the region is ignoring parent alpha.
|
|
--- @return boolean isIgnoring True if the region is ignoring parent alpha.
|
|
--- @example
|
|
--- local isIgnoring = myRegion:IsIgnoringParentAlpha()
|
|
IsIgnoringParentAlpha = function(self) end,
|
|
|
|
--- Returns true if the region is ignoring parent scale.
|
|
--- @return boolean isIgnoring True if the region is ignoring parent scale.
|
|
--- @example
|
|
--- local isIgnoring = myRegion:IsIgnoringParentScale()
|
|
IsIgnoringParentScale = function(self) end,
|
|
|
|
--- Returns true if the region is fully loaded.
|
|
--- @return boolean isLoaded True if the region is loaded.
|
|
--- @example
|
|
--- local isLoaded = myRegion:IsObjectLoaded()
|
|
IsObjectLoaded = function(self) end,
|
|
|
|
--- Sets the opacity of the region.
|
|
--- @param alpha number The opacity value to set (0 to 1).
|
|
--- @example
|
|
--- myRegion:SetAlpha(0.5) -- Set to 50% opacity
|
|
SetAlpha = function(self, alpha) end,
|
|
|
|
--- Sets the layer in which the region is drawn.
|
|
--- @param layer string The layer to set.
|
|
--- @param sublevel number? Optional. The sublevel to set.
|
|
--- @example
|
|
--- myRegion:SetDrawLayer("ARTWORK", 1)
|
|
SetDrawLayer = function(self, layer, sublevel) end,
|
|
|
|
--- Sets whether the region should ignore its parent's alpha.
|
|
--- @param ignore boolean True to ignore parent alpha.
|
|
--- @example
|
|
--- myRegion:SetIgnoreParentAlpha(true)
|
|
SetIgnoreParentAlpha = function(self, ignore) end,
|
|
|
|
--- Sets whether the region should ignore its parent's scale.
|
|
--- @param ignore boolean True to ignore parent scale.
|
|
--- @example
|
|
--- myRegion:SetIgnoreParentScale(true)
|
|
SetIgnoreParentScale = function(self, ignore) end,
|
|
|
|
--- Sets the size scaling of the region.
|
|
--- @param scale number The scale value to set.
|
|
--- @example
|
|
--- myRegion:SetScale(1.5) -- Scale to 150%
|
|
SetScale = function(self, scale) end,
|
|
|
|
--- Sets the vertex shading color of the region.
|
|
--- @param colorR number The red component of the color.
|
|
--- @param colorG number The green component of the color.
|
|
--- @param colorB number The blue component of the color.
|
|
--- @param a number? Optional. The alpha component of the color.
|
|
--- @example
|
|
--- myRegion:SetVertexColor(1, 0, 0) -- Set to red
|
|
SetVertexColor = function(self, colorR, colorG, colorB, a) end,
|
|
}
|