brent carter

Ranch Hand
+ Follow
since Dec 15, 2011
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by brent carter

I am writing an application that allows me to write notes and save them so the next time I open the program I will have a list of those notes that I can then add to, edit or delete. Do I need a database for this?
10 years ago
Whenever I make a game I always run into the same problem. I create a hero object, but after doing a few things with it I run into scope problems. For example: I will create a dungeon class to make dungeons. I am not sure how my hero object should interact with this class that makes dungeons. Do I have to pass my hero object as an argument to the dungeon class? Do I forgo a dungeon class and just create a dungeon method on the same scope as where I created my hero object?

What is the best way to structure a simple game that has a hero that traverses through a dungeon?

Thanks.
10 years ago
basically, i just have System.out.println("AND A WHOLE LOTTA TEXT HERE \n AND HERE \ n AND HERE\n\n\n\n\n\n"); In the console it all comes out in a massive blob and i want to break it in to sections, so after 2 or 3 sentences the user has to press a key to continue reading the text. I want to do this without writing massive input codes everywhere, I guess i could just write a class to do it for me. just wondering if anyone else did it first
12 years ago
Hi guys. I have long paragraphs of text and I want to make it so after a few lines it asks...press any key to continue..etc. I tried creating a new scanner instance but that didnt work. Is there any way to do this, or is there a java util that already does it?
12 years ago
this might be alittle of topic, but it seems to me that most of the big programming jobs are going to c++ programmers. Is this accurate?
12 years ago
thanks guys...heres my progress and everything seems to work
12 years ago
thanks guys, you both sent me on the right path. However, when i set it to null it prints out the word null so obviously i am dong that wrong, and how would i go about creating a new list without that item? it wont let me use -= char1.item[counter].

12 years ago
hi guys. I have an array item[] with 5 strings in it. I want to have it so if a person inputs one of the strings, java recogize that the input belongs in that array and removes it. (something like, if input = arrayitem, array = array - input). Can anyone point me in the right direction?
12 years ago
ritchie if i dont make them public, my other classes dont recognize them
12 years ago
ive done some more reading and figured out how to make an array and solve this problem. I am not going to even bother posting my further questions about arrays because I know that I will figure this stuff out on my own as I keep reading. Thanks for the help guys.
12 years ago
thanks, that asnwered another question I had of why it made me specifically import that class
12 years ago
I have a list of items that I keep track of in a method in my character class. In another class, I want to be able to print out and keep track of whichever of those items i still have in that method in the character class. In other words, if i have an apple, banana, and orange, I want to have a code that can scan my list of items, see which ones i have and register those in this new class. here is my code. There is a good chance this simply involves making a list, but I don't think I have learned to do that and for some reason the internet is so hard to find the answer to simple questions.

12 years ago
thanks stephan. this was great advice and set me in the right direction
12 years ago
Hey guys. I am trying to make a 4x4 (16 room) cave for a mock rpg I am making. What would be the best way to work out the travel mechanism. I am surely going to make every room its own class. I could do it by making a whole bunch of if else statments (if selection.equals("north") run room A3 etc.) I was just wondering if there is a better way to go about doing this. Thanks
12 years ago
thanks Jeff for the great post. This makes things a lot clearer. So just to make sure I understand, if i have something in a class like:

public void console(){
String name


the string name exists only in the method console. Once the method ends name goes away.
12 years ago