Code Monkey home page Code Monkey logo

battlecode-server-2017's Introduction

Battlecode Server Build Status

If you're a competitor, you don't need to be here.

Unless you're a hacker.

Basic Guide to Building

Java 1.8 is required. Make sure you have the JAVA_HOME environment variable set to the appropriate value for your system.

  1. ./gradlew build - to build
  2. ./gradlew javadoc - to make javadocs
  3. ./gradlew test - to run tests

Basic Guide to the Codebase

Inside src/main/battlecode you'll find all the important code for the engine:

  • common: the simple classes available to all competitors, such as Direction, Team, and RobotController.
  • world: the folder that contains most of the gameplay implementation. Here are the most important files:
    • GameMap: information about the game's map.
    • GameWorld: holds the map as well as all the robots on the map, and information about teams (such as team score). The core gameplay code (processing events by visiting signals and keeping track of global team stats) is here.
    • InternalRobot: the class that describes a single Robot and its properties (health, delays, location, etc.).
    • RobotControllerImpl: this implements RobotController. If you're wondering what happens when you call a RobotController. method, check the method's implementation here. RobotControllerImpl interacts heavily with GameWorld.
    • XMLMapHandler: reads the map from the XML file.
  • world/signal: the Signals are objects that hold information about events in a game of Battlecode. These are serialized and then transferred to the client, which processes these events and performs the necessary updates.
  • analysis: deprecated code that would be cool to bring back.
  • doc: tells Javadocs how to create the documentation. RobotDoc is pretty important.
  • instrumenter: handles instrumenting player code so that it is isolated, deterministic, and counts bytecodes.
    • instrumenter/bytecode: the actual bytecode-modification code.
    • instrumenter/inject: classes we replace various parts of java.lang with. Also contains RobotMonitor, which counts bytecodes.
  • server: contains the main class that starts up the engine.
  • serial: contains some information that gets sent to the client as part of every match, such as who won.

battlecode-server-2017's People

Contributors

aepstein824 avatar aibolit avatar asugaya avatar bovard avatar cixelyn avatar cwgreene avatar dgulotta avatar dvorak42 avatar edstiles avatar garywang avatar goldob avatar halfvoxel avatar here avatar hjax avatar jbloxham avatar jhyde369 avatar kazimuth avatar mzhang94 avatar nfearnley avatar nmccoy avatar npinsker avatar pear0 avatar pwnall avatar shewu avatar stefangimmillaro avatar trun avatar uldivad9 avatar vontell avatar ygina avatar

Watchers

 avatar  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.