Creating a Gun in Java, I'm completely lost.
Hi all, I'm a student currently learning Java and I have an assignment I am extremely stuck with. We haven't done much programming before so I'm finding it tough but I have to provide the code for a Gun. Here is what I have so far:
Code :
{
int currentChamber;
boolean [] chamberArray;
public Gun()
{
chamberArray[0] = false;
chamberArray[1] = false;
chamberArray[2] = false;
chamberArray[3] = false;
chamberArray[4] = false;
};
void RotateCylinder()
{
}
void InsertBullet()
{
}
}
I'm struggling to get ANYTHING working for the two methods. Can anyone please help?
Re: Creating a Gun in Java, I'm completely lost.
You don't even specify what those methods are supposed to do. Write out a detailed summary of each method and what they're supposed to do, and you'll have a nice starting point.
I recommend you read the link on asking smart questions from my signature, and this: Starting Writing a Program