SIE508 Homework 2-Classes Avatar and Game Solved

30.00 $

Category: Tags: , , , , ,

Description

Rate this product

Classes Avatar and Game

Assignment
Design and implement two classes: Avatar and Game.

A Game object is initialized without Avatars objects. It should have a method startGame, which initializes an internal empty list of Avator objects. Further, it needs a method to add an Avator object at a time to the Game. A Game object also has a method to animate all its current Avatar objects. Furthermore, it should have a method to stopGame, which destroys all current Avator objects in its internal list.

The Avatar class should create simple human-type Avatars, with attributes such as name, hair color, height, gender, superpower. An Avatar object can change its hair color and superpower. It also has a method that “animates” the avatar. The Animate() method should print out the Avatar’s object variables.

The main program should create 4 different Avator objects that resemble 4 characters from the Super Mario series (https://en.wikipedia.org/wiki/Super_Mario). The program should create a game object ‘super-mario’ and the avatars should be added to the game and ‘animated’ once.

Note, that this assignment does not require any game engine or real animation of characters. The design should be similarly simple to the Dog example in class.

Each class should be in its own .py file, and the main.py should also be in its own .py file.

Deliverables

1. A or several .py files with all the code.

  • sie-508_hw2-main-93qawl.zip