HI i currently have this code:
//Imports packages import java.io.*; import java.lang.*; //class name class Parkour //i think this is right public void static main ( String[] args ) //These varibles have been declared right { String proname = ""; String programq = ""; char programa = "y"; String programc = ""; int Strength =""; int Agility =""; int Charisma =""; System.out.println("Sub Question 3"); System.out.println("\nBy Harry Thompson cook"); //And here's where the problem starts: System.out.println("\nTron:Parkour"); System.out.print("\nWhat is your name:"); //Hope i've done this right InputStreamReader isr = new InputStreamReader(System.in ); BufferedReader buffer = new BufferedReader( isr ); //All Good? try { proname = buffer.readline(); buffer.close(); } catch ( IOException e ) { System.out.println( "Invalid Name choose again program!"); } System.out.println("\nWelcome" + name); System.out.print("\nWe must go through some basic setup options, Proceed y/n?"); InputStreamReader isr = new InputStreamReader(System.in ); BufferedReader buffer = new Bufferedreader( isr ); try { programq = buffer.readline(); buffer.close(); } catch ( IOException e ) { System.out.println("Invalid Input"); } if(programq == programa) { System.out.println("\n You have 10 energy point's"); System.out.println("\n You can use these to upgrade either"); System.out.println("\nStrength"); System.out.println("\nAgility"); System.out.println("\nOr Charisma"); System.out.println("\nEach of these Qualties can help you out on your mission"); System.out.println("\nStrength will help you out when the going get's tough"); System.out.println("\nAgility makes it easier to run from fights and can help in infiltrating buildings"); System.out.println("\nIf you choose Charisma you could use your looks to help you out in tough situation's"); System.out.println("\nNow it is the time to choose what skills you want:"); System.out.print("\nHow much energy will you give to strenth?"); InputStreamReader isr = new InputStreamReader(System.in ); BufferedReader buffer = new Bufferedreader( isr ); try { Strength = buffer.readline(); buffer.close(); } catch ( IOException e ) { System.out.println(\n You must input a number!); } { } else { System.out.println("Setup Will Exit"); }
So i know it's messy but if someone could help me out it would be very much appreciated.
Retro Man