Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package com.sirtrashyton;
- import box2dLight.RayHandler;
- import com.badlogic.gdx.ApplicationAdapter;
- import com.badlogic.gdx.Gdx;
- import com.badlogic.gdx.graphics.GL20;
- import com.badlogic.gdx.graphics.Texture;
- import com.badlogic.gdx.graphics.g2d.SpriteBatch;
- import com.badlogic.gdx.math.Vector2;
- import com.badlogic.gdx.physics.box2d.Box2DDebugRenderer;
- import com.badlogic.gdx.physics.box2d.World;
- public class Game extends ApplicationAdapter {
- SpriteBatch batch;
- Texture img;
- public World w;
- @Override
- public void create () {
- batch = new SpriteBatch();
- img = new Texture("badlogic.jpg");
- Box2DDebugRenderer debug = new Box2DDebugRenderer();
- w = new World(new Vector2(0f, 0f), false);
- }
- @Override
- public void render () {
- Gdx.gl.glClearColor(1, 0, 0, 1);
- Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT);
- batch.begin();
- batch.draw(img, 0, 0);
- batch.end();
- }
- @Override
- public void dispose () {
- batch.dispose();
- img.dispose();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement