Results 1 to 4 of 4
  1. #1
    ki_ha1984 is offline Member
    Join Date
    Aug 2011
    Posts
    74
    Rep Power
    0

    Default command line window on java game

    hello .

    I am new in java and i have many problems.
    I have a AI game developed from someone else. The game is AI GAME COMPUTER VS COMPUTER.
    Now i have to create a textbox where i can send commands to game . something like command line.
    When i say commands, commands like to compare two old games logs to find differences.
    The logs are text files.

    Can i find any tutorial, or help for this???

    thanks

  2. #2
    aianta is offline Member
    Join Date
    Apr 2011
    Posts
    63
    Rep Power
    0

    Default

    If your brand new to java consider getting a refference book. I am currently using this one and its working great for me, it has working example and step by step explanations of everything:
    Amazon.com: Java How to Program, 7th Edition (9780132222204): Harvey M. Deitel, Paul J. Deitel: Books

    If you can spend the extra money I suggest you buy the latest and gratest edition:
    Amazon.com: Java How to Program (early objects) (9th Edition) (Deitel) (9780132575669): Paul Deitel, Harvey Deitel: Books

    Please know that what your asking is very broad, and you put in very few details as to what you want specifically so this reply is just a guess, I don't know if this is what you need.

    Now to attempt to answer your question:
    are the commands already written for you? You just need a text box to enter them?
    if so then look into using the java.util Scanner to get input from you and then interface that input with the commands you want. If you are looking to do this with gui it gets a lot more complicated so try the scanner for now.

    Or do you need to create command codes as well?
    if so then you have a LOT of work ahead of you depending on how many commands you want. For the command about comparing files this tutorial can show you how to read files, which is a start. Go from there.
    Java Read File Line By Line,How to Read File Line By Line in Java

    again, these are guesses please provide more info!

  3. #3
    ki_ha1984 is offline Member
    Join Date
    Aug 2011
    Posts
    74
    Rep Power
    0

    Default

    thank you very much .

    my problem is that i have to create some commands and command window to compare some files.
    thank you again .
    i will look at your links and i will reply for the results.
    i am new in java but i am php programmer and for me it is very big change .
    thank you again.

  4. #4
    aianta is offline Member
    Join Date
    Apr 2011
    Posts
    63
    Rep Power
    0

    Default

    Glad I could help. For a list of in depth tutorials check the The Really Big Index

    Other than that if you have any problems just reply to the thread :)

Similar Threads

  1. Replies: 0
    Last Post: 05-14-2011, 09:44 PM
  2. How do you use the Mac command line for Java?
    By java beginner in forum New To Java
    Replies: 16
    Last Post: 05-07-2011, 05:34 AM
  3. Replies: 2
    Last Post: 07-02-2010, 03:20 PM
  4. Calling a JFrame window from a command line program.
    By new_2_java in forum New To Java
    Replies: 7
    Last Post: 11-09-2008, 04:40 AM
  5. Unable to execute command line command in java
    By LordSM in forum New To Java
    Replies: 1
    Last Post: 08-08-2007, 01:23 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •