Add screen edge reflection.

This commit is contained in:
2018-11-11 15:07:29 +04:00
parent 66bd930e2e
commit 79f4334cd7
3 changed files with 33 additions and 3 deletions

View File

@ -3,6 +3,7 @@ package com.me.brickbuster;
import com.badlogic.gdx.ApplicationAdapter;
import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.graphics.GL20;
import com.badlogic.gdx.math.Vector2;
import com.me.brickbuster.entity.Ball;
import com.me.brickbuster.entity.Block;
import com.me.brickbuster.entity.Paddle;
@ -15,6 +16,11 @@ public class BrickBuster extends ApplicationAdapter {
public static final int HEIGHT = 600;
public static final String TITLE = "Brick Buster";
public static final Vector2 RIGHT_EDGE = new Vector2(0, 1);
public static final Vector2 TOP_EDGE = new Vector2(-1, 0);
public static final Vector2 LEFT_EDGE = new Vector2(0, -1);
public static final Vector2 BOTTOM_EDGE = new Vector2(1, 0);
Ball ball;
Paddle paddle;
ArrayList<Block> blocks;