Class Rect
영역 정보를 저장하는 클래스
상속
object
Rect
네임스페이스: Game.Scripts.Graphics
어셈블리: Assembly-CSharp.dll
Syntax
[MoonSharpUserData]
public class Rect
생성자
Rect(Point, Point)
Rect 생성하기
선언
public Rect(Point position, Point size)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
Point | position | 위치 |
Point | size | 크기 |
Rect(float, float, float, float)
Rect 생성하기
선언
public Rect(float x, float y, float width, float height)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
float | x | X 좌표 |
float | y | Y 좌표 |
float | width | 가로 길이 |
float | height | 세로 길이 |
프로퍼티
center
영역의 중앙 위치를 얻습니다.
선언
public Point center { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
Point |
height
세로 크기
선언
public float height { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
float |
position
Rect 영역의 x, y 정보를 얻습니다.
선언
public Point position { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
Point |
size
영역의 가로 세로 길이를 얻습니다.
선언
public Point size { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
Point |
width
가로 크기
선언
public float width { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
float |
x
위치 X
선언
public float x { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
float |
y
위치 Y
선언
public float y { get; set; }
프로퍼티 값
타입 | 설명 |
---|---|
float |
zero
Rect(0,0,0,0)의 숏컷입니다.
선언
public static Rect zero { get; }
프로퍼티 값
타입 | 설명 |
---|---|
Rect |
함수
__call(object, Point, Point)
영역 정보를 저장하는 클래스
선언
[MoonSharpUserDataMetamethod("__call")]
public static Rect __call(object self, Point position, Point size)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
object | self | |
Point | position | |
Point | size |
반환
타입 | 설명 |
---|---|
Rect |
__call(object, float, float, float, float)
영역 정보를 저장하는 클래스
선언
[MoonSharpUserDataMetamethod("__call")]
public static Rect __call(object self, float x, float y, float width, float height)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
object | self | |
float | x | |
float | y | |
float | width | |
float | height |
반환
타입 | 설명 |
---|---|
Rect |
__pairs(Rect)
영역 정보를 저장하는 클래스
선언
[MoonSharpUserDataMetamethod("__pairs")]
public static DynValue __pairs(Rect self)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
Rect | self |
반환
타입 | 설명 |
---|---|
MoonSharp.Interpreter.DynValue |
연산자
implicit operator Rect(Rect)
영역 정보를 저장하는 클래스
선언
public static implicit operator Rect(Rect rect)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
Rect | rect |
반환
타입 | 설명 |
---|---|
UnityEngine.Rect |
implicit operator Rect(RectTransform)
영역 정보를 저장하는 클래스
선언
public static implicit operator Rect(RectTransform rt)
매개 변수(인자)
타입 | 이름 | 설명 |
---|---|---|
UnityEngine.RectTransform | rt |
반환
타입 | 설명 |
---|---|
Rect |