Code Monkey home page Code Monkey logo

minecraft-pi-target-practice's Introduction

Target Practice

Target Practice is a simple minigame written in Python for Minecraft Pi. In this game, the player must hit a moving target by positioning his Minecraft character in front of the target and pressing a physical Button module.

###Requirements

  1. A Raspberry Pi 3 with the Raspbian "Jessie" operating system installed. Other versions of the Raspberry Pi may work as well, but Target Practice has only been tested on the Raspberry Pi 3.
  2. A connected Button module for shooting at the target and an optional LED sensor.

###Installation

Copy all of the files to a directory on your Raspberry Pi. You can use any directory as long as the files are in the same one. The Button module is configured to use GPIO pin 22 by default. Change the number in line 215 in target_minigame.py to specify your own GPIO number.

###Starting the Game

  1. Launch Minecraft Pi, and enter any world.
  2. Open target_minigame.py in the Python 2 program on the Raspberry Pi. You should see the source code.
  3. Run the file from the Python 2 program.
  4. A message should appear on screen with instructions. Since this game requires some space, you will want to go to a flat and empty area in your Minecraft world. Floating in the air is one option.

###Controls Use your keyboard and mouse as you normally would on Minecraft Pi. Press the Button module to shoot a block at the target.

###API Reference Minecraft Pi's API is rather small, but you can find documentation on it at Stuff about="code".

minecraft-pi-target-practice's People

Contributors

adeeb1 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.