Saturday, August 13, 2011

Nameless roguelike for tutorial

Here's a little roguelike I made over a few days. It was mostly for my own amusement and to try a few different programming things so it doesn't have anything new or great. I also created a tutorial about how I wrote it. This applet can be downloaded and run from the desktop too.




Standard story: descend the Caves Of Slight Danger, find the lost Teddy Bear, and return to the surface to win. Use what you find to avoid dying. Press [?] for help.

main jar file: https://sites.google.com/site/trystansprojects/rltutfinal.jar
display jar file: https://sites.google.com/site/trystansprojects/asciiPanel.jar

[edit]Some people were having problems with it not displaying correctly. I think I've fixed it but let me know if there are problems.[/edit]

6 comments:

  1. Hello, I´ll like to see what your roguelike looks like but I can´t open the .jat files ( A java exception has ocurred) and I can´t play it here, I´m bolcked on --press enter to star--.
    Sorry but any idea that can help me?
    Luis

    ReplyDelete
    Replies
    1. To run it locally you need to type "java -jar rltutfinal.jar". Did you include the "jar" switch?

      Delete
    2. Sorry for my ignorance but, where i have to type it?
      I understand if you don´t waste your time with a noob XD.
      Luis

      Delete
    3. Open the Command Prompt, Terminal, or whatever your OS calls it. Change to the directory where you downloaded it to, then type it in.

      So, on Windows, you might go Start > Run > "cmd". Then type "cd \users\luis\downloads". Then type "java -jar rltutfinal.jar".

      That's just an example. Your OS and download folder might be different so you will have to type in something a little different.

      Delete
    4. I made that but still not working and I supose that I doing something wrong.
      I have a java.lang.NoClassDefFoundError,i´ll search on google how to fix it if you have any idea I usually visit your blog and you can help me to fix it.
      Luis.

      Delete
  2. Was getting java.lang.NoClassDefFoundError too from launching downloaded jar files. Tried specifying classpath:
    java -cp asciiPanel.jar:. rltutfinal.jar
    But it did not work
    Unpacked both jar files with 7zip, had this kind of folder hierarchy:
    /rootsrc/
    +_______/asciiPanel/ /*unpacked asciiPanel.jar*/
    +_______/rltut/ /*unpacked rltutfinal.jar*/
    removed all .class files, recompiled from cmdline
    launched from /rootsrc/:
    java rltut.ApplicationMain

    And it worked!
    (Just in case anyone reads it in 2016)
    (Java applet does not work)

    ReplyDelete