Page 1 of 3 123 LastLast
Showing results 1 to 20 of 56

Thread: [Medium] [Teams] 12/06/06 - Competition - Rebuild Base Macro

  1. #1
    Arbiter Senior Member
    Retired Staff Member

    Blessed
    TheTempest's Avatar
    Join Date
    Apr 2004
    Posts
    2,086

    Default [Medium] [Teams] 12/06/06 - Competition - Rebuild Base Macro

    Hello,

    Hack (Idea from - gamepin126):
    Rebuild Base Macro.

    Quote Originally Posted by gamepin126
    Say you press a button at the beginning, build a base, and press the button again to stop recording. Then you do a button/command it'll rebuild the base exactly.
    Quote Originally Posted by gamepin126 View Post
    The way I thought it would work, would you could have a saved script, per build. So... /loadscript FastestUpperLeft and then you'd build a base, for the top left base. You could repeat for each base position.
    Inthis light, issue a command:
    /save <script name>. Then simply start saving the cmds. Then, have another command, /load <script name>, and finaly an /execute (or something along those lines).

    Extra Credit:
    N/a

    Time Limit:
    3 weeks.

    Additional Requirements:
    As usual, you must provide full documentation on how you came up with it. Tutorial format would be ideal.

    Good luck.
    TT

    My signature is back!! Hell YES!

    Click the link, I DEMAND YOU! :-D
    http://www.bwhacks.com/forums/showthread.php?t=24873

  2. #2
    Ereetu. Senior Member
    Developer

    High Priest
    Zephyrix's Avatar
    Join Date
    Oct 2005
    Location
    xor 1D27,1337
    Posts
    1,618

    Default

    Not that hard, press a hotkey, do a full command log on yourself (store it in a buffer), and when another hotkey is pressed, resend the commands. The most difficult part would be finding the time elapsed between each command issued, and also waiting that long, but that's about as hard as it gets. The problem with this though, is the required resources - minerals, gas, supply.

  3. #3
    rawr
    Evangelist
    White Tiger's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    1,073

    Default

    Be more useful if someone could make simply a recording macro that actually works T.T

    as in, i press F6 or something then 4sd5sd6sz7sz8sh then F6 again and then when you press F7 it will automatically do this. I've tried several like it(yes omg i wanted savior macro) but none worked. something like this ould be really fun to toy around with! =]

    LAWL IM A LEECHER!?
    i play music
    music is good...
    i don't need music
    but i want it

  4. #4
    Arbiter Senior Member
    Retired Staff Member

    Blessed
    TheTempest's Avatar
    Join Date
    Apr 2004
    Posts
    2,086

    Default

    Quote Originally Posted by xxzyzxx View Post
    Not that hard, press a hotkey, do a full command log on yourself (store it in a buffer), and when another hotkey is pressed, resend the commands. The most difficult part would be finding the time elapsed between each command issued, and also waiting that long, but that's about as hard as it gets. The problem with this though, is the required resources - minerals, gas, supply.
    Thus the medium difficulty , unless you believe it should be something else.

    Actually, it's a little more complicated than that. You have to also keep the UNITIDs that were in the selection buffer at the time the cmd's where issued, and then match the selection buffer to the unit that should get the cmd.

    To solve the time delay issue, simply store the current time in a congruent array. Then, when you go to re-issue the cmds, take the time differences, sleep that duration, then send cmd.

    Does this mean you are entering?

    My signature is back!! Hell YES!

    Click the link, I DEMAND YOU! :-D
    http://www.bwhacks.com/forums/showthread.php?t=24873

  5. #5
    Ereetu. Senior Member
    Developer

    High Priest
    Zephyrix's Avatar
    Join Date
    Oct 2005
    Location
    xor 1D27,1337
    Posts
    1,618

    Default

    Quote Originally Posted by TheTempest View Post
    Thus the medium difficulty , unless you believe it should be something else.

    Actually, it's a little more complicated than that. You have to also keep the UNITIDs that were in the selection buffer at the time the cmd's where issued, and then match the selection buffer to the unit that should get the cmd.

    To solve the time delay issue, simply store the current time in a congruent array. Then, when you go to re-issue the cmds, take the time differences, sleep that duration, then send cmd.

    Does this mean you are entering?
    No, I'm not entering. Also, the units that are in selection buffer doesn't have to be kept, except for the first command issued. I believe an 0x09 selunit command is already sent when you click on a unit, so you don't need to reselect it again.

  6. #6
    Maverick Renegade Senior Member

    Crusader
    Megaz's Avatar
    Join Date
    Oct 2005
    Posts
    3,673

    Default

    I'd love to learn to create hacks, I only simple java from school though.

  7. #7
    Arbiter Senior Member
    Retired Staff Member

    Blessed
    TheTempest's Avatar
    Join Date
    Apr 2004
    Posts
    2,086

    Default

    Quote Originally Posted by xxzyzxx View Post
    No, I'm not entering. Also, the units that are in selection buffer doesn't have to be kept, except for the first command issued. I believe an 0x09 selunit command is already sent when you click on a unit, so you don't need to reselect it again.
    Ah, I forgot about that, if your logging, your also logging the select commands. Good point.

    My signature is back!! Hell YES!

    Click the link, I DEMAND YOU! :-D
    http://www.bwhacks.com/forums/showthread.php?t=24873

  8. #8
    Ereetu. Senior Member
    Developer

    High Priest
    Zephyrix's Avatar
    Join Date
    Oct 2005
    Location
    xor 1D27,1337
    Posts
    1,618

    Default

    That is, except for the CURRENTLY selected units, because you already issued the select unit command, so you still have to craft a command for that, and send it first, then the recording.

  9. #9
    Senior Member
    Gold Member

    Deviant
    badman1's Avatar
    Join Date
    May 2004
    Posts
    53

    Default

    would be awesome if you could do this like right when you got in game and it would rebuild the base you had last game

    if money was no object

  10. #10
    Senior Member
    Retired Staff Member

    Celestial Entity
    gamepin126's Avatar
    Join Date
    Oct 2004
    Posts
    20,794

    Default

    Quote Originally Posted by badman1 View Post
    would be awesome if you could do this like right when you got in game and it would rebuild the base you had last game

    if money was no object
    If you start building as soon as you start the map, you'll have to take time to gather resources before building, if whoever makes this does it correctly, then minerals shouldn't be an issue.
    "A Responsible Citizen Not Only Shares Culture, But Destroys The Copyright Industries"

    "Elegance is not a dispensable luxury but a quality that decides between success and failure. "
    "It Don't Mean a Thing (If It Ain't Got That Swing)"
    “Absence of evidence is not evidence of absence.”

  11. #11
    Senior Member
    Gold Member

    Deviant
    badman1's Avatar
    Join Date
    May 2004
    Posts
    53

    Default

    im just saying, it would be great if one setup from a previous game worked well if you could like save it and use it again in another game if you started in the same place and had the money etc.

  12. #12
    Senior Member
    Retired Staff Member

    Celestial Entity
    gamepin126's Avatar
    Join Date
    Oct 2004
    Posts
    20,794

    Default

    Quote Originally Posted by badman1 View Post
    im just saying, it would be great if one setup from a previous game worked well if you could like save it and use it again in another game if you started in the same place and had the money etc.
    The way I thought it would work, would you could have a saved script, per build. So... /loadscript FastestUpperLeft and then you'd build a base, for the top left base. You could repeat for each base position.
    "A Responsible Citizen Not Only Shares Culture, But Destroys The Copyright Industries"

    "Elegance is not a dispensable luxury but a quality that decides between success and failure. "
    "It Don't Mean a Thing (If It Ain't Got That Swing)"
    “Absence of evidence is not evidence of absence.”

  13. #13

    Default

    Yes, I would expect this hack to be able to load whichever script you desired, given the map and position. Maybe more in-depth scripts could compensate for every position on a particular map. Going even further, maybe the script dll could have a few global "api-style variables" such as map, and position, that the script could use as a reference, in order to best choose the actions to take.

    I feel this hack wouldn't be extremely impossible, but would take a lot of work to perfect. This would be something interesting to see, and is almost borderline artificial inteligence scripting. Maybe in the future, provided many additions were made to this script hack, there could be one macro that would play entirely on its own and have a chance at winning.
    the rafm.org - old projects
    http://www.chyea.org/ - web based markup debugger

  14. #14
    Senior Member
    Gold Member

    Deviant
    badman1's Avatar
    Join Date
    May 2004
    Posts
    53

    Default

    Quote Originally Posted by gamepin126 View Post
    The way I thought it would work, would you could have a saved script, per build. So... /loadscript FastestUpperLeft and then you'd build a base, for the top left base. You could repeat for each base position.
    exactly, oh man thatd be awesome.

  15. #15
    Arbiter Senior Member
    Retired Staff Member

    Blessed
    TheTempest's Avatar
    Join Date
    Apr 2004
    Posts
    2,086

    Default

    Quote Originally Posted by gamepin126 View Post
    The way I thought it would work, would you could have a saved script, per build. So... /loadscript FastestUpperLeft and then you'd build a base, for the top left base. You could repeat for each base position.
    Very nice. Change reflected in competition.

    My signature is back!! Hell YES!

    Click the link, I DEMAND YOU! :-D
    http://www.bwhacks.com/forums/showthread.php?t=24873

  16. #16
    Senior Member

    Zealot
    OverFlow636's Avatar
    Join Date
    Apr 2004
    Location
    San marcos, Texas
    Posts
    874

    Default

    ima enter

    if anyone wants to join me in a team say so it will speed the hack up a bit

    [edit]
    my status on this hack is almost finished, i have the /record and /domacro done, just need to save to file and load from file
    the macros somewhat work, issueing the command is done and waiting before doing the next on the list is also finished

    all i have left is to parse my command buffer for the different selects and make sure a unit gets selected, like a drone that dosent exist anymore will have to have an idle one take its place which is proly the hardest part of this hack

    heres an example of how the human readable scripts will be for my plugin at least
    Code:
    Time:23CF1F62 Length:10 Data: 14 A5 08 E7 00 A1 0E E4 00 00 
    Time:23CFD44B Length:4 Data: 09 01 BB 0C 
    Time:23CFD9F8 Length:8 Data: 0C 19 44 00 0E 00 8F 00 
    Time:23D0C497 Length:8 Data: 0C 19 40 00 0F 00 83 00 
    Time:23D0C736 Length:4 Data: 09 01 BB 0C 
    Time:23D0CE7A Length:8 Data: 0C 19 45 00 0F 00 83 00 
    Time:23D0D158 Length:4 Data: 09 01 AE 0C 
    Time:23D0DC07 Length:8 Data: 0C 19 44 00 0D 00 8F 00 
    Time:23D27F76 Length:8 Data: 0C 19 3F 00 0D 00 8F 00 
    Time:23D281D7 Length:4 Data: 09 01 A6 0C 
    Time:23D2888E Length:8 Data: 0C 19 45 00 12 00 8F 00 
    Time:23D28CA5 Length:4 Data: 09 01 A8 0C 
    Time:23D28E6A Length:8 Data: 0C 19 4B 00 0E 00 8F 00 
    Time:23D329BF Length:8 Data: 0C 19 3D 00 0D 00 8F 00 
    Time:23D344AA Length:1 Data: 18 
    Time:23D3496D Length:10 Data: 14 95 09 9B 01 00 00 E4 00 00 
    Time:23D497F5 Length:4 Data: 09 01 BB 0C 
    Time:23D49A47 Length:8 Data: 09 03 8B 0C 87 0C 89 0C 
    Time:23D49CF7 Length:3 Data: 23 29 00 
    Time:23D4A013 Length:4 Data: 09 01 BC 0C 
    Time:23D4A2C3 Length:8 Data: 09 03 8C 0C 8A 0C 88 0C 
    Time:23D4A4B7 Length:3 Data: 23 29 00 
    Time:23D4AC97 Length:4 Data: 09 01 87 0C 
    Time:23D4B011 Length:1 Data: 19 
    Time:23D4B532 Length:4 Data: 09 01 89 0C 
    Time:23D4B8CC Length:1 Data: 19 
    Time:23D4BB9A Length:4 Data: 09 01 8B 0C 
    Time:23D4BE3A Length:1 Data: 19 
    Time:23D4C157 Length:4 Data: 09 01 8A 0C 
    Time:23D4C426 Length:1 Data: 19 
    Time:23D4C733 Length:4 Data: 09 01 88 0C 
    Time:23D4CACD Length:1 Data: 19 
    Time:23D5D8D2 Length:8 Data: 09 03 86 0C 89 14 8A 14 
    Time:23D5E371 Length:3 Data: 23 29 00
    i say human readable one because it will dump 2 files per script one like above and a 'compiled' version of it so that i dont have to parse text at all.

    im also gona see how much extra work it would be to make the scripts a lil easier to edit outside of sc but that could get pretty bad pretty fast
    Last edited by OverFlow636 : 12-13-2006 at 05:12 AM

  17. #17
    Senior Member
    Gold Member

    Deviant
    badman1's Avatar
    Join Date
    May 2004
    Posts
    53

    Default

    I keep checking this thread, I cant wait this is gonna be one of the funnest hacks.

  18. #18
    Senior Member

    Zealot
    OverFlow636's Avatar
    Join Date
    Apr 2004
    Location
    San marcos, Texas
    Posts
    874

    Default

    Quote Originally Posted by badman1 View Post
    I keep checking this thread, I cant wait this is gonna be one of the funnest hacks.
    yea almost done, currently it works for terran and tos if you know how to use but ill make it work for zerg soon and finish up the saving of scripts to file then its done

  19. #19
    Senior Member
    Gold Member

    Deviant
    badman1's Avatar
    Join Date
    May 2004
    Posts
    53

    Default

    Ill beta it :-)

    And I never use zerg so more good news :-)

    Lets do this. Cant freakin wait!

  20. #20
    =) Senior Member
    Developer

    Supreme Being
    K? Pŕo?ćtiόnŹ's Avatar
    Join Date
    Oct 2004
    Posts
    11,794

    Default

    I dont see how this is going to work if the conditions of the maps differ. Like say your in a game all by yourself and you record a macro and the select command will select the unit ids and blah blah blah. Now lets say you join a game with 5 people, those unit ids are going to change so youll be selecting someone elses units, or no units at all. The unit ids will change (Im pretty sure) and that will render it all just useless.
    Quote Originally Posted by Voice Of Korhal View Post
    Let us hope so, if that Reverse Engineering crap actually works, I'll be amazed.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. 1,000,000 Replies
    By Sinz in forum Forum Games
    Replies: 23377
    Last Post: 12-02-2019, 01:29 AM
  2. [Hard] [Teams] 12/06/06 - Competition - Set Formation
    By TheTempest in forum Challenges
    Replies: 30
    Last Post: 02-12-2007, 01:24 PM
  3. Replies: 9
    Last Post: 12-10-2006, 12:41 PM

Posting Rules

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