本文整理汇总了Java中org.andengine.util.color.Color.BLACK属性的典型用法代码示例。如果您正苦于以下问题:Java Color.BLACK属性的具体用法?Java Color.BLACK怎么用?Java Color.BLACK使用的例子?那么恭喜您, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在类org.andengine.util.color.Color
的用法示例。
在下文中一共展示了Color.BLACK属性的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: loadGameFonts
public void loadGameFonts() {
mTypeface = Typeface.createFromAsset(mContext.getAssets(), "LCD.ttf");
final ITexture scoreTexture = new BitmapTextureAtlas(mContext.getTextureManager(), 256, 512, TextureOptions.BILINEAR);
mGameFont = new Font(mContext.getFontManager(), scoreTexture, mTypeface, 18, true, new Color(Color.BLACK));
scoreTexture.load();
mGameFont.load();
final BitmapTextureAtlas gamePlayTexture = new BitmapTextureAtlas(mContext.getTextureManager(), 512, 512, TextureOptions.BILINEAR);
mGamePlayFont = new StrokeFont(mContext.getFontManager(), gamePlayTexture, mTypeface, 96, true, new Color(Color.WHITE), 0, new Color(Color.WHITE));
gamePlayTexture.load();
mGamePlayFont.load();
}
示例2: loadGameFonts
private void loadGameFonts() {
this.mFontTexture_score = new BitmapTextureAtlas(activity.getTextureManager(), score_width, score_height, TextureOptions.BILINEAR_PREMULTIPLYALPHA);
this.mFontTexture_score2 = new BitmapTextureAtlas(activity.getTextureManager(), score2_width, score2_height, TextureOptions.BILINEAR_PREMULTIPLYALPHA);
this.mFontTexture_score_best = new BitmapTextureAtlas(activity.getTextureManager(), score_best_width, score_best_height, TextureOptions.BILINEAR_PREMULTIPLYALPHA);
this.mFont = new Font(activity.getFontManager(), this.mFontTexture_score, Typeface.create(Typeface.DEFAULT, Typeface.BOLD), 24, true, Color.BLACK);
this.mFont = new Font(activity.getFontManager(), this.mFontTexture_score2, Typeface.create(Typeface.DEFAULT, Typeface.BOLD), 24, true, Color.BLACK);
this.mFont = new Font(activity.getFontManager(), this.mFontTexture_score_best, Typeface.create(Typeface.DEFAULT, Typeface.BOLD), 24, true, Color.BLACK);
activity.getTextureManager().loadTexture(this.mFontTexture_score);
activity.getTextureManager().loadTexture(this.mFontTexture_score2);
activity.getTextureManager().loadTexture(this.mFontTexture_score_best);
activity.getFontManager().loadFont(this.mFont);
}
示例3: addBackground
private void addBackground() {
background = new Background(Color.BLACK);
setBackground(background);
}
示例4: init
private void init(KeyListenScene pBaseScene) {
// 共通ウィンドウを作成
CommonWindowRectangle comonWindowRectangle = new CommonWindowRectangle(
0,
0,
pBaseScene.getWindowWidth(),
pBaseScene.getWindowHeight(),
Color.BLACK, 0.8f,
pBaseScene);
attachChild(comonWindowRectangle);
// タイトル
float titleY = 12;
Font titleFont = pBaseScene.createFont(Typeface.DEFAULT_BOLD, 30, Color.WHITE);
Text titleText = new Text(10, 10, titleFont, "〜 経験値振り分け 〜",
pBaseScene.getBaseActivity().getVertexBufferObjectManager());
pBaseScene.placeToCenterX(titleText, titleY);
attachChild(titleText);
float titleLineY = titleText.getY() + titleText.getHeight() + 4;
Line line = new Line(10, titleLineY, pBaseScene.getWindowWidth() - 16, titleLineY,
pBaseScene.getBaseActivity().getVertexBufferObjectManager());
line.setLineWidth(1);
line.setColor(Color.WHITE);
line.setAlpha(1.0f);
attachChild(line);
TextLogic textLogic = new TextLogic();
Font defaultFont = pBaseScene.createFont(Typeface.SANS_SERIF, 16, Color.WHITE);
Font paramFont = pBaseScene.createFont(Typeface.DEFAULT, 16, Color.YELLOW);
//Font upParamFont = pBaseScene.createFont(Typeface.DEFAULT, 16, Color.BLUE);
// Expの表示
float expY = titleLineY + 4;
Rectangle totalExpTextRect = textLogic.createTextRectangle("所持経験値:", defaultFont, "100 Exp", paramFont,
pBaseScene.getBaseActivity().getVertexBufferObjectManager());
attachChild(totalExpTextRect);
Rectangle afterExpTextRect = textLogic.createTextRectangle("振り分け後経験値:", defaultFont, "0 Exp", paramFont,
pBaseScene.getBaseActivity().getVertexBufferObjectManager());
attachChild(afterExpTextRect);
totalExpTextRect.setPosition(pBaseScene.getWindowWidth() / 2 -
(totalExpTextRect.getX() + totalExpTextRect.getWidth() + 50 + afterExpTextRect.getWidth()) / 2, expY);
afterExpTextRect.setPosition(
totalExpTextRect.getX() + totalExpTextRect.getWidth() + 50,
totalExpTextRect.getY());
float expLineY = totalExpTextRect.getY() + totalExpTextRect.getHeight() + 4;
Line expLine = new Line(10, expLineY, pBaseScene.getWindowWidth() - 16, expLineY,
pBaseScene.getBaseActivity().getVertexBufferObjectManager());
expLine.setLineWidth(1);
expLine.setColor(Color.WHITE);
expLine.setAlpha(1.0f);
attachChild(expLine);
// プレイヤー情報
float playerX = 12;
float playerY = expLineY + 12;
ActorPlayerLogic actorPlayerLogic = new ActorPlayerLogic();
ActorPlayerDto actorPlayerDto = actorPlayerLogic.createActorPlayerDto(pBaseScene, 1);
PlayerStatusRectangle playerStatusRectangle = new PlayerStatusRectangle(pBaseScene, defaultFont,
actorPlayerDto, ActorSpriteUtil.getFaceFileName(actorPlayerDto.getImageResId()), playerX, playerY);
playerStatusRectangle.show(PlayerStatusRectangleType.MINI_STATUS);
attachChild(playerStatusRectangle);
}