Back to project page FlappyCow.
The source code is released under:
MIT License
If you think the Android project FlappyCow listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
/** * Manages the bitmap at the front// w w w .j a v a 2s.com * * @author Lars Harmsen * Copyright (c) <2014> <Lars Harmsen - Quchen> */ package com.quchen.flappycow.sprites; import com.quchen.flappycow.Game; import com.quchen.flappycow.GameView; import com.quchen.flappycow.R; import com.quchen.flappycow.Util; import android.graphics.Bitmap; public class Frontground extends Background { /** * Height of the ground relative to the height of the bitmap */ public static final float GROUND_HEIGHT = (1f * /*45*/ 35) / 720; /** * Static bitmap to reduce memory usage. */ public static Bitmap globalBitmap; public Frontground(GameView view, Game game) { super(view, game); if(globalBitmap == null){ globalBitmap = Util.getDownScaledBitmapAlpha8(game, R.drawable.fg); } this.bitmap = globalBitmap; } }