C# 클래스 Protogame.HasTransformExtensions

Extension methods which assist developers in writing classes that implement IHasTransform.
파일 보기 프로젝트 열기: RedpointGames/Protogame

공개 메소드들

메소드 설명
GetAttachedFinalTransformImplementation ( this hasTransform, INode node ) : IFinalTransform

Returns a final transform by combining the final transform of the parent in the hierarchy (if the parent node has a transform), and the local transform of this object. You should use this method to implement IHasTransform.FinalTransform if your object resides in the hierarchy.

GetDetachedFinalTransformImplementation ( this hasTransform ) : IFinalTransform

Gets a final transform which is just representative of the local transform. This method should be used sparingly, but is intended when either you know the parent of this object will have no transform (i.e. you are implementing an entity which resides directly in the world), or when there's no way for the caller to know it's position in the hierarchy.

메소드 상세

GetAttachedFinalTransformImplementation() 공개 정적인 메소드

Returns a final transform by combining the final transform of the parent in the hierarchy (if the parent node has a transform), and the local transform of this object. You should use this method to implement IHasTransform.FinalTransform if your object resides in the hierarchy.
public static GetAttachedFinalTransformImplementation ( this hasTransform, INode node ) : IFinalTransform
hasTransform this The current object.
node INode /// The node in the dependency injection hierarchy that points to this object. This value /// can be obtained by injecting into the constructor of your object. ///
리턴 IFinalTransform

GetDetachedFinalTransformImplementation() 공개 정적인 메소드

Gets a final transform which is just representative of the local transform. This method should be used sparingly, but is intended when either you know the parent of this object will have no transform (i.e. you are implementing an entity which resides directly in the world), or when there's no way for the caller to know it's position in the hierarchy.
public static GetDetachedFinalTransformImplementation ( this hasTransform ) : IFinalTransform
hasTransform this The current object.
리턴 IFinalTransform