GuiBase2d

GuiBase2d : Instance

Overview

2D GuiObject๋“ค์˜ ๊ธฐ๋ฐ˜์ด ๋˜๋Š” ์ถ”์ƒ ํด๋ž˜์Šค์ž…๋‹ˆ๋‹ค.

Properties

AbsolutePosition

Vector2

UI ์š”์†Œ๊ฐ€ ์‹ค์ œ ํ™”๋ฉด์ƒ์— ๋ Œ๋”๋ง๋˜๋Š” ์œ„์น˜๋ฅผ ํ”ฝ์…€ ๋‹จ์œ„๋กœ ๋‚˜ํƒ€๋‚ด๋Š” ์†์„ฑ์ž…๋‹ˆ๋‹ค.

์ด ๊ฐ’์€ ๋ถ€๋ชจ UI ์š”์†Œ๋“ค์˜ ์œ„์น˜์™€ ํฌ๊ธฐ๋ฅผ ๋ชจ๋‘ ๋ฐ˜์˜ํ•œ ์ตœ์ข… ๊ณ„์‚ฐ ๊ฒฐ๊ณผ์ด๋ฉฐ, ํ•ญ์ƒ ์š”์†Œ์˜ ์ขŒ์ธก ์ƒ๋‹จ์„ ๊ธฐ์ค€์œผ๋กœ ํ•ฉ๋‹ˆ๋‹ค.

Code Samples

local ScreenGui = script.Parent
local TextLabel = ScreenGui.TextLabel

print("AbsolutePosition : ", TextLabel.AbsolutePosition)

AbsoluteSize

Vector2

UI ์š”์†Œ๊ฐ€ ํ™”๋ฉด์— ๋ Œ๋”๋ง๋  ๋•Œ ์ ์šฉ๋˜๋Š” ์‹ค์ œ ํฌ๊ธฐ๋ฅผ ํ”ฝ์…€ ๋‹จ์œ„๋กœ ๋‚˜ํƒ€๋‚ด๋Š” ์†์„ฑ์ž…๋‹ˆ๋‹ค.

์ด ๊ฐ’์€ ๋ถ€๋ชจ์˜ ํฌ๊ธฐ, AnchorPoint, Scale ๋“ฑ์˜ ์„ค์ •์ด ๋ชจ๋‘ ๋ฐ˜์˜๋œ ๊ฒฐ๊ณผ๊ฐ’์œผ๋กœ, ํ™”๋ฉด์—์„œ ํ•ด๋‹น ์š”์†Œ๊ฐ€ ์ฐจ์ง€ํ•˜๋Š” ์ตœ์ข… ํฌ๊ธฐ๋ฅผ ์ •ํ™•ํ•˜๊ฒŒ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

Code Samples

local ScreenGui = script.Parent
local TextLabel = ScreenGui.TextLabel

print("AbsoluteSize : ", TextLabel.AbsoluteSize)

Methods

Events

Last updated