C# 클래스 UIDraggableCamera, Hero.Coli

상속: MonoBehaviour
파일 보기 프로젝트 열기: CyberCRI/Hero.Coli 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
dragEffect UIDragObject.DragEffect
momentumAmount float
rootForBounds Transform
scale Vector2
scrollWheelFactor float
smoothDragStart bool

공개 메소드들

메소드 설명
Awake ( ) : void

Cache the common components.

ConstrainToBounds ( bool immediate ) : bool

Constrain the current camera's position to be within the viewable area's bounds.

Drag ( Vector2 delta ) : void

Drag event receiver.

Press ( bool isPressed ) : void

Calculate the bounds of all widgets under this game object.

Scroll ( float delta ) : void

If the object should support the scroll wheel, do it.

Start ( ) : void

Cache the root.

Update ( ) : void

Apply the dragging momentum.

비공개 메소드들

메소드 설명
CalculateConstrainOffset ( ) : Vector3

Calculate the offset needed to be constrained within the panel's bounds.

메소드 상세

Awake() 공개 메소드

Cache the common components.
public Awake ( ) : void
리턴 void

ConstrainToBounds() 공개 메소드

Constrain the current camera's position to be within the viewable area's bounds.
public ConstrainToBounds ( bool immediate ) : bool
immediate bool
리턴 bool

Drag() 공개 메소드

Drag event receiver.
public Drag ( Vector2 delta ) : void
delta Vector2
리턴 void

Press() 공개 메소드

Calculate the bounds of all widgets under this game object.
public Press ( bool isPressed ) : void
isPressed bool
리턴 void

Scroll() 공개 메소드

If the object should support the scroll wheel, do it.
public Scroll ( float delta ) : void
delta float
리턴 void

Start() 공개 메소드

Cache the root.
public Start ( ) : void
리턴 void

Update() 공개 메소드

Apply the dragging momentum.
public Update ( ) : void
리턴 void

프로퍼티 상세

dragEffect 공개적으로 프로퍼티

Effect to apply when dragging.
public UIDragObject.DragEffect dragEffect
리턴 UIDragObject.DragEffect

momentumAmount 공개적으로 프로퍼티

How much momentum gets applied when the press is released after dragging.
public float momentumAmount
리턴 float

rootForBounds 공개적으로 프로퍼티

Root object that will be used for drag-limiting bounds.
public Transform rootForBounds
리턴 Transform

scale 공개적으로 프로퍼티

Scale value applied to the drag delta. Set X or Y to 0 to disallow dragging in that direction.
public Vector2 scale
리턴 Vector2

scrollWheelFactor 공개적으로 프로퍼티

Effect the scroll wheel will have on the momentum.
public float scrollWheelFactor
리턴 float

smoothDragStart 공개적으로 프로퍼티

Whether the drag operation will be started smoothly, or if if it will be precise (but will have a noticeable "jump").
public bool smoothDragStart
리턴 bool