C# 클래스 UHSampleGame.SpriteBatchExtensions

파일 보기 프로젝트 열기: holtkampw/UH-Sample-XNA-Project

공개 메소드들

메소드 설명
DrawInt32 ( this spriteBatch, SpriteFont spriteFont, int value, Vector2 position, Color color ) : Vector2

Extension method for SpriteBatch that draws an integer without allocating any memory. This function avoids garbage collections that are normally caused by calling Int32.ToString or String.Format.

메소드 상세

DrawInt32() 공개 정적인 메소드

Extension method for SpriteBatch that draws an integer without allocating any memory. This function avoids garbage collections that are normally caused by calling Int32.ToString or String.Format.
public static DrawInt32 ( this spriteBatch, SpriteFont spriteFont, int value, Vector2 position, Color color ) : Vector2
spriteBatch this The SpriteBatch instance whose DrawString method will be invoked.
spriteFont Microsoft.Xna.Framework.Graphics.SpriteFont The SpriteFont to draw the integer value with.
value int The integer value to draw.
position Vector2 The screen position specifying where to draw the value.
color Color The color of the text drawn.
리턴 Vector2