<commit_before>package com.jos.shooot;

import com.badlogic.gdx.ApplicationAdapter;
import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.Input;
import com.badlogic.gdx.graphics.GL20;
import com.badlogic.gdx.graphics.OrthographicCamera;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.Sprite;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;

public class ShootGame extends ApplicationAdapter {
	private Texture dude;
	private OrthographicCamera camera;
	private SpriteBatch batch;
	private Sprite dudeSprite;

	@Override
	public void create () {

		camera = new OrthographicCamera();
		camera.setToOrtho(false, 600, 480);

		dude = new Texture("dude_gun_sprite.png");
		dudeSprite = new Sprite(dude, 0, 0, 40, 48);
		batch = new SpriteBatch();

	}

	float dudeSpeed = 10.0f;
	float dudeX;
	float dudeY;
	boolean flip = false;

	@Override
	public void render () {
		Gdx.gl.glClearColor(1, 1, 0, 1);
		Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT);

		if(Gdx.input.isKeyPressed(Input.Keys.DPAD_LEFT)){
			dudeX -= Gdx.graphics.getDeltaTime() * dudeSpeed * 10;
			if (flip) {
				dudeSprite.flip(flip, false);
				flip = false;
			}
		}
		if(Gdx.input.isKeyPressed(Input.Keys.DPAD_RIGHT)){
			dudeX += Gdx.graphics.getDeltaTime() * dudeSpeed * 10;
			if (!flip){
				dudeSprite.flip(true, false);
				flip = true;
			}
		}

		batch.begin();
		batch.draw(dudeSprite, dudeX, dudeY);
		batch.end();

	}

	@Override
	public void dispose() {
		//TODO (jos) What else do we need to dispose of?
		batch.dispose();
		dude.dispose();
	}
}<commit_msg>reformat and add space bar handler<commit_after>package com.jos.shooot;

import com.badlogic.gdx.ApplicationAdapter;
import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.Input;
import com.badlogic.gdx.graphics.GL20;
import com.badlogic.gdx.graphics.OrthographicCamera;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.Sprite;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;

public class ShootGame extends ApplicationAdapter {
  private Texture dude;
  private OrthographicCamera camera;
  private SpriteBatch batch;
  private Sprite dudeSprite;

  @Override
  public void create() {

    camera = new OrthographicCamera();
    camera.setToOrtho(false, 600, 480);

    dude = new Texture("dude_gun_sprite.png");
    dudeSprite = new Sprite(dude, 0, 0, 40, 48);
    batch = new SpriteBatch();

  }

  float dudeSpeed = 10.0f;
  float dudeX;
  float dudeY;
  boolean flip = false;

  @Override
  public void render() {
    Gdx.gl.glClearColor(1, 1, 0, 1);
    Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT);

    if (Gdx.input.isKeyPressed(Input.Keys.DPAD_LEFT)) {
      dudeX -= Gdx.graphics.getDeltaTime() * dudeSpeed * 10;
      if (flip) {
        dudeSprite.flip(flip, false);
        flip = false;
      }
    }
    if (Gdx.input.isKeyPressed(Input.Keys.DPAD_RIGHT)) {
      dudeX += Gdx.graphics.getDeltaTime() * dudeSpeed * 10;
      if (!flip) {
        dudeSprite.flip(true, false);
        flip = true;
      }
    }

    if (Gdx.input.isKeyPressed(Input.Keys.SPACE)) {
      dudeY += Gdx.graphics.getDeltaTime() * dudeSpeed * 10;
    }

    batch.begin();
    batch.draw(dudeSprite, dudeX, dudeY);
    batch.end();

  }

  @Override
  public void dispose() {
    //TODO (jos) What else do we need to dispose of?
    batch.dispose();
    dude.dispose();
  }
}
{'fraction_non_alphanumeric': 0.12712116701399226, 'fraction_numerical': 0.017862459065197976, 'mean_word_length': 3.5283018867924527, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4539274', 'n_tokens_mistral': 1345, 'n_tokens_neox': 1224, 'n_words': 253}