Skip to content

Yunxian#35

Open
yunxianding wants to merge 103 commits intojcrouser:mainfrom
yunxianding:yunxian
Open

Yunxian#35
yunxianding wants to merge 103 commits intojcrouser:mainfrom
yunxianding:yunxian

Conversation

@yunxianding
Copy link

No description provided.

tnphammy and others added 30 commits April 13, 2025 17:04
I was thinking about Item.java on my way back. I thought about A8, we can overload the constructors to accept different parameters. And this way, we can write all the items in this(maybe not computer because it's more complicated). We can let : Item teddyBear = new Item(...)
Notes:

1.I deleted several items to start small and make it easier. We can always add more later.

2. I added the two souls as instances of items. We can try setting the two souls as items instead of writing a soul class.

3.I think printManifest of all the items should be in room classes instead of Item class. We could store the available items in an arrayList and print out.

4. I'm unsure of whether this will work. Should we start a main class and put this main method in?
I also deleted computer as an item. We will write a separate class for it because of its complexity.
I kept the description for each room in the command and I added attributes of a name and an arraylist of items. A wild idea: Can we write bedroom and lab as instances of room instead of starting a subclass. But if so, how do we deal with the computer?
I think it's a better idea to let bedroom and lab be instances of the room instead of subclasses
This is the class where we implement the classes and methods we have written and run the game. I currently created the items and two rooms. Much more to be added later, but this is a good start!
We can take advantage of this attribute later. If laserActive == true && (the user chooses to walk), the player will die, achieving the first ending.
Wrote basic code for the majority of methods/accessors in Existence; Overrode fight() in Human and Robot Class
…loaded selfDestruct methods for better functionality
yunxianding and others added 30 commits April 28, 2025 21:16
1. I updated the descriptions for the items and added the `door` item that connects the bedroom and the lab;
2. I Implemented`health`, `inventory`, `look`,  `touch` and `inspect` in game loop
3. Still need to put the other commands inside game loop, as well as tasks, stages and endings
4. I closed scanner outside of the game loop so that it runs normally.
5. I've tested running the game loop and it looks decent.  Still many things to be added, but at least we have something to run now!!! We are almost there!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants