Results 1 to 12 of 12
  1. #1
    berryh's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Location
    Netherlands
    Posts
    363
    Reputation
    10
    Thanks
    2,927

    Team Destroy Loader Tutorial | By berryh



    Hey Guys!

    I'm finally doing my tutorial on the loader that my team is using!
    I will give you a fairly standard loader lay-out, because it's quite easy to customize it.
    You can find really much source codes on the internet if you want to!
    I hope you know a little bit more about the coding language and my loader!

    Let's get started!

    Step 1
    The coding language that we will use is called: AutoIt!
    Download the .rar file in the attachments.
    Then open up AutoIt.exe and install that program.
    After that, install SciTE.exe!

    Step 2
    If you're running Windows Vista or 7 then do this: (For Windows XP or lower, go to Step 3!)
    Go to the Windows start menu and find "SciTE".
    Right-click on that one and click on "Properties".
    Go to the tab "Compatibility" and click on the checkbox "Run as Administrator". This one has to be checked!
    Then just click on "OK"

    Step 3
    Find a place where you want to create the loader. Right-click there with you're mouse.
    Click on "New", then on "AutoIt V3 Script".
    Give the file a name. (Like "Loader")
    Then right-click on the new created file and click on "Edit Script". (If you get a UAC pop-up, just click on "Yes")
    First, delete all the things that are in the file, so that you have a completely empty file!
    Then, find the hack .dll file you want to use! Copy that file to the same location as your script.
    Also create a background or download one from the internet. The size can be whatever you want, as long as it's an .jpg file!
    Last, find an icon file. I just choose the standard CrossFire icon. You can find this in your CrossFire Folder! Copy that one to your loader location to!
    Then you're good to go!

    Step 4
    Take a little bit of time and decide for wich type of CrossFire you're going to make the loader.
    Why is that quite important?
    I'll explain it:
    For CrossFire NA: First, the location of the CrossFire folder is different. Second, u have to use mlang.dll.
    For CrossFire Europe: Again, the location is different and u can use sxs.dll.
    Also: I have different names for the loaders, so you can easily tell for witch version of CrossFire it is, and wich version of the hack it is!
    If you have decided all these things, make sure you keep these things in mind, so you do it right in the coding part!

    Step 5
    The real coding work!

    First, let's make sure that the script will ALWAYS run as Administrator! Add this code to the beginning:
    Code:
    #RequireAdmin
    Then, let's get the files - that we have made ready for use - inside the script:
    Code:
    DirCreate(@AppDataDir & "/myLoaderCache") ;This creates the location to store the files we are going to use! It creates it in the appdata dir. As good as no-one will look there!:D
    FileSetAttrib(@AppDataDir & "/myLoaderCache","+H") ;This makes this folder hidden, so no-one is going to mess it up
    FileInstall("./sxs.dll",@AppDataDir & "\myLoaderCache\sxs.dll") ;This Copy's the hack dll(This one is for CrossFire Europe. mlang.dll is for CrossFire NA. If you want a CrossFire NA loader, change ALL the sxs.dll words to mlang.dll
    FileInstall("./background.jpg",@AppDataDir & "\myLoaderCache\background.jpg") ;This Copy's the Background image
    Sleep(1000) ;You have to wait with starting up the program, otherwise the background won't show up on the slower computers!
    After you have done that, let's create our CrossFire location selection form!
    Code:
    $loc1 = FileSelectFolder("Select Your CrossFire Europe Folder","",0,"C:\SG Interactive\Crossfire Europe") ;Selecting our CrossFire folder, and storing it into a variable so whe can use it later! Change the locations for use with CrossFire NA!
    If @error = 1 Then
    	error1() ;If he closes the box or click's on cancel, the loader will exit, and clean up the files. We will explain this function later.
    EndIf
    Now it's finally time to create our MAIN GUI! (Graphical User Interface):
    It work's this way:
    The GuiCreate statement work's like this: GuiCreate("Name",Width,Height{,Left,Top}) (Left and Top are not really needed! Without them, it will center in the middle!)
    The GuiCtrlCreate... statement work's like this: GuiCtrlCreate...("Name",Distance From Left,Distance From Right,Width,Height)
    Keep that in mind while you're coding!

    Code:
    GuiCreate("Our CrossFire Europe Hack V1 Loader",600,420) ;Create a GUI. Make this one exactly as big as your image PLUS 20 pixels for the menu!
    $pic1 = GUICtrlCreatePic(@AppDataDir & "\myLoaderCache\background.jpg",0,0,0,0); This creates the background image.
    GUICtrlSetState($pic1, $GUI_DISABLE) ;This turn's the image of, so it is in the background, and NOT over the controls!
    $button1 = GuiCtrlCreateButton("Activate",25,25,220,150) ;The activate button
    $button2 = GuiCtrlCreateButton("Deactivate",300,25,220,150) ;The deactivate button
    $button3 = Guictrlcreatebutton("Start CrossFire Europe",190,280,220,30) ;The button to start CrossFire Europe
    $menu1 = GUICtrlCreateMenu("File") ;This creates a menu called "File"
    $menu2 = GUICtrlCreateMenu("Help") ;This creates a menu called "Help"
    $menuoption1 = GUICtrlCreateMenuItem("Exit",$menu1) ;This creates the option "Exit" in the menu "File"
    $menuoption2 = GUICtrlCreateMenuItem("Help",$menu2) ;This creates the option "Help" in the menu "Help"
    DllCall("UxTheme.dll", "int", "SetWindowTheme", "hwnd", GUICtrlGetHandle($button1), "wstr", 0, "wstr", 0) ;This is to remove all the current lay-out of the buttons, so we can change it.
    DllCall("UxTheme.dll", "int", "SetWindowTheme", "hwnd", GUICtrlGetHandle($button2), "wstr", 0, "wstr", 0) ;Some of you might start thinking: "Why? It's possible witout!" Yes, but not on all systems!
    DllCall("UxTheme.dll", "int", "SetWindowTheme", "hwnd", GUICtrlGetHandle($button3), "wstr", 0, "wstr", 0) ;And the one for the last button!:)
    GUICtrlSetBkColor($button1, 0x333333) ;Setting the Background Color For the buttons
    GUICtrlSetBkColor($button2, 0x333333) ;Enter the Color in Hex! How that works:
    GUICtrlSetBkColor($button3, 0x333333) ;Pick your Color in RGB and add 0x at the beginning!
    GUICtrlSetColor($button1, 0xffffff) ;Seting the text color of the buttons!
    GUICtrlSetColor($button2, 0xffffff) ;It uses the same system as the background colors!
    GUICtrlSetColor($button3, 0xffffff) ;Final one!
    GuiSetState(@SW_SHOW) ;Set the GUI state to visable!
    Now, make it possible for the user to do something:
    Code:
    While 1 ;Let our GUI react to the users input! So that something happens if he clicks a button. And to make that our GUI is going to stay on the screen, and not directly going away!
    	$msg = GuiGetMsg() ;Getting the users input from the GUI that we created.
    	If $msg = $GUI_EVENT_CLOSE Then stop() ;If the user want's to close the GUI, then the function stop() will be done!
    	If $msg = $button1 Then button1() ;If the Activate button is clicked, the function button1() will be executed.
    	If $msg = $button2 Then button2() ;Same here for the button Deactivate
    	If $msg = $button3 Then button3() ;Starting CrossFire Europe
    	If $msg = $menuoption1 Then option1() ;This is our "Exit" option in the menu "File"
    	If $msg = $menuoption2 Then option2() ;This is our "Help" option in the menu "Help"
    Wend ; End that While statement. Time to add our Functions!
    Now we will add the functions for our loader!
    Code:
    Func button1() ;The function for the activate button!
    	FileCopy(@AppDataDir & "\myLoaderCache\sxs.dll",$loc1 & "\sxs.dll",1) ;This copies the hack file to your CrossFire location!
    	MsgBox(64,"Hack Activated","The Hack Is Succesfully Activated!") ;Let's the user know that the hack is activated!
    EndFunc ;End of the activate function
    
    Func button2() ;The function for the deactivate button!
    	FileDelete($loc1 & "\sxs.dll") ;Remove the hack file from the CrossFire location!
    	MsgBox(64,"Hack Deactivated","The hack Is Deactivated!") ;Gives the user a message box, saying that the hack is deactivated!
    EndFunc ;End of the deactivate function
    
    Func stop() ;The function to stop the launcher!
    	DirRemove(@AppDataDir & "\myLoaderCache",1) ;Removes the folder that we use to store the files that we need!
    	MsgBox(0,"Your Name Here!","Thanks For using!") ;Gives the user a messagebox, saying "Thanks For Using!"
    	Exit ;Exit's the launcher!
    EndFunc ;End of the stop function!
    
    Func option1() ;The function for the menu option "Exit" in the menu "File"!
    	stop() ;This just executes the function stop()
    EndFunc ;End of the function for the menu option "Exit"
    
    Func option2() ;The function for the menu option "Help" in the menu "Help"
    	ShellExecute("https://www.mpgh.net/forum/members/590240-berryh.html") ;Give the user a message box, let them go to your profile, or whatever you want!
    EndFunc ;End of the function for the menu option "Help"
    
    Func error1() ;This is the function for the "Select CrossFire Location" Dialog!
    	DirRemove(@AppDataDir & "\myLoaderCache",1) ;Just removes the folder we created to store our things!
    	Exit ;This just exit's the loader!
    EndFunc ;End of the function for the "Select CrossFire Location" Dialog!
    
    Func button3() ;This is the function for the button "Start CrossFire Europe"
    	Beep(1000,1000) ;This is the frustrating beep!:D
    	ShellExecute("patcher_cf","",$loc1) ;This executes patcher_cf.exe in the CrossFire Europe location that we have selected!
    	DirRemove(@AppDataDir & "\myLoaderCache",1) ;Remove the Folder that we created to store our files that we needed!
    	Exit ;This just exit's the loader
    EndFunc ;End of the function for the "Start CrossFire Europe" Button!
    Step 6
    Create an .exe file out of this!
    Click on the menu "Tools" in the SciTE editor.
    Then click on "Compile".
    Click on the button at the end of the option "Target x86" and choose the destination to save the .exe file to!
    Then click on the button at the end of the option icon, and select your .ico file. We have saved that one in our loader location!
    Then go to the tab "Resource Update" and type in the things you want to, like the "FileVersion"
    Then click on the button "Compile Script" to make an .exe file out of it!

    That's about it! Thank you for reading it!
    There is a complete example in the attachment file that you have downloaded!
    All the files used are in the map "Loader" in the attachment file!
    Good luck with the code! If you have any questions, just mail me at berryhmpgh@hotmail.com or send me a PM!

    Virusscans:

    VirusTotal

    Sorry, only ONE virusscan this time! The other virusscanners like Jotti and VirScan are freaking me out, because they can't really handle files this big!

    The viruses are again false positives! The are in the installer files i tought. I'm serious, that's not going to do anything to you! Just false positives!

    Fast Approval should be great!
    A Sticky to!

    Greetings,
    @berryh
    <b>Downloadable Files</b> Downloadable Files


    Join our new CrossFire Europe Clan!

    Follow us on Twitter to stay tuned about updates and more! [MPGH]Team Destroy

    If you need help: Send me a PM or send me an E-Mail: berryhmpgh@hotmail.com
    You can also add me on MSN using that adress!

    Take a look at our YouTube Channel! [MPGH]Team Destroy

    For all you guys who want's to know how i make my loader: Please take a look at My Loader Tutorial!

  2. The Following 27 Users Say Thank You to berryh For This Useful Post:

    abadea97 (10-30-2012),bilow (05-22-2012),Br4ncoxD (11-22-2012),cmc5414 (04-25-2012),d4n9el (10-26-2012),filipe008 (10-19-2012),flaviusxxx78 (10-27-2012),fueltv10 (10-30-2012),ghost2000 (11-09-2012),grannycrazy (03-03-2012),Iamollie (04-28-2012),janoelnil (11-25-2012),jodipro (02-21-2013),Kanesis (12-09-2012),keko1998 (04-30-2012),kernil13 (10-23-2012),ledot262 (04-27-2012),matt123lol (05-05-2012),matthewdbest1 (10-17-2012),mumun123 (12-04-2014),niotakakis (05-01-2012),pouler32 (11-07-2012),Ryuzaki™ (08-05-2012),toutou123123 (10-23-2012),xaim34 (10-26-2012),Yorollie (08-01-2012),zezo774 (07-12-2012)

  3. #2
    Hero's Avatar
    Join Date
    Feb 2011
    Gender
    male
    Location
    memes
    Posts
    40,198
    Reputation
    4764
    Thanks
    9,694
    Looks clean... Tutorial + Attachment Approved...
    [] [] [] [][]

    Editor from 06•14•2011 • 2014
    Donator since 09•16•2011
    Minion from 10•10•2011 • 01•06•2011
    Minion+ from 01•06•2012 • 08•08•2012
    Moderator from 08•08•2012 • 10•06•2012
    Global Moderator from 10•06•2012 • 12•05•2017
    Staff Administrator from 12•05•2017 • 05•01•2019
    Trusted Member since 07•13•2019
    Global Moderator since 09•11•2020




  4. #3
    berryh's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Location
    Netherlands
    Posts
    363
    Reputation
    10
    Thanks
    2,927
    Quote Originally Posted by Hero View Post
    Looks clean... Tutorial + Attachment Approved...
    Thank you Hero!


    Join our new CrossFire Europe Clan!

    Follow us on Twitter to stay tuned about updates and more! [MPGH]Team Destroy

    If you need help: Send me a PM or send me an E-Mail: berryhmpgh@hotmail.com
    You can also add me on MSN using that adress!

    Take a look at our YouTube Channel! [MPGH]Team Destroy

    For all you guys who want's to know how i make my loader: Please take a look at My Loader Tutorial!

  5. #4
    Swag's Avatar
    Join Date
    Jul 2011
    Gender
    male
    Location
    Netherlands
    Posts
    1,619
    Reputation
    19
    Thanks
    1,865
    My Mood
    Amused
    Good job

  6. #5
    Zvonimir Cro's Avatar
    Join Date
    Dec 2011
    Gender
    female
    Location
    VB coder
    Posts
    266
    Reputation
    11
    Thanks
    305
    My Mood
    Lonely

  7. #6
    lolzydolzy's Avatar
    Join Date
    Mar 2012
    Gender
    male
    Posts
    14
    Reputation
    10
    Thanks
    0
    How do u make it to a background on xp xD ?

  8. #7
    Swag's Avatar
    Join Date
    Jul 2011
    Gender
    male
    Location
    Netherlands
    Posts
    1,619
    Reputation
    19
    Thanks
    1,865
    My Mood
    Amused
    Quote Originally Posted by Zvonimir Cro View Post
    Yea, that's in VB
    This is in auto it.. i think a little bit difficulter

  9. #8
    Zvonimir Cro's Avatar
    Join Date
    Dec 2011
    Gender
    female
    Location
    VB coder
    Posts
    266
    Reputation
    11
    Thanks
    305
    My Mood
    Lonely
    Quote Originally Posted by Swag View Post
    Yea, that's in VB
    This is in auto it.. i think a little bit difficulter
    well why work on hard way

  10. #9
    Swag's Avatar
    Join Date
    Jul 2011
    Gender
    male
    Location
    Netherlands
    Posts
    1,619
    Reputation
    19
    Thanks
    1,865
    My Mood
    Amused
    Quote Originally Posted by Zvonimir Cro View Post


    well why work on hard way
    IDK, berryh like auto-it :P

  11. #10
    berryh's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Location
    Netherlands
    Posts
    363
    Reputation
    10
    Thanks
    2,927
    Quote Originally Posted by Zvonimir Cro View Post
    Yeah, autoit is easier to use and customize + you have to place your loader in the CrossFire directory. With my loader, you can place it everywhere!


    Join our new CrossFire Europe Clan!

    Follow us on Twitter to stay tuned about updates and more! [MPGH]Team Destroy

    If you need help: Send me a PM or send me an E-Mail: berryhmpgh@hotmail.com
    You can also add me on MSN using that adress!

    Take a look at our YouTube Channel! [MPGH]Team Destroy

    For all you guys who want's to know how i make my loader: Please take a look at My Loader Tutorial!

  12. #11
    berryh's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Location
    Netherlands
    Posts
    363
    Reputation
    10
    Thanks
    2,927
    Quote Originally Posted by lolzydolzy View Post
    How do u make it to a background on xp xD ?
    Sorry for the late response!
    It should work automatically!
    Add me on MSN so i can try to help you!


    Join our new CrossFire Europe Clan!

    Follow us on Twitter to stay tuned about updates and more! [MPGH]Team Destroy

    If you need help: Send me a PM or send me an E-Mail: berryhmpgh@hotmail.com
    You can also add me on MSN using that adress!

    Take a look at our YouTube Channel! [MPGH]Team Destroy

    For all you guys who want's to know how i make my loader: Please take a look at My Loader Tutorial!

  13. #12
    UnXperienS's Avatar
    Join Date
    Apr 2012
    Gender
    male
    Location
    In your House
    Posts
    317
    Reputation
    10
    Thanks
    33
    My Mood
    Cool
    nice work.
    AWESOMENESS
    WHEN I GET SAD, I STOP BEING SAD AND BE AWESOME AGAIN.



Similar Threads

  1. [Discussion] berryh Tutorial for my Team Destroy loader?
    By berryh in forum CrossFire Europe Discussions
    Replies: 8
    Last Post: 01-07-2012, 09:49 AM
  2. [Patched] Team Destroy CrossFire Europe Hack V4 Loader
    By berryh in forum CrossFire Europe Hacks
    Replies: 39
    Last Post: 12-27-2011, 09:46 AM
  3. [Patched] Team Destroy Crossfire EU Hack V2
    By Swag in forum CrossFire Europe Hacks
    Replies: 101
    Last Post: 12-16-2011, 11:47 AM
  4. [Patched] Team Destroy Cossfire EU Hack V1
    By Swag in forum CrossFire Europe Hacks
    Replies: 23
    Last Post: 11-24-2011, 04:02 PM
  5. [Request] Team Death Match Tutorial map?
    By lilkrnboy in forum CrossFire Mods & Rez Modding
    Replies: 1
    Last Post: 06-16-2011, 02:12 PM

Tags for this Thread