runescape-combat-formula-van-tipit
Gesponsorde koppelingen
PHP script bestanden
Code (php)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
<?php
# - ////////////////////
# by: CheiChei
# how to use: like: echo rscombat(ATTACK LVL, STRENGTH LVL, DEFENSE LVL, HIT POINTS LVL, MAGIC LVL, PRAY LVL, RANGE LVL);
# like: echo rscombat(82, 81, 81, 83, 76, 59, 77); < my stats now ^^
# comments: if you use this for your site please add a link to http://www.tip.it, they made the formula used in this script!!!
# - \\\\\\\\\\\\\\\\\\\\
function rscombat($att, $str, $def, $hp, $mag, $pray, $ran)
{
# tip.it's uitreken pagina
$ch = curl_init("http://www.tip.it/runescape/combat_calc.php");
# post instellen + post variables instellen
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, 'attack='.$att.'&strength='.$str.'&defense='.$def.'&hits='.$hp.'&magic='.$mag.'&prayer='.$pray.'&ranged='.$ran);
# dataterug krijgen
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
# output
$output = curl_exec($ch);
# filter je combat level eruit
$output = explode('<b>', $output);
$output = explode('</b>', $output[1]);
$output = $output[0];
# geef het weer
echo $output;
}
?>
# - ////////////////////
# by: CheiChei
# how to use: like: echo rscombat(ATTACK LVL, STRENGTH LVL, DEFENSE LVL, HIT POINTS LVL, MAGIC LVL, PRAY LVL, RANGE LVL);
# like: echo rscombat(82, 81, 81, 83, 76, 59, 77); < my stats now ^^
# comments: if you use this for your site please add a link to http://www.tip.it, they made the formula used in this script!!!
# - \\\\\\\\\\\\\\\\\\\\
function rscombat($att, $str, $def, $hp, $mag, $pray, $ran)
{
# tip.it's uitreken pagina
$ch = curl_init("http://www.tip.it/runescape/combat_calc.php");
# post instellen + post variables instellen
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, 'attack='.$att.'&strength='.$str.'&defense='.$def.'&hits='.$hp.'&magic='.$mag.'&prayer='.$pray.'&ranged='.$ran);
# dataterug krijgen
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
# output
$output = curl_exec($ch);
# filter je combat level eruit
$output = explode('<b>', $output);
$output = explode('</b>', $output[1]);
$output = $output[0];
# geef het weer
echo $output;
}
?>