A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: Flash import and split text!

  1. #1
    Junior Member
    Join Date
    May 2004
    Posts
    10

    Question Flash import and split text!

    Hi !

    I building a replayer poker hands tool. When you play poker, at fulltilt, for example, the history is saved in a text file (See below).

    I will build a visual tool to replay the hand. I guess the first step is to split the file, and put the values into variables. I tried this with the split method, but couldn't figure it out

    Need help please!




    Full Tilt Poker Game #8208927107: Table Howie (heads up) - $0.25/$0.50 - No Limit Hold'em - 16:05:45 ET - 2008/09/24
    Seat 1: wosh ($23)
    Seat 2: d3rv0gel ($20.25)
    d3rv0gel posts the small blind of $0.25
    wosh posts the big blind of $0.50
    The button is in seat #2
    *** HOLE CARDS ***
    Dealt to wosh [3h 2h]
    d3rv0gel raises to $1.50
    wosh adds $0.50
    wosh folds
    Uncalled bet of $1 returned to d3rv0gel
    d3rv0gel mucks
    d3rv0gel wins the pot ($1)
    *** SUMMARY ***
    Total pot $1 | Rake $0
    Seat 1: wosh (big blind) folded before the Flop
    Seat 2: d3rv0gel (small blind) collected ($1), mucked



    Full Tilt Poker Game #8208928820: Table Howie (heads up) - $0.25/$0.50 - No Limit Hold'em - 16:05:53 ET - 2008/09/24
    Seat 1: wosh ($23)
    Seat 2: d3rv0gel ($20.75)
    wosh posts the small blind of $0.25
    d3rv0gel posts the big blind of $0.50
    The button is in seat #1
    *** HOLE CARDS ***
    Dealt to wosh [Qs 6s]
    wosh raises to $1.50
    d3rv0gel folds
    Uncalled bet of $1 returned to Wing666
    wosh mucks
    wosh wins the pot ($1)
    *** SUMMARY ***
    Total pot $1 | Rake $0
    Seat 1: wosh (small blind) collected ($1), mucked
    Seat 2: d3rv0gel (big blind) folded before the Flop

  2. #2
    Senior Member jweeks123's Avatar
    Join Date
    Mar 2006
    Posts
    1,124
    Could you provide more information?

    With what you've listed here I can only say this. I've done this a lot with PHP and other things like that and have to split imported name value pairs as well as name value strings, and then split the string with a character in the PHP.

    the same principal applies here, I'd seperate each line with something out of the ordinary, like &=. Then split the imported string based on that character.

  3. #3
    Flactionscrish Baby Minion's Avatar
    Join Date
    Nov 2005
    Location
    Planet Earth
    Posts
    312
    Sounds like you need a class, which can interpret the file.
    There is an obvious format to how the log file is laid out. You should take a lot of these files, and get a greater understanding of the information in them

    Make a class, that can take the text in a log file, and convert it into an array, which acts as each sequence of actions performed.

    Best bet, is to use Regular Expressions to sift through the text, but you could also use a sequential check system, and go through it.

    After you have the array, you can use a sequencer to just recreate the actions that occurred.

    I can't help much more than that but my give you a place to start.
    ktu[k-two]
    he who hesitates is lost; so i guess i'll wander intently

    Are you sure this is real?
    Life is Love, Love is Blind, Blind we go through Life.
    Life isn't hard, dealing with your self is.

    The concept of life in a human brain is weakening day after day. Live every day like its your last. Take the chances, and opportunities, and never let authority push you around for fun.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center