ArcEmu: Anyone Have A Parser? - ArcEmu

Jump to content

Toggle shoutbox Lastest Announcements

dfighter  : (07 December 2014 - 12:06 PM) Arcemu is in hibernation mode, please read http://arcemu.org/fo...showtopic=26903
dfighter  : (01 January 2013 - 05:56 PM) Arcemu wishes you all a happy new year!
Hasbro  : (12 September 2012 - 10:01 AM) Please excuse our outage from the web! Our web host had a major malfunction!
dfighter  : (01 September 2012 - 04:05 PM) Since the spam bots just don't want to stop, I've enabled admin verification when registering.
dfighter  : (23 January 2012 - 09:56 PM) Please note that from now on you will need to confirm your email on the wiki in order to edit it!
Hasbro  : (31 December 2011 - 12:50 PM) Happy New Years all!
Navid  : (26 December 2011 - 04:09 AM) Merry Christmas !!!!!! Happy holidays all :)
WAmadeus  : (24 December 2011 - 03:54 PM) Merry Christmas to all!
dfighter  : (24 December 2011 - 11:05 AM) The Arcemu team wishes y'all a Merry Christmukkah!
Hasbro  : (05 October 2011 - 12:53 PM) Looking for web designers for upcoming web related project. If you're interested in designing user interfaces contact me
dfighter  : (02 September 2011 - 03:47 PM) So who here wants vehicles in Arcemu? :P http://arcemu.org/fo...showtopic=25440
Hasbro  : (14 August 2011 - 03:25 PM) Join us on irc, grab an irc client and connect to irc.freenode.net join channel #arcemu /server irc.freenode.net:6667 /join #arcemu
jackpoz  : (03 August 2011 - 05:33 AM) to all Lua Engine (old one) users: please check http://arcemu.org/fo...showtopic=25274
Hasbro  : (20 May 2011 - 05:27 PM) Looking for people experienced with CMake configuration and setup! Contact me asap
Hasbro  : (15 May 2011 - 05:03 PM) ArcEmu is recruiting C++ programmers, contact Hasbro if interested.
paroxysm  : (03 May 2011 - 06:26 PM) Updated luabridge gossip example to describe the whole gossip creation process rather than just how to create menu. Gossip tutorial
paroxysm  : (23 April 2011 - 11:35 AM) Lua writers can refer to the Luabridge Tutorials section in the Wiki to learn how to write gossip code correctly.
Hasbro  : (20 April 2011 - 05:22 PM) Thank you for your continuous contribution of bug reports, we are working on them.
Hasbro  : (17 April 2011 - 03:20 AM) Please consider donating to support our bills. Donations can be sent using PayPal to donations@arcemu.org - Thank you for your support.
paroxysm  : (10 April 2011 - 12:43 AM) Refer to the Luabridge Tutorials section in the Wiki to learn the new syntax of luabridge.
Resize Shouts Area

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Anyone Have A Parser?

#1 User is offline   Ogchaos 

  • Interested
  • PipPipPipPip
  • Group: Members
  • Posts: 404
  • Joined: 30-September 09

Posted 01 January 2010 - 01:23 PM

Hey everyone,

I need a parser that can,

Get "creature spawns" and "new creatures" "claudenegm" from why-db also wants this kind of tool, http://www.whydb.org...php?f=11&t=3197

Thanks in advance
0

#2 User is offline   dfighter 

  • Titles are overrated
  • PipPipPipPipPipPipPipPipPipPip
  • Group: Administrator
  • Posts: 5,189
  • Joined: 14-June 08
  • IRC:dfighter
  • Gender:Male
  • Server OS:Linux

Posted 08 January 2010 - 10:13 AM

View PostOgchaos, on 01 January 2010 - 01:23 PM, said:

Hey everyone,

I need a parser that can,

Get "creature spawns" and "new creatures" "claudenegm" from why-db also wants this kind of tool, http://www.whydb.org...php?f=11&t=3197

Thanks in advance

There are tools like this, but they are mostly private. Just ask yourself the question why would anyone want to share them?
The other question you need to ask is that shouldn't he be able to make such tools, after all he is a developer isn't he?
"The demand for free goods is infinite."
0

#3 User is offline   FleX 

  • Member
  • Pip
  • Group: Members
  • Posts: 85
  • Joined: 12-July 08
  • Gender:Male
  • Location:Denmark

Posted 09 January 2010 - 08:38 AM

View PostOgchaos, on 01 January 2010 - 01:23 PM, said:

Hey everyone,

I need a parser that can,

Get "creature spawns" and "new creatures" "claudenegm" from why-db also wants this kind of tool, http://www.whydb.org...php?f=11&t=3197

Thanks in advance


Get them from where if i may ask?
WoW Database Websites like WowHead, Allakhazam, WowDB etc.
Or WoW Cache Files?
Or somewhere else?

I once coded a tool to parse data from WowHead's hidden XML files, but i've lost the program now as i've been away from the WoW Emulation Communities for several months.


0

#4 User is offline   Ogchaos 

  • Interested
  • PipPipPipPip
  • Group: Members
  • Posts: 404
  • Joined: 30-September 09

Posted 09 January 2010 - 10:38 AM

View PostFleX, on 09 January 2010 - 08:38 AM, said:

Get them from where if i may ask?


WowHead or Allakhazam would be great.
0

#5 User is offline   dfighter 

  • Titles are overrated
  • PipPipPipPipPipPipPipPipPipPip
  • Group: Administrator
  • Posts: 5,189
  • Joined: 14-June 08
  • IRC:dfighter
  • Gender:Male
  • Server OS:Linux

Posted 09 January 2010 - 04:41 PM

View PostOgchaos, on 09 January 2010 - 10:38 AM, said:

WowHead or Allakhazam would be great.

That kinda sucks, since you don't get most of the important informations from there, like bytes and flags.
"The demand for free goods is infinite."
0

#6 User is offline   Ogchaos 

  • Interested
  • PipPipPipPip
  • Group: Members
  • Posts: 404
  • Joined: 30-September 09

Posted 09 January 2010 - 05:53 PM

View Postdfighter, on 09 January 2010 - 04:41 PM, said:

That kinda sucks, since you don't get most of the important informations from there, like bytes and flags.


Hmm, what would be your recommendation?
0

#7 User is offline   this_is_junk 

  • Retired Retard
  • Group: Contributor
  • Posts: 2,432
  • Joined: 08-October 08
  • Gender:Male
  • Location:Washington State

Posted 09 January 2010 - 05:59 PM

Packet Logging.

Posted Image
GAH!!! >_< ...can't...just...stop...working...
0

#8 User is offline   technique 

  • Occasional Poster
  • PipPip
  • Group: Members
  • Posts: 145
  • Joined: 19-June 08
  • Gender:Male
  • Location:Underground
  • Interests:Emulation?
  • Server OS:Other

Posted 09 January 2010 - 07:06 PM

View PostOgchaos, on 09 January 2010 - 05:53 PM, said:

Hmm, what would be your recommendation?

Whine on Dfighter or Walla or tudi until they give up and share the MAGIC TOOLS OF DOOM.

It works :E
ŧechnique,
the one and only
0

#9 User is offline   Ogchaos 

  • Interested
  • PipPipPipPip
  • Group: Members
  • Posts: 404
  • Joined: 30-September 09

Posted 09 January 2010 - 08:24 PM

View Posttechnique, on 09 January 2010 - 07:06 PM, said:

Whine on Dfighter or Walla or tudi until they give up and share the MAGIC TOOLS OF DOOM.

It works :E


lol, well if Dfighter would be kind enough to share, it would be much appreciated :)
0

#10 User is offline   dfighter 

  • Titles are overrated
  • PipPipPipPipPipPipPipPipPipPip
  • Group: Administrator
  • Posts: 5,189
  • Joined: 14-June 08
  • IRC:dfighter
  • Gender:Male
  • Server OS:Linux

Posted 09 January 2010 - 10:39 PM

View PostOgchaos, on 09 January 2010 - 08:24 PM, said:

lol, well if Dfighter would be kind enough to share, it would be much appreciated :)

I believe I share enough, so not going to happen.
"The demand for free goods is infinite."
0

#11 User is offline   iEzri 

  • < Ace of spades >
  • Group: Contributor
  • Posts: 1,692
  • Joined: 22-December 08
  • Gender:Female
  • Interests:I'm likely to cause mischief
  • Server OS:Linux

Posted 26 February 2010 - 06:35 AM

Well, then how about doing it yourself?

i.e.

$page = implode("", file($loc)); 


or sth like that. I know it wont get all of it, but hey, at least youll get something ^^
Posted Image I do not join. I lead.
0

#12 User is offline   Doggie52 

  • arcemu feedback police
  • PipPipPip
  • Group: Members
  • Posts: 297
  • Joined: 09-October 08
  • Gender:Male
  • Location:Sweden
  • Interests:web designing, web programming, wow databases, game- and webservers
  • Server OS:Windows

Posted 21 March 2010 - 02:52 AM

I love how WoWHead's XML interface is labelled as "hidden". It's simply adding &xml to the end of whatever page you're viewing and it's mentioned on the forums a couple of times.
0

#13 User is offline   Lawrence83 

  • Newbie
  • Group: Members
  • Posts: 4
  • Joined: 21-December 11
  • Gender:Male
  • Location:USA
  • Server OS:Windows

Posted 02 January 2012 - 10:51 PM

as the subject of this discussion is parser so here i am sharing with you something. Typically when I need to extract data from a PDF, I just convert it to text and apply some regex fu on the text. This approach is not effective for my current project due to the page layout. I was hoping to use the traverse() method to create a node walker akin to HTML::TokeParser.
Consume a node
Determine node type
Determine current state of parse
Dispatch a handler for the node based on type and current state
I have done a fair amount of searching and came across two hints of a solution at Stack Overflow by the author of CAM::PDF. I have also emailed the author though I imagine he is quite busy actually having a life.

Obviously, I am not looking for someone to write the parser for me but does anyone have a more generic (non-specific) example of using traverse()? Below is an example of how I create a parser using HTML::TokeParser

# Step 1: Dump the entire document
while (my $tok = $p->get_token) {
print Dumper($tok);
}
[download]
I then edit the dumped document searching for the piece of information I want to extract. Perhaps it is identified by a certain id or name tag. Then, I can start to construct my parser:

use constant TYPE => 0;
use constant TEXT => 1;
use constant TAG => 2;
use constant ATTR => 3;
while (my $tok = $p->get_token) {
next if $tok->[TYPE] ne 'S' || $tok->[TAG] ne 'b' || ! $tok->[ATTR
+]{class};
next if $tok->[ATTR]{class} ne 'secret';
my $next = $p->get_token;
$wanted{password} = trim($next->[TEXT]);
last;
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users