Code Monkey home page Code Monkey logo

chronos's Introduction

chronos's People

Contributors

bitbrain avatar

Watchers

 avatar  avatar

chronos's Issues

Provide inner type reflection of generics

Create a class which provides the class of the inner type of a generic. For instance:

ReflectionTemplate<String> string = new ReflectionTemplate<String>();
// Should output: java.lang.String
System.out.println(string.getInnerClass().getName());

Independent resource loading order

When a resource depends on another, the other one should be loaded first to avoid missing resources. Dependencies should be calculated before loading any resource and the loading order should be changed. This must affect on deferred resources as well.

Missing constructors for BasicEntity

When creating a new BasicEntity instance, it should be possible to give information about position and size. It has to look something like this:

public BasicEntity(float x, float y, float width, float height) {
/* ... */
}
By doing so it should be more easy to extend the class.

Extendable game updater which updates a game

Write a game updater which is able to update a game. It should be extendable, e.g. it should be able to update via FTP, FTPS, SVN or HTTP by injecting the functionality.
Also it should support listeners to abort the process or handling output.

A possible product would look like this:

DataProvider provider = new SVNProvider("path-to-repository", "username", "password");
GameUpdater updater = new BasicGameUpdater(provider);
updater.addListener(new GameUpdateListener() {

   @Override
   public void onStart(UpdateEvent event) {

   }

   @Override
   public void onProgress(UpdateEvent event) {

   }

   @Override
   public void onAbort(UpdateEvent event) {

   }

   @Override
   public void onSuccess(UpdateEvent event) {

   }
});

updater.execute();

Create and test FamilyObject

Create an interface FamilyObject, which provides support for adding children and parents, implement it and test it.

Scripting support for entities

Write a script implementation which invokes different scripts to an entity. Possible implementation:

ScriptFactory factory = new BasicScriptFactory();
Script pythonScript = factory.create("script.py");
Script luaScript = factory.create("script.lua");
Script jsScript = factory.create("script.js");

Entity entity = new Entity();
entity.addListener(pythonScript);
entity.addListener(luaScript);
entity.addListener(jsScript);

Scripts are listeners for entities so they can be easily added.

Script resource support

Create a script loader which is able to detect given script types and applies them to the resource manager like:

<resource type="script" id="script1">script.lua</resource>
<resource type="script" id="script2">script.js</resource>
<resource type="script" id="script3">script.py</resource>

Write a resource manager which provides resource loading

Write a singleton resource manager which provides resource loading. For example:

Resource<String> resource = ResourceManager.getInstance().getResource("my_id", String.class);

Therefore the manager needs to know which resources are supported.

Create data provider

Provide a data provider interface which can update a game:

public interface DataProvider {

   DataSource getMetaData();

   DataSource getChronosData();

   void download(String file) throws DownloadException;

}

Listener support for game entities

Make an entity observable. It should be possible to add listeners to an entity like this:

Entity entity = new Entity();
entity.addListener(new EntityListener() {

   @Override
   public void onCreate(EntityChangedEvent) {

   }

   @Override
   public void onUpdate(EntityChangedEvent) {

   }
});

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.