|
Post by jussjames on Mar 13, 2006 23:35:58 GMT -8
This may sound odd, and I know most people aren't up for a RPG challenge neccisarily. But I have this idea, just wonder if it will work. Is there a way to modify RPG Me to store a single variable (not Money, all that stuff, I personally need one variable; Rank Label) in a specific post on a hidden board? Maybe beable to make a "username####" format, then query that instead of querying from the Personal Text Box? I think it might be a challenge. But perhaps worth it? I'm just a bit too far out of my league in this to do it myself, and anyways, it's not my code to modify. Please email me at jussjames@hotmail.com if there is a solution for this.) The code is below. <script type='text/javascript'> /* RPG Me V1.0 Created by cRAzY_J (http://hatakeforum.proboards30.com) do no redistribute this code without the creator's permission this header must not be removed*/
var redbull=document.body.getElementsByTagName("td"); var coffee=document.body.getElementsByTagName("table"); function cocacola(){ for(t=0;t<redbull.length;t++){ if(redbull[t].colSpan=="2" && redbull[t].innerHTML.match(/Member's\sBio/)){ redbull[t].getElementsByTagName("a")[0].href.match(/&user=(.+?)$/) redbull[t].getElementsByTagName("b")[0].innerHTML+= " - <a href='/index.cgi?action=modifyprofile&user="+RegExp.$1+"&rpgstats'>RPG Stats</a>"; } } } function mtdew(){ for(mock=4;mock<coffee.length;mock++) coffee[mock].style.display="none"; var gatorade=document.modifyForm.posts.value; var a,b,c,d; if(!document.modifyForm.personaltext.value.match(/gpr%%(\d+)%%(\d+)%%(\d+)%%(\d+)%%/)){ a = Math.floor(gatorade*2.5);b = Math.floor(gatorade*3.5);c = Math.floor(gatorade*1.75);d = Math.floor(gatorade*1.25); }else{ a=RegExp.$1;b=RegExp.$2;c=RegExp.$3;d=RegExp.$4; } var pepsi= "<table width='92%' class='bordercolor' border='0' cellPadding='0' align='center'>" pepsi+= "<tr><td><table width='100%' cellPadding='4' cellSpacing='1'><tr><td class='titlebg'>" pepsi+= "<font size='2' class='cattext'>RPG Profile</font></td></tr></table>" pepsi+= "<table width='100%' cellPadding='4' cellSpacing='1'><tr>" pepsi+= "<td class='windowbg' width='50%'>Money:</td><td width='50%' class='windowbg'>" pepsi+= "<input id='money' value='"+a+"'></td></tr>" pepsi+= "<tr><td class='windowbg' width='50%'>Health Points:</td><td width='50%' class='windowbg'>" pepsi+= "<input id='hp' value='"+b+"'></td></tr>" pepsi+= "<tr><td class='windowbg' width='50%'>Magic Points:</td><td width='50%' class='windowbg'>" pepsi+= "<input id='mp' value='"+c+"'></td></tr>" pepsi+= "<tr><td class='windowbg' width='50%'>Stamina Points:</td><td width='50%' class='windowbg'>" pepsi+= "<input id='sp' value='"+d+"'></td></tr></table>" pepsi+= "<table width='100%' cellPadding='4' cellSpacing='1'><tr><td class='titlebg' align='center'>" pepsi+= "<input type='button' value='Submit Changes' onClick='sprite();'></td></tr></table></td></tr></table>" document.write(pepsi); }
function sprite(){ var one = document.getElementById("money").value; var two = document.getElementById("hp").value; var three = document.getElementById("mp").value; var four = document.getElementById("sp").value; document.modifyForm.personaltext.value = "gpr%%"+one+"%%"+two+"%%"+three+"%%"+four+"%%"; document.modifyForm.submit(true); }
function fanta(){ for(can=0;can<redbull.length;can++){ if(redbull[can].innerHTML.match(/Personal\sText:/) && redbull[can].width=="160") redbull[can].parentNode.style.display = "none"; } }
function orangejuice(){ for(glass=0;glass<redbull.length;glass++){ if( redbull[glass].width=="20%" && redbull[glass].innerHTML.match(/Posts:\s(\d+)/)){ if(redbull[glass].innerHTML.match(/gpr%%(\d+)%%(\d+)%%(\d+)%%(\d+)%%/)){ redbull[glass].innerHTML+= "<br />Money: "+RegExp.$1+"<br />Health Points: "+RegExp.$2+"<br />Magic Points: "+RegExp.$3+"<br />Stamina: "+RegExp.$4; redbull[glass].innerHTML = redbull[glass].innerHTML.replace(/gpr%%(\d+)%%(\d+)%%(\d+)%%(\d+)%%/,""); }else{ var beer=redbull[glass].innerHTML.match(/Posts:\s(\d+)/)? RegExp.$1:false; redbull[glass].innerHTML+= "<br /> Money: "+Math.floor(beer*2.5)+"<br /> Health Points: "+Math.floor(beer*3.5)+"<br /> Magic Points: "+Math.floor(beer*1.75)+"<br /> Stamina: "+Math.floor(beer*1.25); } } } }
if(location.href.match(/modifyprofile/)) fanta(); if(location.href.match(/(view(profile)?|display)/)) orangejuice(); if(redbull[5].innerHTML.match(/admin/)){ cocacola(); if(location.href.match(/&rpgstats/)) mtdew(); } </script>
Last Edit: Mar 13, 2006 23:37:10 GMT -8 by jussjames
|
|