Jump to content

HyperChao

Members
  • Posts

    8
  • Joined

  • Last visited

Everything posted by HyperChao

  1. I guess this applies to any keyboard with extra nonstandard keys, but can AutoIt handle the 18 "G keys" that come on the G15?
  2. I've written a program very similar to this one, except mine also searches for files inside folders found in the original folder (and files in folders in those folders, etc ) until every single file contained in the specified folder is accounted for. If anyone is interested, I can post details. Perhaps SolidSnake can just implement it into his code, although two arrays are involved. I suppose the information can be condensed into one array, but then it gets messy... [EDIT] Okay, so condensing it into one array wasn't as messy as I thought... just complicated to explain. Here goes: $list[0][0] = number of folders and subfolders $list[0][x] = x-th folder (a folder's number has no significance as to its location) $list[x][0] = number of files in the folder $list[0][x] $list[x][$y] = y-th file in folder $list[0][x] The path stored in $list[0][x] is enough so that $dir & $list[0][x] will take you where you want. The code isn't documented well, but if anyone wants me to post it just ask.
  3. OK. Thanks a bunch both in this thread and your own. Guess my understanding of trees wasn't way off - glad you cleared up some terms for me.
  4. Since you don't use _ArraySort anymore, is v3.1.1 good enough? Also, it doesn't seem that the zip file attached in the first post is updated with your new functions... As for your algorithm, how does it handle adding new elements? Greater than, on the right, less than to the left, but what about when it's equal? Does it leave the tree unaltered? Or am I just totally confused? I'm not sure about this key and value business.
  5. Thanks blindwig - that's what I was looking for. I knew I could just use a normal array, but I'm working with thousands of entries. I had read somewhere that binary trees are faster for sorting. Now I just need to figure out how to implement it...
  6. Say I have a large text file with a relatively short string on each line. These strings may not be unique. How can I efficiently process the file to delete repeated entries?
  7. Why don't you use a WinWaitActive function with a timeout? If it does not appear, then you can assume the network's not working.
  8. [Edits below. If you don't want to read details, just read what's in bold below for my current problem.] I was wondering if anyone has had experience working with ZSNES. When I am using the cursor inside the window, AU3Info does not seem to give me the correct coordinates. However, it does seem to read the colors when a game is running, but I just don't know the location of the point being read. My first challenge is to find a way to identify important coordinates to read colors. I am considering making a background .bmp with lines every 10 pixels as a last resort. Any suggestions? For the people who are familiar with the game, I also am trying to figure out a good way to plot out the playing field. I am considering using a 6x14 matrix. There is no problem normally, as I can keep track of where my pieces are going, but when clear blobs come in, I will have problems. Is there a fast way to scan the playing field when this happens, or should I pinpoint a particular spot (or at least small square) that will allow me to identify what kind of block occupies that space? I may be able to find a spot that is unique to each blob. I am anxious to start trying to tackle the logistics of my strategy, but I find myself stuck trying to gather all the information I need. Please chime in if you are interested or if you would like to get some Netplay action. [Edit 1] I have attached a .bmp of the grid I am using just in case anyone can find a use for it. Just set as background and tile it. (I went through making a 1600x1200 grid before realizing the tile trick ) The blue lines are every 10 pixels and the red lines are every 100. I will try to go about getting coordinates using this method. Any more sophisticated methods are very welcome ! [Edit 2] No more problems detecting pixels from ZSNES. It got along fine with AU3Info as long as it was not the active program, so I just ran notepad on top and moved it away so that I could still see the game. I now have all coordinates and bitmaps of all possible pictures in each square in the playing field using a Screen Capture DLL I found in this forum here. What I need to know now is how I can find a coordinate that is the same color in 11 similar bitmaps. All 11 should be associated as the same thing. See the bitmaps in the attached blobs.zip to get an idea of what I'm talking about; every bmp in each folder should be grouped as that color. Also, can I make a pixel checksum from a bitmap? Speed is not an issue, as I only need to do this once and store the number (or is this not how it works?).
×
×
  • Create New...