Thread: 1 error (possible loss of precision) when compiling(Help appreciated)

Results 1 to 3 of 3
  1. #1 1 error (possible loss of precision) when compiling(Help appreciated) 
    Registered Member
    Join Date
    May 2013
    Posts
    140
    Thanks given
    6
    Thanks received
    9
    Rep Power
    0
    I am trying to add [Only registered and activated users can see links. ] to a source I am working on, and I get 1 error when compiling..

    The error I get is:

    client.java:16800: error: possible loss of precision
    announcementTimer = System.currentTimeMillis();
    ^
    required: int
    found: long
    1 error
    Finished!
    Press any key to continue . . .

    the code added which contains the above 'error' within it is located in the client.java and is:

    if (System.currentTimeMillis() - announcementTimer > 900) {
    announcementTimer = System.currentTimeMillis();
    sM(Announcements.getAnno());

    }

    Any and all help is appreciated!

    Thanks in advance!

    P.S. don't flame about how you hate delta or it sucks, it's my choice to use it.


    Reply With Quote  
     

  2. #2  
    Registered Member
    Join Date
    Nov 2011
    Posts
    108
    Thanks given
    5
    Thanks received
    2
    Rep Power
    11
    The error already tells it.

    required: int
    found: long
    Reply With Quote  
     

  3. #3  
    Registered Member
    Join Date
    May 2013
    Posts
    140
    Thanks given
    6
    Thanks received
    9
    Rep Power
    0
    I am aware of that now, thanks for the help though you all.


    Reply With Quote  
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [Help] Error when compiling [PI]
    By dylcompton in forum Help
    Replies: 2
    Last Post: 06-04-2012, 05:01 PM
  2. Replies: 2
    Last Post: 01-12-2012, 12:15 AM
  3. LOss Of Precision!?!
    By Bando in forum Help
    Replies: 2
    Last Post: 08-23-2009, 11:04 PM
  4. Replies: 1
    Last Post: 05-12-2009, 06:23 PM
  5. Javac error when Compiling? - Fix it!
    By Mickle in forum Tutorials
    Replies: 2
    Last Post: 12-04-2007, 05:13 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •