November 4, 201312 yr Hello again I have decided to start making my own private scripts. Still extremely new, so I am using open source scripts to kind of tinker with, to try and get a feel for. I am stuck with a problem to which most developers could fix in 1 second: Time until level... I currently have this: int xpGained = this.client.getSkills().getExperience(Skill.AGILITY) - this.startXp; int xpPerHour = (int)(xpGained * 3600000.0D / (System.currentTimeMillis() - this.startTime)); g.drawString("Runtime: "+hours+":"+minutes+":"+seconds, 381, 280); g.drawString("Xp Gained: " + xpGained, 381, 295); g.drawString("Xp / Hour: " + xpPerHour, 381, 310); How would I add a time until level int? Mathematically I know it is exp/hour / exp needed. Can someone help me real quick with this? Thank you Edited November 4, 201312 yr by Sk00n
November 4, 201312 yr Author mathematically it is exp needed/ exp/hour Typed it backwards On topic, where could I find it in the API?
November 4, 201312 yr Author Not sure if it is in API. Looks like it is not. My problem is figuring out how to write the exp needed To make that, it is: Next level exp - current level exp. How do I write that correctly? :\