Giter Site home page Giter Site logo

semesterproject-4's People

Contributors

alexandernorup avatar gorm2303 avatar jonaskaad avatar magnuskjaer avatar sebmon avatar victoraboye avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

alexandernorup

semesterproject-4's Issues

Refactor monsters to have URL's instead of images

Make the monster class contain two URL's/paths that lead to their front and back sprite. This needs to be implemented in all relevant places: JSON parser, the monster class and interface, and where the monsters are drawn.

Import and setup Tilemaps into LibGDX

We should be able to import .tmx files into libgdx and show them. Ideally this includes collision, as Tiled has support for assigning collision in the editor.

MapView implements IGameViewService
Hav metoderne.
Sprite til map. tilemap

This issue blocks #52

Create the battle-scene simulation

Should simulate the battle between two IBatttleParticipant each using an amount IMonster.
The battle should be turn-based.

This should only be a simulation, and not focus on actually drawing the battle, as that should be handled by #17.

Discuss that method should be used in order to send information to the battle-scene of what to draw. Either the battle-scene view will inject an interface when creating the battle-simulation that will allow the battle-simulation to command the battle-simulation of what to show. Or use a publish-subscribe pattern so the battle-simulation will "publish" all battle events, which the battle-scene then subscribes to in order to display the battle accordingly.
There are pros and cons to each method. Just injecting an interface is simpler, and make it easier to actually synchronize the battle-simulation and battle-view. But on the other hand, the publish-subscribe pattern would allow other packages or modules/components to follow along with what happens inside the battle which could be beneficial.

Remember to create unit tests for the simulation

Prioritization draft

MoSCoW of all requirements until now.
Decide requirements to complete in first iteration.

Update design for Battle

Update the interface document to reflect the changes that have been discussed (transfer responsibility from Battle to Monster, split Battle up, etc.)

Create Monster component

Create the Monster component:

Monster class implementing relevant interfaces.

  • Create relevant variables
  • Implement the relevant methods

Monster Plugin

  • Create an instance of a Monster (Create a Charmander)
  • Create some moves?

Create Player bundle for Map

This bundle should represent the player.
The bundle should include:

  • A player class that extends the entity class
  • A Player plugin. This should instantiate the player with certain parts.
  • A player control system class

This issue blocks #52

Create a battle-scene view

In order for the game to have a turn-based battle gameplay, we need to create the actual visual scene shown to the player.

This issue should only create the view itself. - not the actual simulation or handling of battles.. The idea being that we don't want to tie the visuals (presentation-layer) together with the code that does the actual simulation together (domain layer). I'm not saying that we should componentize each part (although that could potentially be possible I guess). But even though the parts are in the same component, I still think we should try and use best practises from OOP/VOP and keep the different parts as loosely coupled as possible.

Create an interface that contains all methods the battle-simulation would have to call in order to visualize the battle that it would be simulating. These methods could be, but this is just an example:

  • void setPlayerMonster(IMonster monster)
  • void setOpponentMonster(IMonster monster)
  • void doPlayerAttack(IAnimation animation, int newOpponentHealth)
  • void doOpponentAttack(IAnimation animation, int newOpponentHealth)
  • void showText(String text)
  • boolean isAnimating() (Skal signalere til Simuleringen at battle-scenen ikke er klar til at modtage nye kommandoer endnu, fordi en animation er igang).
  • etc.

Make some code that draws the battle-scene itself, and make some way to allow the simulation to control the view using the interface.
Alternatively
Make the battle-simulation provide a publish-subscribe pattern which the battle-scene subscribes to, and use that to send messages from the simulation to the battle scene.

Discuss with the developers of #19.

Testing

This might be hard to unit test. Even more to describe how to without knowing how it is going to be implemented.
See if you can think of something. If you can't think of anything, then just make some tests that assert that exceptions will be thrown if you call setPlayerMonster(null) or something similar.

MonsterRegistry

Make monster registry - decide if it should be its own module or part of the monster module

Put together Map, Player and NPC

Make the different bundles/modules work together such that:

  • The player can move around the map
  • The map has collision
  • NPC's can be in static positions
  • NPC's can move randomly around the map

Map
MapProcessing implements IEntityProcessingService
MapParticpants (Liste af entities)

Create NPC bundle for Map

This bundle should represent an NPC in the map view.
The bundle should include:

  • An NPC class that extends the entity class
  • An NPC plugin class that instantiates the neccesary parts
  • An NPC control system class

This issue blocks #52

Create BattleScene related DTO interfaces

Blocks #17

Create DTO (Data Transfer Objects) interfaces that should be used for the BattleScene.

From the top of my mind, the following comes to mind:

  • IMonster (Represents a monster. Has Name, HP, Stats, Sprites (Maybe even front and back-sprites), List etc.)
  • IMonsterAction (Represents a "move" or "attack" that the monster has and can use. Should contain info like: Name, Desscription, Damage, Effect, Type, IAnimation, Sprite)
  • IAnimation: En eller anden repræsentation af en animation. Læg hovedet i blød. Men bare lav nogle simpelt det kan udvides senere
  • IBattleParticipant: Has list monsters of monsters along with properly other stuff (Maybe methods that can be probed for input? (Either from the player or the AI) I don't know.
  • Probably a lot more when you get into it

Requirements analysis

Connect the given project description and our ideas, to the requirements, with a description of our gameplay and perhaps a full use case diagram

Setup the project with OSGi or NetBeans

Setup the project with either:

  • OSGi
  • NetBeans Module System

Configure it such that it's possible to use either its whiteboard model or dependency injection. Through either the Lookup API or the BundleContext API

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.