RPG-11
All that the light touches belongs to
Github
(18]
/
-W
Moofasa
||
This assignment will teach you how to work together to build a text-based
roleplaying game (RPG).
If you like making video games (it's one of the most common reasons why people
go into computer science, after all), then you will have fun with this. If you
hate video games, well, you can make something else I guess with permission.
Your game here should be fairly detailed, with the details required to get
100% found in the grading criteria listed below, so make sure you read over
both the group grading criteria and the invidual grading criteria before you
design your game with your group so that you hit all the mandatory
requirements. Also make sure you're all joined up on Github Classroom!
Invite code for 2024: https://classroom.github.com/a/A0bLXBOV
Purpose:
1) To teach you about collaborative design and implementation using Github
2) To have you get hands-on experience with inheritance in a big project
3) Visualizing circular linked lists
4) Using a BST to work as an inventory system
You MUST be in a group of 3 to 4 for this, and have it on our Github Classroom
where we can watch your development efforts.
Grading:
10 points will be for group effort
10 points will be for individual effort
Group Effort:
5 points Quality of the game each bullet point is one point
A) Is it a fun game?
B) Does it have a decent amount of content in it / take at least a little
while to win?
C) Does it have an interesting world map in color?
D) Can you win and lose?
E) Is there combat?
3 points - Documentation. Write a README.md that:
A) describes your game including directions on how to win, key commands,
command line parameters, etc.
B) Uses Markdown to make it more interesting than just a boring text file.
You should at a minimum have some bullet points, some colors, and at least
one image embedded in it that is the logo of your game
C) List all of the people who contributed to the project (if they didn't
contribute, don't list them), and note which person or people did each of
the bullet points in this project, including the group and individual
bullet points (i.e. who wrote the documentation, who did the BRIDGES
circular linked list, who designed it to be sure it was a fun game, who
made the world map, etc.) If any bullet points are not done, NOTE THEM, do
not make me hunt around for it or you will get a negative point. It's best
to just list all the bullet points here in the README in order and note which are done and by who.
2 points Consistency of work:
A) Screenshot the state of your game as of one week in
B) Screenshot the github commit log for your game showing a consistent set
of commits over time rather than waiting to the last minute (include both
of these in your README.md above)
Note: Fake commits, like adding and removing comments to make it look like
you're being active (which a student tried in the past) will result in
negative points. Don't try to inflate your commit record.
INDIVIDUAL WORK 10 points
-
Person A "The Inheritor of Suffering": This person is responsible for
building a class hierarchy consisting of a pure virtual / abstract class
called Actor (which is anything with an x,y location in the world) from which
you have classes inheriting off of it, including stationary objects, Heroes,
and Monsters. The Hero class should have at least four classes inheriting off
of it (such as Wizard, Fighter, Thief, and Cleric, but you can pick whatever
you want) that have to all be different in some meaningful way, and you should
inherit off the Monster class for at least five types of monsters, including a
Boss monster that you have to kill to win the game. Write in the README.md
file a description of your class hierarchy and include all the relevant code
at the end of it. Make a diagram showing the relationship of the different
classes.
In the game itself, the player should be playing a party of 4 to 6
heroes and walking around killing monsters and doing quests.
All these classes need to actually work, do interesting different stuff, and
be reasonably detailed to get a 10/10.
Person B - "The BRIDGEngineer". This person is responsible for creating a
circular linked list in BRIDGES that represents the initiative turn order for
the heroes and enemies in the current combat. Combat in the game should
involve fights of at least four people on each side most of the time (a boss
fight or whatever could be 6 vs 1). Each Hero and Monster should inherit from
a class called HasInitiative that gives them a speed member variable that can
be from 1 to 40. When combat begins, roll a d20 and add it to their speed
variable, and then sort them so that the fastest goes first. When they are
finished with their turn, go to the next in the list. When you get to the end
of the list, go back to the top of the list. When a hero or monster dies,
remove them from the list.
At any point in the combat, the user should be able to hit a Snapshot command
that sends a visualization of the current turn order to BRIDGES. Each node in
the circular linked list should have a label on it with the name of the actor
as well as their initiative.
Helpful help file: https://bridgesuncc.github.io/tutorials/CircularDoubly LinkedList.html
Attach a screenshot visualizing your combat turn order in the README.md
You shouldn't just hard code a single combat visualization, but have the
ability to visualize the turn order for any combat you are in to get a 10/10.
Person C "JJK Curse Lord": Your job will be to learn the NCURSES library and
use it to create both a UI for your game (with or without using NCURSES
windows) and also a scrollable world map with interesting features on it like
towns and lakes and so forth. You have to use color, have it work in raw mode
(non-cooked) and have it work with arrow keys. You should also display the
combat on screen, as well as inventory and anything else crucial in addition
to the world map.
Curses was used to make Vi/Vim/Nvim work in full screen character mode, rather
than the line-by-line "cooked" mode you are used to using with Cin and Cout where you output one line at a time and everything scrolls off the top of the
screen. In Vim, you can actually move the character up a line, and you don't
have to hit return to enter a string, it will read each character one at a
time immediately after being typed.
Documentation: https://invisible-island.net/ncurses/ncurses-intro.html
Easier Intro: https://www.linuxjournal.com/content/getting-started-ncurses
More Documentation: https://tldp.org/HOWTO/NCURSES-Programming-HOWTO/
I also have lots of demo code for you. You could also use my Colors library if
you want (/public/colors.h) which is like a stripped down version of NCurses
To get a 10/10 you must demonstrate reasonable proficiency with NCURSES. Fire
up 'nethack' on the server and see what a reasonable NCURSES application
should roughly look like. It should be full screen, have different areas of
interest in them, have colors, should scroll around as you move, have the
party move around on the map when you hit arrow gets, show inventory, etc.
Person D "Sephiroth, Master of the Tree": Your job is to implement an
inventory system using a BST. You can make your own BST or use the
multimap class in the standard library to do so. Your inventory
system needs to support the following commands at a minimum: A) Print all
items you have in your inventory in alphabetical order B) Be able to have
multiple copies of the same item in your inventory (such as having 100 arrows
and 2 healing potions). C) Be able to pick up and drop items, and buy items
using gold (which you track in your inventory) from a merchant in the world.
You should be able to sell non-Key Items to the merchant as well. D) Have
special Key Items for solving the main quest in your game that cannot be
dropped (if the player tries dropping it, disallow it); they can only be
removed by solving the quest they are part of. E) Monsters should have
randomly generated inventories that will drop to the ground when they are
defeated. F) Items should have interesting and different statistics, for
example you could have a minor healing potion and a major healing potion that
heal for different amounts of damage, or weapons with different speeds (they
add or subtract to your initiative), damage values, and costs at the merchant.
You will probably need some sort of Item class that has a name that is used to
sort the items in the Multimap (or you can write an operator< so that your Items
can be sorted alphabetically in a Multiset instead) as well as finding it.
Each string used to name an item in a Multimap needs to be unique to that
item, as that is what is used to insert, search, and delete the item.
To get 10/10 you need to write your own BST class that can support all of the
above operations. If you use the Multimap or other STD options, you will get
an 9/10 instead, and note that in the README.md file.
You need to work with the Curse Lord to make sure the inventory is properly
displayed, with the Inheritor of Suffering to make sure that each hero and
monster has an inventory, and make sure the items can be dropped on the ground
and picked up (and bought and sold at a merchant) for 10/10.
頑張って!
If you have a 5th person (by professor permission only) they are the "Scared
Balloon" role, and they have to implement a dynamic weather system and a
quest system./n3
6
9
12
151
18-
21
24
27
30-
33
36-
39-
42
451
48
51
54
57
10
4
60
60
60
60
63
66
10
10
13 16
6.
19
22
22
25
28 31
34
36
37 40
10
43
46 49
52 55
58 61 64
120
67
70
73
73
སྐྱེ སྠཽ སུཾ རྒྱ ཆ རྒྱ རྞ མྦཎྞཱཎྜཾ & $ ཥུ ༔ $ ྂ ཙཾ བྲྀ
122
107
101
104
131
69
134
69
72
75
78
81
84 87
90 93
96
99 102 105 108 111 114 117 120 123 126 129 132/n Zip file has the notes, so you can use them for the reference
the only part is the bst part that is missing
you can use the readme file to see the instructions
Student is person D
the other parts should be done or almost done, regardless if they are
done or not student's only responsability is person D BST
Need to provide modified code files
Need to use the given code file to code student's part
Just make what person D is supposed to do/n Updated Tasks To Accomplish
Thanks For All The Support, hope this is helpful, send message if you have questions.
See the conclusion section for additional information.
Communication is key, according to today's lecture, so we can make the most of the final day by
working with each other.
For future projects, we could do all this in the first week and be golden. I'll put the details here
into the README.
1. Really Annoying To Sort Linked List:
a. Create vector of actors (works with monsters and heroes)
b. Sort by initiative
c. Add actors in this order to the double linked list
2. Add to makefile compile flags if not already: -lcurl -lbridges -lncurses.
3. Party can move in unison around map with only one icon (I Think A Capital P).
4. Actor is any object with a position:
a. Merchant, Treasure Chest, Item Pickup, House, etc.
b. Walls are not an actor, because you don't interact with them.
5. Have Actor just have x and y position.
a. Then have a subclass of Actor TakeDamage that handles damage.
b. Hero and Monster inherit from TakeDamage so they can hurt each other.
c. We can model damage with just health points and harming, no need for defense.
6. Markdown Tips:
a. To insert an image, do .
b. This url can be anything.
7. Putty Copy Tip: Shift-click highlight text in putty to copy to computer clipboard.
8. On Inventory Items:
a. Viewable in window in ncurses.
b. Item class to find and sort items by name.
c. Each Hero and monster has inventory.
d. Items drop on ground (disappear I suppose), pick up items around world that are
e.
at certain place.
f. Key 1: Dynamite? Key 2: Ham and Eggs? (based on Kaitlyn's story idea)
9. On Combat:
a. Monsters randomly pick a number from 1-4 to choose what character to damage. b. Highest initiative goes first.
Questline: (Put This Stuff In README)
Conclusions
Spawn in shelter (merchant in shelter. Quest 1: Kill weak monster (1 hit or something
lol). Quest 2: Use gold from monster to get key item dynamite at merchant, blow up
barrier, fight other monsters (4 of them in a room) Quest 3: Bring back the food (ham
and eggs, key item #2) to the shelter, and defeat the final fire boss that results from
cooking the food.
Character: Firefighter (Water, good against final boss), Soldier (explosive, strong against rocks),
Looter (Baseball bat, does both but not as well), Doctor (heals one person, set health to max).
All characters have basic attacks (Hero class), and then their own attack.
Loot Table Items (Random Drop From Weak Monster): [10 Gold, Damage Boost Weapon,
Small Heal].
Merchant Items: [Dynamite (Key Item #1), Big Heal].
1. Stationary objects are Actor. Inventory person has Item class to make. Item inherits
from Actor for the xy position.
2. TakeDamage can be a separate class from Actor like Has Initiative, and Hero and
Monster inherit take damage. Hero/Monster inherit from Actor, Has Initiative, and
Take Damage.
Kaitlyn's updated story context (Nonbinding, for actual gameplay progression see Questline
above):
I was looking thru the wiki for the 1906 earthquake. The only fire on there
that was given a name was the Ham and Eggs fire, which happened because a
woman was making breakfast with a damaged chimney. I was thinking that we
could make a story based on this and the final boss be the Ham and Eggs fire.
So basically the premise is that your party is trying to scavenge for food for
the survivors of the earthquake, who are currently huddled in a makeshift shelter.
There is a supermarket nearby, but the way to get there is blocked by rubble and
destroyed buildings. You have to traverse the terrain using dynamite to clear all the
wreckage from the path, and maybe that could be an object to purchase from the
merchant. And of course, there's also the rock monsters that have to be dealt with along the way. Once you get to the market, you have to pick up ham and eggs,
those are Key Items for the Main Quest. You bring them back but along the way,
you notice that there are small fires that were caused from the all the dynamite
usage, which actually occured in real life disaster due to improper dynamite use.
This will foreshadow the final boss.
Once you give the ham and eggs to those in charge of food prep, they start
cooking but Oh No the chimney's broken, boom final boss fight. The fire that
starts, along with the other fires that your party started throughout the journey,
come to make up the Ham and Eggs fire that surrounds the entire shelter. During
fights with lesser monsters, most of the attacks would be based on explosives and
blunt force, but you have to fight the fire with water this time./n/n
