Giter Site home page Giter Site logo

siarl / sd-project-2020-vu Goto Github PK

View Code? Open in Web Editor NEW

This project forked from s2-group/software-design-vu

1.0 1.0 0.0 4.78 MB

Project for Software Design (XB_40007), Computer Science @ VU Amsterdam, 2019/2020. TextAdventureGame Group 7: Koen van den Burg, Bogdan Cercel, Claudia Grigoras, Sofia Konovalova, Wilkin van Roosmalen.

Home Page: https://studiegids.vu.nl/en/2019-2020/courses/XB_40007

License: GNU General Public License v3.0

PureBasic 3.61% Java 96.39%

sd-project-2020-vu's People

Contributors

bojanaarsovska avatar claaudytza avatar gkrls avatar iivanoo avatar koenvandenburg avatar nicholaskozanidis avatar reglayass avatar sarthakg17 avatar siarl avatar xidot avatar

Stargazers

 avatar

sd-project-2020-vu's Issues

Assignment 2

Here we can discuss and plan Assignment 2


Assignment 2

Modeling. By building on assignment 1, you will model the system via UML models (see the Modeling section in the Team Project guide).

Implementation (base). You implement a minimal subset of the system (e.g., the text adventure game allows only empty rooms and basic movement of the user). In this context, the goal is to show the instructors that you acquired the basics about how to correctly represent your modelled design solution in Java.

The revised version of assignments 1 and 2 will be taken into consideration to see how the instructors’ feedback has been addressed.

Carefully follow the structure of the document provided here: https://github.com/S2-group/software-design-vu/blob/master/docs/assignment2.md (Links to an external site.)

IMPORTANT: when submitting, provide the URL of the GitHub pull request corresponding to your submission. Submissions without such URL will be ignored.

Grading. This part represents 50% of the final grade of the team project.

Assignment 2 Rubrix

Part Points (total = 60)
Feedback from Assignment 1   10.0 pts
Class diagram   10.0 pts
Object diagram   10.0 pts
State machine diagrams   10.0 pts
Sequence diagrams   10.0 pts
Implementation   10.0 pts

Let's go!

Add Characters

Current implementation?

Currently the only character in the game is the `Player':

public class Player implements Interactable {

    private String name;
    private List<String> inventory;
    private PlayerStats playerStats;

   /*
    Interactable methods here
   */

   /*
    Getters & Setters here
   */
}

What needs to change?

More characters should be added to the game besides the player. We need friendly characters the player can talk with and enemies the player can fight with.

How is this implemented?

  1. Abstract Class Character needs to be added. The Character will contain the implementation of the inventory (the list and also the getters and setters). The Character abstract should implement the Interactable interface.

  2. The Player class will extend the Character abstract (thus removing the inventory implementation from the Player code).

  3. A new class Friend (extends Character) needs to be added. Friends should be able to have conversations with the Player. A new class Conversation (extends Interactable) should be added and used as an attribute to Friend. When in a conversation, players can use a limited set of commands. The player is locked in a loop different from the main loop in Game.

  4. A new class Enemy (extends Character) should also be added. Instead of having a conversation with the Player, Enemies can engage in combat.
    New class Combat should be added. When in combat, the commands the player can use are limited. The player is locked in a loop different from the main loop in Game. Let's keep Combat a simple game of rock-paper-scissors for now.

  5. Characters should be maintained by the Scene class, as characters can only be in one scene. More info on that later.

TODO

please tick off when you are done and also comment

Branch: Assignment3

Multiple Effects mapped to one Command

Current implementation?

When a command is entered, the Actions object handles it in onCommand(Command command, Callback callback):

    @Override
    public boolean onCommand(Command command, Callback callback) {
        if (hasCommand(command.getAction())) {
            Effect effect = getEffect(command.getAction());
            if (effect != null) {
                effect.apply(command.getGame());

                callback.onMessage("Effect applied... " + effect.toString());
            }
            return true;
        }

        return false;
    }

The Effect object mapped to the specific command string is retrieved and applied.
What exactly happens when an Effect is applied depends on the Effect.Type.

What needs to change?

One command should be able to apply multiple effect types.

How is this implemented?

New class Effects should be added. The Effects should contain a collection of Effect objects. Effects should also contain an apply() method that simply applies all the Effect objects at once.

Instead of mapping the command string to an Effect object, it should be mapped to an Effects object.

TODO

please tick off when you are done and also comment

Branch: Assignment3

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.