Welcome to the RuneGlory Wiki, where we do our best to make your life easier!
You can use the search menu on the right side of the wiki (or at the bottom if you are on mobile) to search for the page you are looking for. The most popular pages can be found on the right side of the wiki aswell (or again at the bottom if you are on mobile).
Difference between revisions of "Dannyx Test2"
From RuneGlory
Line 1: | Line 1: | ||
+ | <html> | ||
− | |||
<head> | <head> | ||
− | <style> | + | <style> |
− | table, th, td { | + | table, |
− | + | th, | |
− | } | + | td { |
+ | border: 1px solid black; | ||
+ | } | ||
− | select { | + | select { |
− | + | color: white; | |
− | + | width: 100%; | |
− | } | + | } |
+ | </style> | ||
+ | </head> | ||
− | |||
− | |||
<body> | <body> | ||
− | <h2 style="color:white"> | + | <h2 style="color:white"> |
− | Prayer Table: | + | Prayer Table: |
− | </h2> | + | </h2> |
+ | |||
+ | <table width="100%"> | ||
+ | |||
+ | </td> | ||
+ | <th>Your Prayer XP</td> | ||
+ | <td> <img id="prayer" src="https://i.imgur.com/Vq65Tdh.png"> | ||
+ | <input type="text" id="curxp" name="skill-xp" maxlength="9" onkeyup="func()" placeholder="Your XP"> | ||
+ | </td> | ||
+ | <tr> | ||
+ | <th>Target XP</td> | ||
+ | <td> <img id="prayer" src="https://i.imgur.com/Vq65Tdh.png"> | ||
+ | <input type="text" id="tarxp" name="skill-xp" maxlength="9" onkeyup="func()" value="13034431"> | ||
+ | </td> | ||
+ | |||
+ | <tr> | ||
+ | <th>Bonuses</td> | ||
+ | <td> | ||
+ | <div id="Reg Donator"> | ||
+ | <input type="checkbox" name="Reg Donator" id="reg-donor" onclick="myFunction()" /> Regular Donator<br /> | ||
+ | </div> | ||
+ | <div id="Super Donator"> | ||
+ | <input type="checkbox" name="Super Donator" id="super-donor" onclick="myFunction()" /> Super Donator<br /> | ||
+ | </div> | ||
+ | <div id="Extreme Donator"> | ||
+ | <input type="checkbox" name="extdonor" id="ext-donor" onclick="myFunction()" /> Extreme Donator<br /> | ||
+ | </div> | ||
+ | <div id="Prayerbrawlers"> | ||
+ | <input type="checkbox" name="Prayerbrawlers" id="prayer-brawlers" onclick="myFunction()" /> Prayer Brawlers<br /> | ||
+ | </div> | ||
+ | <div id="1-5 bonus days"> | ||
+ | <input type="checkbox" name="bonus days" id="bonus-days" onclick="myFunction()" /> 1st-5th Bonus Days<br /> | ||
+ | </div> | ||
+ | <div id="Advanced Knowledge Aura"> | ||
+ | <input type="checkbox" name="aura" id="ak-aura" onclick="myFunction()" /> Advanced Knowledge Aura<br /> | ||
+ | </div> | ||
+ | <div id="Advanced Knowledge Aura"> | ||
+ | <input type="checkbox" name="server event" id="event" onclick="myFunction()" /> 25% Skilling Hour<br /> | ||
+ | </div> | ||
+ | </div> | ||
+ | </td> | ||
+ | |||
+ | </div> | ||
+ | </div> | ||
+ | </table> | ||
+ | |||
+ | <script> | ||
+ | function func() { | ||
+ | |||
+ | if (document.getElementById("curxp").value > 200000000) { | ||
+ | //alert("reached max limit"); | ||
+ | document.getElementById("curxp").value = "Invalid Amount!"; | ||
+ | return; | ||
+ | } | ||
+ | |||
+ | |||
+ | } | ||
+ | |||
+ | function Get(urlencoded) { | ||
+ | var Httpreq = new XMLHttpRequest(); // a new request | ||
+ | Httpreq.open("GET", yourUrl, false); | ||
+ | Httpreq.send(null); | ||
+ | return Httpreq.responseText; | ||
+ | |||
+ | var json_obj = JSON.parse(Get(urlencoded)); | ||
+ | //console.log(json_obj.11); | ||
+ | } | ||
− | + | document.getElementById("curxp").oninput = function() { | |
+ | myFunction() | ||
+ | }; | ||
+ | document.getElementById("tarxp").oninput = function() { | ||
+ | myFunction() | ||
+ | }; | ||
+ | var ourgBoneXp = 80000; | ||
+ | var zogreBoneXp = 60000; | ||
+ | var frostdragonBoneXp = 7200; | ||
+ | var dagannothBoneXp = 5000; | ||
+ | var wyvernBoneXp = 4000; | ||
+ | var dragonBoneXp = 2880; | ||
+ | var babydragonBoneXp = 1200; | ||
+ | var bigBoneXp = 600; | ||
+ | var regularBoneXp = 200; | ||
− | + | // ***** Getting current XP & Target Xp ***** | |
− | + | function setup() { | |
− | + | ||
− | + | regularBoneXp = 200; | |
− | + | bigBoneXp = 600; | |
− | + | babydragonBoneXp = 1200; | |
− | + | dragonBoneXp = 2880; | |
− | + | wyvernBoneXp = 4000; | |
− | + | dagannothBoneXp = 5000; | |
− | + | frostdragonBoneXp = 7200; | |
− | + | zogreBoneXp = 60000; | |
− | + | ourgBoneXp = 80000; | |
− | + | ||
− | + | // ***** Fixed variables for XP ets ***** | |
− | + | ||
− | + | ||
− | + | if (document.getElementById("prayer-brawlers").checked) { | |
− | + | regularBoneXp *= 2; | |
− | + | ||
− | + | } | |
− | + | if (document.getElementById("prayer-brawlers").checked) { | |
− | + | bigBoneXp *= 2; | |
− | + | ||
− | + | } | |
− | + | if (document.getElementById("prayer-brawlers").checked) { | |
− | + | babydragonBoneXp *= 2; | |
− | + | ||
− | + | } | |
− | + | if (document.getElementById("prayer-brawlers").checked) { | |
− | + | dragonBoneXp *= 2; | |
− | + | ||
− | + | } | |
− | + | if (document.getElementById("prayer-brawlers").checked) { | |
− | + | wyvernBoneXp *= 2; | |
− | + | ||
− | + | } | |
+ | if (document.getElementById("prayer-brawlers").checked) { | ||
+ | dagannothBoneXp *= 2; | ||
+ | |||
+ | } | ||
+ | if (document.getElementById("prayer-brawlers").checked) { | ||
+ | frostdragonBoneXp *= 2; | ||
− | + | } | |
+ | if (document.getElementById("prayer-brawlers").checked) { | ||
+ | zogreBoneXp *= 2; | ||
− | + | } | |
− | + | if (document.getElementById("prayer-brawlers").checked) { | |
− | + | ourgBoneXp *= 2; | |
− | + | } | |
− | + | if (document.getElementById("ext-donor").checked) { | |
+ | regularBoneXp *= 2.1; | ||
+ | } | ||
+ | if (document.getElementById("ext-donor").checked) { | ||
+ | bigBoneXp *= 2.1; | ||
+ | } | ||
+ | if (document.getElementById("ext-donor").checked) { | ||
+ | babydragonBoneXp *= 2.1; | ||
+ | } | ||
+ | if (document.getElementById("ext-donor").checked) { | ||
+ | dragonBoneXp *= 2.1; | ||
+ | } | ||
+ | if (document.getElementById("ext-donor").checked) { | ||
+ | wyvernBoneXp *= 2.1; | ||
+ | } | ||
+ | if (document.getElementById("ext-donor").checked) { | ||
+ | dagannothBoneXp *= 2.1; | ||
+ | } | ||
+ | if (document.getElementById("ext-donor").checked) { | ||
+ | frostdragonBoneXp *= 2.1; | ||
+ | } | ||
+ | if (document.getElementById("ext-donor").checked) { | ||
+ | zogreBoneXp *= 2.1; | ||
} | } | ||
− | + | if (document.getElementById("ext-donor").checked) { | |
− | + | ourgBoneXp *= 2.1; | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
} | } | ||
+ | if (document.getElementById("super-donor").checked) { | ||
+ | regularBoneXp *= 2; | ||
+ | } | ||
+ | if (document.getElementById("super-donor").checked) { | ||
+ | bigBoneXp *= 2; | ||
+ | } | ||
+ | if (document.getElementById("super-donor").checked) { | ||
+ | babydragonBoneXp *= 2; | ||
+ | } | ||
+ | if (document.getElementById("super-donor").checked) { | ||
+ | dragonBoneXp *= 2; | ||
+ | } | ||
+ | if (document.getElementById("super-donor").checked) { | ||
+ | wyvernBoneXp *= 2; | ||
+ | } | ||
+ | if (document.getElementById("super-donor").checked) { | ||
+ | dagannothBoneXp *= 2; | ||
+ | } | ||
+ | if (document.getElementById("super-donor").checked) { | ||
+ | frostdragonBoneXp *= 2; | ||
+ | } | ||
+ | if (document.getElementById("super-donor").checked) { | ||
+ | zogreBoneXp *= 2; | ||
+ | } | ||
+ | if (document.getElementById("super-donor").checked) { | ||
+ | ourgBoneXp *= 2; | ||
+ | } | ||
+ | if (document.getElementById("reg-donor").checked) { | ||
+ | regularBoneXp *= 1.75; | ||
+ | } | ||
+ | if (document.getElementById("reg-donor").checked) { | ||
+ | bigBoneXp *= 1.75; | ||
+ | } | ||
+ | if (document.getElementById("reg-donor").checked) { | ||
+ | babydragonBoneXp *= 1.75; | ||
+ | } | ||
+ | if (document.getElementById("reg-donor").checked) { | ||
+ | dragonBoneXp *= 1.75; | ||
+ | } | ||
+ | if (document.getElementById("reg-donor").checked) { | ||
+ | wyvernBoneXp *= 1.75; | ||
+ | } | ||
+ | if (document.getElementById("reg-donor").checked) { | ||
+ | dagannothBoneXp *= 1.75; | ||
+ | } | ||
+ | if (document.getElementById("reg-donor").checked) { | ||
+ | frostdragonBoneXp *= 1.75; | ||
+ | } | ||
+ | if (document.getElementById("reg-donor").checked) { | ||
+ | zogreBoneXp *= 1.75; | ||
+ | } | ||
+ | if (document.getElementById("reg-donor").checked) { | ||
+ | ourgBoneXp *= 1.75; | ||
+ | } | ||
+ | if (document.getElementById("ak-aura").checked) { | ||
+ | regularBoneXp *= 1.30; | ||
+ | } | ||
+ | if (document.getElementById("ak-aura").checked) { | ||
+ | bigBoneXp *= 1.30; | ||
+ | } | ||
+ | if (document.getElementById("ak-aura").checked) { | ||
+ | babydragonBoneXp *= 1.30; | ||
+ | } | ||
+ | if (document.getElementById("ak-aura").checked) { | ||
+ | dragonBoneXp *= 1.30; | ||
+ | } | ||
+ | if (document.getElementById("ak-aura").checked) { | ||
+ | wyvernBoneXp *= 1.30; | ||
+ | } | ||
+ | if (document.getElementById("ak-aura").checked) { | ||
+ | dagannothBoneXp *= 1.30; | ||
+ | } | ||
+ | if (document.getElementById("ak-aura").checked) { | ||
+ | frostdragonBoneXp *= 1.30; | ||
+ | } | ||
+ | if (document.getElementById("ak-aura").checked) { | ||
+ | zogreBoneXp *= 1.30; | ||
+ | } | ||
+ | if (document.getElementById("ak-aura").checked) { | ||
+ | ourgBoneXp *= 1.3; | ||
+ | } | ||
+ | if (document.getElementById("event").checked) { | ||
+ | regularBoneXp *= 1.25; | ||
+ | } | ||
+ | if (document.getElementById("event").checked) { | ||
+ | bigBoneXp *= 1.25; | ||
+ | } | ||
+ | if (document.getElementById("event").checked) { | ||
+ | babydragonBoneXp *= 1.25; | ||
+ | } | ||
+ | if (document.getElementById("event").checked) { | ||
+ | dragonBoneXp *= 1.25; | ||
+ | } | ||
+ | if (document.getElementById("event").checked) { | ||
+ | wyvernBoneXp *= 1.25; | ||
+ | } | ||
+ | if (document.getElementById("event").checked) { | ||
+ | dagannothBoneXp *= 1.25; | ||
+ | } | ||
+ | if (document.getElementById("event").checked) { | ||
+ | frostdragonBoneXp *= 1.25; | ||
+ | } | ||
+ | if (document.getElementById("event").checked) { | ||
+ | zogreBoneXp *= 1.25; | ||
+ | } | ||
+ | if (document.getElementById("event").checked) { | ||
+ | ourgBoneXp *= 1.25; | ||
+ | } | ||
+ | } | ||
− | // ***** | + | // ***** Start of function to calculate everything ***** |
− | + | function myFunction() { | |
− | + | setup(); | |
− | + | var x = document.getElementById("curxp").value; | |
− | + | var y = document.getElementById("tarxp").value; | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | + | if (x.length == 0) return; | |
− | |||
− | + | // ***** Calculate XP ***** | |
− | + | console.log(zogreBoneXp) | |
− | + | document.getElementById("zogrer").innerHTML = Math.ceil((y - x) / zogreBoneXp); | |
− | / | ||
− | + | document.getElementById("ourgr").innerHTML = Math.ceil((y - x)/ourgBoneXp); | |
− | |||
− | |||
− | |||
document.getElementById("frostr").innerHTML = Math.ceil((y - x)/frostdragonBoneXp); | document.getElementById("frostr").innerHTML = Math.ceil((y - x)/frostdragonBoneXp); | ||
Line 116: | Line 318: | ||
document.getElementById("regr").innerHTML = Math.ceil((y - x)/regularBoneXp); | document.getElementById("regr").innerHTML = Math.ceil((y - x)/regularBoneXp); | ||
− | // ***** Calculate XP required ***** | + | |
− | + | // ***** Calculate XP required ***** | |
+ | //document.getElementById("xpneeded").innerHTML = "" + (y - x); | ||
+ | |||
+ | |||
+ | } | ||
+ | </script> | ||
− | + | <table width="75%"> | |
− | + | <td> | |
− | <table width="75%"> | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
<img id="next" src="https://i.imgur.com/CxjVoDP.png"> Bones </td> | <img id="next" src="https://i.imgur.com/CxjVoDP.png"> Bones </td> | ||
<td id="regr"> </td> | <td id="regr"> </td> | ||
Line 164: | Line 364: | ||
<td id="frostr"> </td> | <td id="frostr"> </td> | ||
</tr> | </tr> | ||
− | + | <tr> | |
− | + | <td> | |
− | <img id="next" src="https://i.imgur.com/daQP1uy.png"> | + | <img id="next" src="https://i.imgur.com/daQP1uy.png"> Zogre Bones </td> |
− | + | <td id="zogrer"> </td> | |
− | + | </tr> | |
− | + | <td> | |
− | |||
<img id="next" src="https://i.imgur.com/HXjMCVh.png"> Ourg Bones </td> | <img id="next" src="https://i.imgur.com/HXjMCVh.png"> Ourg Bones </td> | ||
<td id="ourgr"> </td> | <td id="ourgr"> </td> | ||
</tr> | </tr> | ||
− | </table> | + | </table> |
</body> | </body> | ||
+ | |||
</html> | </html> |
Revision as of 19:13, 7 July 2018
Prayer Table:
Your Prayer XP | |
---|---|
Target XP | |
Bonuses |
Regular Donator
Super Donator
Extreme Donator
Prayer Brawlers
1st-5th Bonus Days
Advanced Knowledge Aura
25% Skilling Hour
|
Bones | |
Big Bones | |
Babydragon Bones | |
Dragon Bones | |
Wyvern Bones | |
Dagannoth Bones | |
Frost Dragon Bones | |
Zogre Bones | Ourg Bones |