Jump to content

Mastermosley

Members
  • Posts

    17
  • Joined

  • Last visited

Everything posted by Mastermosley

  1. Just recently got back into Runescape...once again, and my previous clan has disappeared off the map. I am looking for an active, organized, and well developed clan. Depending on my mood i might be into pking or skilling and what not so being in a clan that offers a multitude of activities would be a plus. I created my account way back in the day when Runescape first came out, when you were able to choose your own class and I have played off and on since. Having some old school members would be another plus haha. I can say in all of the previous clans I have been in in my runescape life I have never missed a well advertised event without reason, and never missed a war. Stats Combat - 96 Attack - 75 Defense - 75 Strength - 84 Constitution - 79 Pray - 51 Fishing - 70 Cooking - 70 Slayer - 72 Summoning - 1 Cheers
  2. This is complete bulls**t. The isp's are trying to meter the amount of bandwith we use and charge us a rate. This will change our internet sign the petition below. http://openmedia.ca/meter
  3. Those were the days...haha spend all day mining for coal certificates which were worth 15k a peice i think
  4. Ya same here......:( Just got it today
  5. Just curious, does anyone remeber when tip.it used to be a dark age of camelot tip site as well? (Back when a party hat was 300k)
  6. Nice nice, thought you meant you lost 40mill haha,
  7. Awesome, thanks for giving me something to do anyway.
  8. Ya my program kicks off at 21450 users ill just wait a while and restart from there.
  9. couldnt you continue from when you left off? Give 10 minutes then restart but at the point you left off?
  10. its not actually grabbing the highscores yet just grabbing each user. from this http://services.runescape.com/m=hiscore/overall.ws?rank=1&table=0&scroll=true&category_type=0 every 22 usernames that are processed a global variable which starts at 1 goes up by 22 and the link changes respectively: "http://services.runescape.com/m=hiscore/overall.ws?rank=" + globalvariable + "&table=0&scroll=true&category_type=0" which downloads the next source. About the banning, I dont no I haven't been yet anyway. What I am going to do is download each username into an xml database a new one every 100k which will end me up with 20 of these 100k databases. Then my new program will be multithreaded (20 threads) which will grab the highscores similtaniously hopefully making this faster. I made a mistake when I said it will double when I access the highscores it will probobly slow down by *22 times :( and the final database should be around 3gigs
  11. Okay I am just grabbing the users and adding them to a database at this point, but basically with my code which is below I can process 1000 users a minute meaning its going to take 33 hours to get all of the users :P And it will probobly double when I have to grab each members stats, Im stoked to test this out. Runs on a seperate thread gives me the total amount of usernames processed and the time elapsed. using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; using System.Threading; namespace RSGrab { public partial class Form1 : Form { int CurrentPageList = 1; int usernamec = 0; System.Diagnostics.Stopwatch wat = new System.Diagnostics.Stopwatch(); public delegate void UpdateForm(string text); public Form1() { InitializeComponent(); } private void kryptonButton1_Click(object sender, EventArgs e) { wat.Start(); timer1.Start(); Thread ms = new Thread(MainStuff); ms.Start(); } private void MainStuff() { DateTime eventtime1 = DateTime.Now; while (CurrentPageList < 1000000) { string aData = getPageSource(getCurrentUrl()); //Grab the source aData = StripTagsCharArray(aData); //Gets Rid of <html> tags aData.Trim(); //Trim all whitespaces beginning end end string[] bData = getActualData(aData); //Takes only the data needed //Now that I have the data I need I will parse it for each person int count = 0; int line = 1; while (count < 88) { string name = ""; //Account Name - Only grabbing the Username because I will grab the //entire highscores for each member. if (line == 1) { count++; line++; } if (line == 2) { name = bData[count]; count++; line++; } if (line == 3) { count++; line++; } if (line == 4) { ListBox1.Invoke(new UpdateForm(this.AddUserNameXml), new object[] { name }); count++; line = 1; } } CurrentPageList = CurrentPageList + 22; } DateTime eventtime2 = DateTime.Now; TimeSpan elapsed = eventtime1 - eventtime2; MessageBox.Show(elapsed.ToString()); } private void AddUserNameXml(string username) { usernamec++; label2.Text = usernamec.ToString(); } private string[] getActualData(string data) { string[] aData = data.Split('\r', '\n'); string bData = ""; int count = 0; while (count < aData.Length) { if (aData[count].Trim() != "") { bData += aData[count].ToString() + "%"; } count++; } bData.Trim(); string[] cData = bData.Split('%'); int newcount = 122; int newcount2 = 0; string[] final = new string[89]; while (newcount <= 209) { final[newcount2] = cData[newcount]; newcount++; newcount2++; } return final; } private string getCurrentUrl() { string url = "http://services.runescape.com/m=hiscore/overall.ws?rank=" + CurrentPageList.ToString() + "&table=0&scroll=true&category_type=0"; return url; } private string getPageSource(string url) { System.Net.WebClient wb = new System.Net.WebClient(); string strSource = wb.DownloadString(url); wb.Dispose(); return strSource; } private static string StripTagsCharArray(string source) { char[] array = new char[source.Length]; int arrayIndex = 0; bool inside = false; for (int i = 0; i < source.Length; i++) { char let = source[i]; if (let == '<') { inside = true; continue; } if (let == '>') { inside = false; continue; } if (!inside) { array[arrayIndex] = let; arrayIndex++; } } return new string(array, 0, arrayIndex); } private void timer1_Tick(object sender, EventArgs e) { label4.Text = Math.Round((decimal)wat.Elapsed.TotalMinutes, 2).ToString(); } } }
  12. Thats pretty cool. I am no good perl or php, how are you getting the next user to grab the stats from. I'm going to try this out in C# :P
  13. If speed is what you want ASP.NET MVC is far superior the php. (A compiled language is proven faster than a interpretted language) Not so if you are using ASP .NET Webforms though all that extra jazz really slows it down.
  14. Not to mention Microsoft IDE, makes developing C# applications a breeze. Also you can download a MONO Tools for visual studio so you can debug it if it were running on mono.
  15. This is what I used for the highscores lookup might help with your api. Taken from RS Regent Toolkit http://www.rsregent.net WebClient stats = new WebClient(); Stream statstream = stats.OpenRead("http://hiscore.runescape.com/index_lite.ws?player=" + RSN); StreamReader statread = new StreamReader(statstream); string sockread = null, sockline = null; int aa = 0; while ((sockread = statread.ReadLine()) != null) { string[] bb = sockread.Split(new string[] { "," }, StringSplitOptions.None); if (bb.Length == 3) { if (bb[0] != "-1") { int r = int.Parse(bb[0]), l = int.Parse(bb[1]), f = int.Parse(bb[2]); string rank = String.Format("{0:0,0}", r), level = String.Format("{0:0,0}", l), exp = String.Format("{0:0,0}", e); // sockline = SkillsArray[aa] + " " + "Rank: " + rank + " Level: " + level + " Exp: " + exp; aa++; Console.WriteLine(sockline); hst[aa].Text = rank; gst[aa].Text = level; aa++; } else { aa++; } } else { if (bb[0] != "-1") { int r = int.Parse(bb[0]), l = int.Parse(bb[1]); string rank = String.Format("{0:0,0}", r), level = String.Format("{0:0,0}", l); // sockline = SkillsArray[aa] + " " + "Rank: " + rank + " Score: " + level; aa++; Console.WriteLine(sockline); hst[aa].Text = rank; gst[aa].Text = level; aa++; } else { aa++; } } } statstream.Close(); } } I have labels for Rank and Level Referenced in order hst = highscorestext, gst = level. Grabs the highscores lite data and splits it into separate strings and goes from there. Any questions I can probobly help you out.
  16. If you want to learn a programming language that can be utilized on multiple platforms I would suggest C++ because it seems it will never go away and every platform supports it. There is tons of documentations and ebooks avaialble to teach you how and with you knowledge of php and javascript the syntax's are very similiar. Microsoft Visual Studio is by far the best IDE to work with in my opinion. C++ is very complex and will require modivations. Now my personal favorite C# is an awesome language if you want to program for Windows. (Also MONO is available which allows you to run C# programs on other platforms). Its similiar to c++ but much easier to understand. C# is a very powerfull language and you can do just about anything in it as well. Visual Studio Website
  17. I agree it should be legalized. Although it may or may not help the economy depending on where you live. I live in British Columbia, Canada, we produce some of the worlds best pot, legalizing it here would be a major boost to our economy because the government would tax that [cabbage] out of it bringing more tax dollars to us, and maby lowering taxes on other things.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.