Latest Diablo 3 News
DiabloWiki Updates
Support the site! Become a Diablo: IncGamers PAL - Remove ads and more!

A new run counter (complete with a timer)

Discussion in 'Single Player Forum' started by Skinny, May 22, 2008.

Thread Status:
Not open for further replies.
  1. Skinny

    Skinny Banned

    Joined:
    Aug 2, 2005
    Messages:
    367
    Likes Received:
    0
    Trophy Points:
    0
    A new run counter (complete with a timer)

    Hey SPFers,
    as a project for my Java class, I made a Diablo II run counter. You can get it here. It counts runs, computes the average time and keeps the total time, which should be handy in things like the MF Pentathalon. I'm open for suggestions about changes/adding stuff and fixing bugs (I tested it, but as always in programming some errors are bound to come up :)). Try it out and if you have any feedback (both positive and negative :)), post it here. Cheers,

    Skinny
     
  2. moo-cow

    moo-cow IncGamers Member

    Joined:
    Jul 3, 2003
    Messages:
    817
    Likes Received:
    0
    Trophy Points:
    120
    Re: A new run counter (complete with a timer)

    does this one not have the "feature" that the first run isn't counted?
     
  3. Skinhead On The MBTA

    Skinhead On The MBTA IncGamers Member

    Joined:
    Feb 3, 2006
    Messages:
    1,203
    Likes Received:
    0
    Trophy Points:
    120
    Re: A new run counter (complete with a timer)

    It doesn't work for me :sad: It tells me that:
    And this is what the Console says:
    Code:
    2008-05-22 16:33:43.882 Opera[391] CFLog (21): dyld returns 2 when trying to load /Library/Internet Plug-Ins/Java Applet.plugin/Contents/MacOS/Java Applet
    Exception in thread "main" java.lang.UnsupportedClassVersionError: Bad version number in .class file
    	at java.lang.ClassLoader.defineClass1(Native Method)
    	at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
    	at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
    	at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
    	at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
    	at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
    	at java.security.AccessController.doPrivileged(Native Method)
    	at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
    	at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
    	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268)
    	at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
    	at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
    
     
  4. muzzz

    muzzz IncGamers Member

    Joined:
    Apr 10, 2006
    Messages:
    2,421
    Likes Received:
    0
    Trophy Points:
    165
    Re: A new run counter (complete with a timer)

    Works for me. I've never encountered that particular error myself. But if I had to guess, I'd say your java version is older than the one Skinny compiled against. Try upgrading to the latest version of java.
     
  5. Uzziah

    Uzziah IncGamers Member

    Joined:
    Feb 20, 2004
    Messages:
    3,564
    Likes Received:
    0
    Trophy Points:
    255
    Re: A new run counter (complete with a timer)

    This is likely an issue, D2Lod is programmed slightly differently for mac than PC, if you are using a mac version of D2 then the program might have issues obtaining the data.

    But most likely your java versions are different.
     
  6. zerth

    zerth IncGamers Member

    Joined:
    Jul 3, 2006
    Messages:
    1,118
    Likes Received:
    0
    Trophy Points:
    165
    Re: A new run counter (complete with a timer)

    Yeap, Bad version number in .class file occurs when your jre version is older than the jdk version used by the developer. I typically have this problem with a colleague using 1.6 jdk, while I (for some odd reason) stick to 1.5
     
  7. Skinny

    Skinny Banned

    Joined:
    Aug 2, 2005
    Messages:
    367
    Likes Received:
    0
    Trophy Points:
    0
    Re: A new run counter (complete with a timer)

    Nope, it counts every run.

    Yeah, like the others said it's probably due to java version inconsistency.

    The thing is that the counter doesn't use d2 in any way. It only operates on the file system, and such java programs should be cross-platform. It could be used, with minor changes, for any game.



     
  8. Skinny

    Skinny Banned

    Joined:
    Aug 2, 2005
    Messages:
    367
    Likes Received:
    0
    Trophy Points:
    0
    Re: A new run counter (complete with a timer)

    I've already noticed an error- the current run time & total run time had a tendency to drift apart after a little while. That's already fixed, the version in the link is updated.
     
  9. Helx

    Helx IncGamers Member

    Joined:
    Dec 19, 2006
    Messages:
    364
    Likes Received:
    0
    Trophy Points:
    78
    Re: A new run counter (complete with a timer)

    Same as Skinhead on The MTBA here with my Mac. Silo's works for me, but must've been done with an older version.
     
  10. dizelsky

    dizelsky IncGamers Member

    Joined:
    Mar 10, 2010
    Messages:
    40
    Likes Received:
    0
    Trophy Points:
    5
    Re: A new run counter (complete with a timer)

    Could anybody share the link to this counter? it seems to be out of date. or any other run counter working at vista, except silospen's, because at long runs it shows too many of them. I need to count baal runs. thx in advance

    There's another two linked to in the ATMA help thread. Thyiad
     
    Last edited by a moderator: Aug 31, 2012
Thread Status:
Not open for further replies.

Share This Page