Sign in to follow this  
Followers 0
melf

Function Where To Put It..

3 posts in this topic

Here is the complete code of the app im building

#include <GUIConstants.au3> 
#include <file.au3> 
#include <array.au3> 

GUICreate("Menu de Database",640,480) 
TrayTip("", "Gestionnaire d'inscription Imladris.", 1) 
; Menu 
$filemenu = GuiCtrlCreateMenu ("Fiche des Joueurs") 
$separator1 = GuiCtrlCreateMenuitem ("",$filemenu) 
$clearbutton = GuiCtrlCreateMenuitem ("Vider les Cases",$filemenu) 
$openbutton = GuiCtrlCreateMenuitem ("Importer",$filemenu) 
$savebutton = GUICtrlCreateMenuitem ("Sauvegarger",$filemenu) 
$separator1 = GuiCtrlCreateMenuitem ("",$filemenu) 
$helpmenu = GuiCtrlCreateMenu ("Information") 
$separator1 = GuiCtrlCreateMenuitem ("",$helpmenu) 
$nombre = GuiCtrlCreateMenuitem ("Nbres de Joueurs",$helpmenu) 
$aboutitem = GuiCtrlCreateMenuitem ("Info sur ce prog",$helpmenu) 
$separator1 = GuiCtrlCreateMenuitem ("",$helpmenu) 
$editmenu = GUICtrlCreateMenu("Backup",-1,1) 
$separator1 = GuiCtrlCreateMenuitem ("",$editmenu) 
$backup = GuiCtrlCreateMenuitem ("Faire un Backup des Inscriptions",$editmenu) 
$separator1 = GuiCtrlCreateMenuitem ("",$editmenu) 
$date = GuiCtrlCreateDate("", 5, 880, 1, 2,$WS_TABSTOP) 
GuiCtrlCreateLabel("INFO DU JOUEUR", 66, 8) 
GuiCtrlCreateLabel("FICHE PERSONNEL", 66, 37) 
GuiCtrlCreateLabel("Prénoms", 10, 52) 
$monprenom=GUICtrlCreateInput ("", 96,52,130,20) 
GUICtrlSetTip($monprenom,"Prenom du Joueur") 
GuiCtrlCreateLabel("Noms de famille", 10, 72) 
$monnom=GUICtrlCreateInput ("", 96,72,130,20) 
GuiCtrlCreateLabel("Adresse", 10, 92) 
$monadresse=GUICtrlCreateInput ("", 96,92,130,20) 
GuiCtrlCreateLabel("Ville", 10, 112) 
$monville=GUICtrlCreateInput ("", 96,112,130,20) 
GuiCtrlCreateLabel("Codepostal", 10, 132) 
$moncodepostale=GUICtrlCreateInput ("", 96,132,130,20) 
GuiCtrlCreateLabel("Téléphone", 10, 152) 
$montelephone=GUICtrlCreateInput ("", 96,152,130,20) 
GuiCtrlCreateLabel("Email", 10, 172) 
$monemail=GUICtrlCreateInput ("", 96,172,130,20) 
GUICtrlCreateLabel("CarteMaladie", 10, 192) 
$moncarteass=GUICtrlCreateInput ("",96,192,130,20) 
GUICtrlCreateLabel("Age", 10, 212) 
$monage=GUICtrlCreateInput ("",96,212,30,20) 
GuiCtrlCreateLabel("FICHE PERSONNAGE", 66, 262) 
GUICtrlCreateLabel("Nom de perso", 10, 282) 
$monnomperso=GUICtrlCreateInput ("",96,282,130,20) 
GUICtrlCreateLabel("Race", 10,302) 
$monrace=GUICtrlCreateInput ("",96,302,130,20) 
GUICtrlCreateLabel("Classe", 10,322) 
$monclasse=GUICtrlCreateInput("",96,322,130,20) 
GUICtrlCreateLabel("Clan", 10,342) 
$monclan=GUICtrlCreateInput("",96,342,130,20) 

;STATS 
GuiCtrlCreateLabel("PERSONNAGE (suite)", 376, 8) 
GuiCtrlCreateLabel("AVANTAGES", 296, 37) 
$monavant1=GUICtrlCreateInput ("", 246,52,180,20) 
$monavant2=GUICtrlCreateInput ("", 246,72,180,20) 
$monavant3=GUICtrlCreateInput ("", 246,92,180,20) 
$monavant4=GUICtrlCreateInput ("", 246,112,180,20) 
$monavant5=GUICtrlCreateInput ("", 246,132,180,20) 
$monavant6=GUICtrlCreateInput ("", 246,152,180,20) 
$monavant7=GUICtrlCreateInput ("", 246,172,180,20) 
$monavant8=GUICtrlCreateInput ("", 246,192,180,20) 
$monavant9=GUICtrlCreateInput ("", 246,212,180,20) 
$monavant10=GUICtrlCreateInput ("", 246,232,180,20) 
GuiCtrlCreateLabel("DÉSAVANTAGES", 296, 267) 
$mondesa1=GUICtrlCreateInput ("", 246,282,180,20) 
$mondesa2=GUICtrlCreateInput ("", 246,302,180,20) 
$mondesa3=GUICtrlCreateInput ("", 246,322,180,20) 
$mondesa4=GUICtrlCreateInput ("", 246,342,180,20) 
$mondesa5=GUICtrlCreateInput ("", 246,362,180,20) 
GuiCtrlCreateLabel("COMPÉTENCES", 496, 37) 
$moncompet1=GUICtrlCreateInput ("", 446,52,180,20) 
$moncompet2=GUICtrlCreateInput ("", 446,72,180,20) 
$moncompet3=GUICtrlCreateInput ("", 446,92,180,20) 
$moncompet4=GUICtrlCreateInput ("", 446,112,180,20) 
$moncompet5=GUICtrlCreateInput ("", 446,132,180,20) 
$moncompet6=GUICtrlCreateInput ("", 446,152,180,20) 
$moncompet7=GUICtrlCreateInput ("", 446,172,180,20) 
$moncompet8=GUICtrlCreateInput ("", 446,192,180,20) 
$moncompet9=GUICtrlCreateInput ("", 446,212,180,20) 
$moncompet10=GUICtrlCreateInput ("", 446,232,180,20) 
GuiCtrlCreateLabel("SPHERE/CULTE/MAGIE", 476, 267) 
$monmagie1=GUICtrlCreateInput ("", 446,282,180,20) 
$monmagie2=GUICtrlCreateInput ("", 446,302,180,20) 
$monmagie3=GUICtrlCreateInput ("", 446,322,180,20) 
$monmagie4=GUICtrlCreateInput ("", 446,342,180,20) 
$monmagie5=GUICtrlCreateInput ("", 446,362,180,20) 
$monmagie6=GUICtrlCreateInput ("", 446,382,180,20) 
$monmagie7=GUICtrlCreateInput ("", 446,402,180,20) 
$monmagie8=GUICtrlCreateInput ("", 446,422,180,20) 

GuiSetState() 

While 1 
$msg = GUIGetMsg() 


Select 

Case $msg = $GUI_EVENT_CLOSE 
ExitLoop 

Case $msg = $openbutton 
           $message = "Choisis un joueur." 
           $joueurimporter = FileOpenDialog($message,@ScriptDir,"Files (*ini)") 
$prenom = IniRead($joueurimporter,"Prenom","Info","") 
$nom = IniRead($joueurimporter, "Noms", "info","") 
$adresse = IniRead($joueurimporter, "Adresse", "info","") 
$ville = IniRead($joueurimporter, "Ville", "info","") 
$codepostale = IniRead($joueurimporter, "CodePostale", "info","") 
$age = IniRead($joueurimporter, "Age", "info","") 
$telephone = IniRead($joueurimporter, "Telephone", "info","") 
$email = IniRead($joueurimporter, "Email", "info","") 
$carteass = IniRead($joueurimporter, "Carteass", "info","") 
$nomperso = IniRead($joueurimporter, "Perso", "info","") 
$race = IniRead($joueurimporter, "Race", "info","") 
$classe = IniRead($joueurimporter, "Classe", "info","") 
$clan = IniRead($joueurimporter, "Clan", "info","") 
$avant1 = IniRead($joueurimporter, "Avantage1", "info","") 
$avant2 = IniRead($joueurimporter, "Avantage2", "info","") 
$avant3 = IniRead($joueurimporter, "Avantage3", "info","") 
$avant4 = IniRead($joueurimporter, "Avantage4", "info","") 
$avant5 = IniRead($joueurimporter, "Avantage5", "info","") 
$avant6 = IniRead($joueurimporter, "Avantage6", "info","") 
$avant7 = IniRead($joueurimporter, "Avantage7", "info","") 
$avant8 = IniRead($joueurimporter, "Avantage8", "info","") 
$avant9 = IniRead($joueurimporter, "Avantage9", "info","") 
$avant10 = IniRead($joueurimporter, "Avantage10", "info","") 
$desa1 = IniRead($joueurimporter, "desavantage1", "info","") 
$desa2 = IniRead($joueurimporter, "desavantage2", "info","") 
$desa3 = IniRead($joueurimporter, "desavantage3", "info","") 
$desa4 = IniRead($joueurimporter, "desavantage4", "info","") 
$desa5 = IniRead($joueurimporter, "desavantage5", "info","") 
$compet1 = IniRead($joueurimporter, "competence1", "info","") 
$compet2 = IniRead($joueurimporter, "competence2", "info","") 
$compet3 = IniRead($joueurimporter, "competence3", "info","") 
$compet4 = IniRead($joueurimporter, "competence4", "info","") 
$compet5 = IniRead($joueurimporter, "competence5", "info","") 
$compet6 = IniRead($joueurimporter, "competence6", "info","") 
$compet7 = IniRead($joueurimporter, "competence7", "info","") 
$compet8 = IniRead($joueurimporter, "competence8", "info","") 
$compet9 = IniRead($joueurimporter, "competence9", "info","") 
$compet10 = IniRead($joueurimporter, "competence10", "info","") 
$magie1 = IniRead($joueurimporter, "magie1", "info","") 
$magie2 = IniRead($joueurimporter, "magie2", "info","") 
$magie3 = IniRead($joueurimporter, "magie3", "info","") 
$magie4 = IniRead($joueurimporter, "magie4", "info","") 
$magie5 = IniRead($joueurimporter, "magie5", "info","") 
$magie6 = IniRead($joueurimporter, "magie6", "info","") 
$magie7 = IniRead($joueurimporter, "magie7", "info","") 
$magie8 = IniRead($joueurimporter, "magie8", "info","") 
GUICtrlSetData($monprenom, $prenom) 
GUICtrlSetData($monnom, $nom) 
GUICtrlSetData($monadresse, $adresse) 
GUICtrlSetData($monville, $ville) 
GUICtrlSetData($moncodepostale, $codepostale) 
GUICtrlSetData($montelephone, $telephone) 
GUICtrlSetData($monemail, $email) 
GUICtrlSetData($moncarteass, $carteass) 
GUICtrlSetData($monage, $age) 
GUICtrlSetData($monnomperso, $nomperso) 
GUICtrlSetData($monrace, $race) 
GUICtrlSetData($monclasse, $classe) 
GUICtrlSetData($monclan, $clan) 
GUICtrlSetData($monavant1, $avant1) 
GUICtrlSetData($monavant2, $avant2) 
GUICtrlSetData($monavant3, $avant3) 
GUICtrlSetData($monavant4, $avant4) 
GUICtrlSetData($monavant5, $avant5) 
GUICtrlSetData($monavant6, $avant6) 
GUICtrlSetData($monavant7, $avant7) 
GUICtrlSetData($monavant8, $avant8) 
GUICtrlSetData($monavant9, $avant9) 
GUICtrlSetData($monavant10, $avant10) 
GUICtrlSetData($mondesa1, $desa1) 
GUICtrlSetData($mondesa2, $desa2) 
GUICtrlSetData($mondesa3, $desa3) 
GUICtrlSetData($mondesa4, $desa4) 
GUICtrlSetData($mondesa5, $desa5) 
GUICtrlSetData($moncompet1, $compet1) 
GUICtrlSetData($moncompet2, $compet2) 
GUICtrlSetData($moncompet3, $compet3) 
GUICtrlSetData($moncompet4, $compet4) 
GUICtrlSetData($moncompet5, $compet5) 
GUICtrlSetData($moncompet6, $compet6) 
GUICtrlSetData($moncompet7, $compet7) 
GUICtrlSetData($moncompet8, $compet8) 
GUICtrlSetData($moncompet9, $compet9) 
GUICtrlSetData($moncompet10, $compet10) 
GUICtrlSetData($monmagie1, $magie1) 
GUICtrlSetData($monmagie2, $magie2) 
GUICtrlSetData($monmagie3, $magie3) 
GUICtrlSetData($monmagie4, $magie4) 
GUICtrlSetData($monmagie5, $magie5) 
GUICtrlSetData($monmagie6, $magie6) 
GUICtrlSetData($monmagie7, $magie7) 
GUICtrlSetData($monmagie8, $magie8) 

Case $msg = $savebutton 
$prenom=GUICtrlRead ($monprenom) 
$delim="-" 
$nom=GUICtrlRead ($monnom) 
$joueurimporter = $prenom & $delim & $nom & ".ini" 
          IniWrite($joueurimporter, "Prenom", "info", $prenom) 
          IniWrite($joueurimporter, "Noms", "info", $nom) 
          $adresse=GUICtrlRead ($monadresse) 
          IniWrite($joueurimporter, "Adresse", "info", $adresse) 
   $ville=GUICtrlRead ($monville) 
   IniWrite($joueurimporter, "Ville", "info", $ville) 
          $codepostale=GUICtrlRead ($moncodepostale) 
          IniWrite($joueurimporter, "CodePostale", "info", $codepostale) 
          $telephone=GUICtrlRead ($montelephone) 
          IniWrite($joueurimporter, "Telephone", "info", $telephone) 
          $email=GUICtrlRead ($monemail) 
          IniWrite($joueurimporter, "Email", "info", $email) 
   $carteass=GUICtrlRead ($moncarteass) 
   IniWrite($joueurimporter, "Carteass", "info", $carteass) 
   $age=GUICtrlRead ($monage) 
   IniWrite($joueurimporter, "Age", "info", $age) 
   $nomperso=GUICtrlRead ($monnomperso) 
   IniWrite($joueurimporter, "Perso", "info", $nomperso) 
   $race=GUICtrlRead ($monrace) 
   IniWrite($joueurimporter, "Race", "info", $race) 
   $classe=GUICtrlRead ($monclasse) 
   IniWrite($joueurimporter, "Classe", "info", $classe) 
   $clan=GUICtrlRead ($monclan) 
   IniWrite($joueurimporter, "Clan", "info", $clan) 
      $avant1=GUICtrlRead ($monavant1) 
   IniWrite($joueurimporter, "Avantage1", "info", $avant1) 
      $avant2=GUICtrlRead ($monavant2) 
   IniWrite($joueurimporter, "Avantage2", "info", $avant2) 
      $avant3=GUICtrlRead ($monavant3) 
   IniWrite($joueurimporter, "Avantage3", "info", $avant3) 
      $avant4=GUICtrlRead ($monavant4) 
   IniWrite($joueurimporter, "Avantage4", "info", $avant4) 
      $avant5=GUICtrlRead ($monavant5) 
   IniWrite($joueurimporter, "Avantage5", "info", $avant5) 
      $avant6=GUICtrlRead ($monavant6) 
   IniWrite($joueurimporter, "Avantage6", "info", $avant6) 
      $avant7=GUICtrlRead ($monavant7) 
   IniWrite($joueurimporter, "Avantage7", "info", $avant7) 
      $avant8=GUICtrlRead ($monavant8) 
   IniWrite($joueurimporter, "Avantage8", "info", $avant8) 
      $avant9=GUICtrlRead ($monavant9) 
   IniWrite($joueurimporter, "Avantage9", "info", $avant9) 
      $avant10=GUICtrlRead ($monavant10) 
   IniWrite($joueurimporter, "Avantage10", "info", $avant10) 
      $desa1=GUICtrlRead ($mondesa1) 
   IniWrite($joueurimporter, "desavantage1", "info", $desa1) 
      $desa2=GUICtrlRead ($mondesa2) 
   IniWrite($joueurimporter, "desavantage2", "info", $desa2) 
      $desa3=GUICtrlRead ($mondesa3) 
   IniWrite($joueurimporter, "desavantage3", "info", $desa3) 
      $desa4=GUICtrlRead ($mondesa4) 
   IniWrite($joueurimporter, "desavantage4", "info", $desa4) 
      $desa5=GUICtrlRead ($mondesa5) 
   IniWrite($joueurimporter, "desavantage5", "info", $desa5) 
      $compet1=GUICtrlRead ($moncompet1) 
   IniWrite($joueurimporter, "competence1", "info", $compet1) 
      $compet2=GUICtrlRead ($moncompet2) 
   IniWrite($joueurimporter, "competence2", "info", $compet2) 
      $compet3=GUICtrlRead ($moncompet3) 
   IniWrite($joueurimporter, "competence3", "info", $compet3) 
      $compet4=GUICtrlRead ($moncompet4) 
   IniWrite($joueurimporter, "competence4", "info", $compet4) 
      $compet5=GUICtrlRead ($moncompet5) 
   IniWrite($joueurimporter, "competence5", "info", $compet5) 
      $compet6=GUICtrlRead ($moncompet6) 
   IniWrite($joueurimporter, "competence6", "info", $compet6) 
      $compet7=GUICtrlRead ($moncompet7) 
   IniWrite($joueurimporter, "competence7", "info", $compet7) 
      $compet8=GUICtrlRead ($moncompet8) 
   IniWrite($joueurimporter, "competence8", "info", $compet8) 
      $compet9=GUICtrlRead ($moncompet9) 
   IniWrite($joueurimporter, "competence9", "info", $compet9) 
      $compet10=GUICtrlRead ($moncompet10) 
   IniWrite($joueurimporter, "competence10", "info", $compet10) 
      $magie1=GUICtrlRead ($monmagie1) 
   IniWrite($joueurimporter, "magie1", "info", $magie1) 
      $magie2=GUICtrlRead ($monmagie2) 
   IniWrite($joueurimporter, "magie2", "info", $magie2) 
      $magie3=GUICtrlRead ($monmagie3) 
   IniWrite($joueurimporter, "magie3", "info", $magie3) 
      $magie4=GUICtrlRead ($monmagie4) 
   IniWrite($joueurimporter, "magie4", "info", $magie4) 
      $magie5=GUICtrlRead ($monmagie5) 
   IniWrite($joueurimporter, "magie5", "info", $magie5) 
      $magie6=GUICtrlRead ($monmagie6) 
   IniWrite($joueurimporter, "magie6", "info", $magie6) 
      $magie7=GUICtrlRead ($monmagie7) 
   IniWrite($joueurimporter, "magie7", "info", $magie7) 
      $magie8=GUICtrlRead ($monmagie8) 
   IniWrite($joueurimporter, "magie8", "info", $magie8) 
GUICtrlSetData ( $monprenom, "") 
GUICtrlSetData ( $monnom, "") 
GUICtrlSetData ( $monadresse, "") 
GUICtrlSetData ( $monville, "") 
GUICtrlSetData ( $moncodepostale, "") 
GUICtrlSetData ( $montelephone, "") 
GUICtrlSetData ( $monemail, "") 
GUICtrlSetData ( $moncarteass, "") 
GUICtrlSetData ( $monage, "") 
GUICtrlSetData ( $monnomperso, "") 
GUICtrlSetData ( $monrace, "") 
GUICtrlSetData ( $monclasse, "") 
GUICtrlSetData ( $monclan, "") 
GUICtrlSetData ( $monavant1, "") 
GUICtrlSetData ( $monavant2, "") 
GUICtrlSetData ( $monavant3, "") 
GUICtrlSetData ( $monavant4, "") 
GUICtrlSetData ( $monavant5, "") 
GUICtrlSetData ( $monavant6, "") 
GUICtrlSetData ( $monavant7, "") 
GUICtrlSetData ( $monavant8, "") 
GUICtrlSetData ( $monavant9, "") 
GUICtrlSetData ( $monavant10, "") 
GUICtrlSetData ( $mondesa1, "") 
GUICtrlSetData ( $mondesa2, "") 
GUICtrlSetData ( $mondesa3, "") 
GUICtrlSetData ( $mondesa4, "") 
GUICtrlSetData ( $mondesa5, "") 
GUICtrlSetData ( $moncompet1, "") 
GUICtrlSetData ( $moncompet2, "") 
GUICtrlSetData ( $moncompet3, "") 
GUICtrlSetData ( $moncompet4, "") 
GUICtrlSetData ( $moncompet5, "") 
GUICtrlSetData ( $moncompet6, "") 
GUICtrlSetData ( $moncompet7, "") 
GUICtrlSetData ( $moncompet8, "") 
GUICtrlSetData ( $moncompet9, "") 
GUICtrlSetData ( $moncompet10, "") 
GUICtrlSetData ( $monmagie1, "") 
GUICtrlSetData ( $monmagie2, "") 
GUICtrlSetData ( $monmagie3, "") 
GUICtrlSetData ( $monmagie4, "") 
GUICtrlSetData ( $monmagie5, "") 
GUICtrlSetData ( $monmagie6, "") 
GUICtrlSetData ( $monmagie7, "") 
GUICtrlSetData ( $monmagie8, "") 

Case $msg = $nombre 

$sShellCmd = "DIR C:\final\*.ini /B > C:\joueursList.txt" 
RunWait(@ComSpec & " /c " & $sShellCmd, @TempDir) 
          $CountLines = _FileCountLines("C:\joueursList.txt") 
          MsgBox(64, "Joueurs Inscrit", "Il y a " & $CountLines & " joueurs d'inscrit.") 

Case $msg = $backup  
$datecheck=GUICtrlRead ($date) 
$blabla="Un Backup des fichiers a été créer en date du "
$blabla2= $blabla & $datecheck
MsgBox(0, "Backup", $blabla2) 
DirCreate("C:\final\backup" & " " & $datecheck) 
FileCopy("C:\final\*.ini", "C:\final\backup" & " " & $datecheck) 

Case $msg = $clearbutton 
GUICtrlSetData ( $monprenom, "") 
GUICtrlSetData ( $monnom, "") 
GUICtrlSetData ( $monadresse, "") 
GUICtrlSetData ( $monville, "") 
GUICtrlSetData ( $moncodepostale, "") 
GUICtrlSetData ( $montelephone, "") 
GUICtrlSetData ( $monemail, "") 
GUICtrlSetData ( $moncarteass, "") 
GUICtrlSetData ( $monage, "") 
GUICtrlSetData ( $monnomperso, "") 
GUICtrlSetData ( $monrace, "") 
GUICtrlSetData ( $monclasse, "") 
GUICtrlSetData ( $monclan, "") 
GUICtrlSetData ( $monavant1, "") 
GUICtrlSetData ( $monavant2, "") 
GUICtrlSetData ( $monavant3, "") 
GUICtrlSetData ( $monavant4, "") 
GUICtrlSetData ( $monavant5, "") 
GUICtrlSetData ( $monavant6, "") 
GUICtrlSetData ( $monavant7, "") 
GUICtrlSetData ( $monavant8, "") 
GUICtrlSetData ( $monavant9, "") 
GUICtrlSetData ( $monavant10, "") 
GUICtrlSetData ( $mondesa1, "") 
GUICtrlSetData ( $mondesa2, "") 
GUICtrlSetData ( $mondesa3, "") 
GUICtrlSetData ( $mondesa4, "") 
GUICtrlSetData ( $mondesa5, "") 
GUICtrlSetData ( $moncompet1, "") 
GUICtrlSetData ( $moncompet2, "") 
GUICtrlSetData ( $moncompet3, "") 
GUICtrlSetData ( $moncompet4, "") 
GUICtrlSetData ( $moncompet5, "") 
GUICtrlSetData ( $moncompet6, "") 
GUICtrlSetData ( $moncompet7, "") 
GUICtrlSetData ( $moncompet8, "") 
GUICtrlSetData ( $moncompet9, "") 
GUICtrlSetData ( $moncompet10, "") 
GUICtrlSetData ( $monmagie1, "") 
GUICtrlSetData ( $monmagie2, "") 
GUICtrlSetData ( $monmagie3, "") 
GUICtrlSetData ( $monmagie4, "") 
GUICtrlSetData ( $monmagie5, "") 
GUICtrlSetData ( $monmagie6, "") 
GUICtrlSetData ( $monmagie7, "") 
GUICtrlSetData ( $monmagie8, "") 

Case $msg = $aboutitem 
Msgbox(0,"Lecteur Database Imladris","Une Compillation Melf 2006") 
EndSelect 
WEnd


GUIDelete() 

Exit

Ive been trying for hours now to put in a fonction that will be called by the $savebutton menu item press ..

here is the fonction i want it to call..or something close to it..has you can see im just starting to learn how to code in autoit..

$orc="orc"
$elf="elf"
$human="human"
Func Racecheck()
    If $monrace=$orc then 
FileCopy($joueurimporter,"C:\final\orc\")
Elseif $monrace=$elf then 
FileCopy($joueurimporter,"C:\final\elf\")
Else$monrace=$orc then 
FileCopy($joueurimporter,"C:\final\orc\")
Endif
EndFunc

Can anyone tell me where i can stuff the function in my code so it can be called??

Share this post


Link to post
Share on other sites



Try this:

#include <GUIConstants.au3>
#include <file.au3>
#include <array.au3>

GUICreate("Menu de Database", 640, 480)
TrayTip("", "Gestionnaire d'inscription Imladris.", 1)
; Menu
$filemenu = GUICtrlCreateMenu("Fiche des Joueurs")
$separator1 = GUICtrlCreateMenuitem("", $filemenu)
$clearbutton = GUICtrlCreateMenuitem("Vider les Cases", $filemenu)
$openbutton = GUICtrlCreateMenuitem("Importer", $filemenu)
$savebutton = GUICtrlCreateMenuitem("Sauvegarger", $filemenu)
$separator1 = GUICtrlCreateMenuitem("", $filemenu)
$helpmenu = GUICtrlCreateMenu("Information")
$separator1 = GUICtrlCreateMenuitem("", $helpmenu)
$nombre = GUICtrlCreateMenuitem("Nbres de Joueurs", $helpmenu)
$aboutitem = GUICtrlCreateMenuitem("Info sur ce prog", $helpmenu)
$separator1 = GUICtrlCreateMenuitem("", $helpmenu)
$editmenu = GUICtrlCreateMenu("Backup", -1, 1)
$separator1 = GUICtrlCreateMenuitem("", $editmenu)
$backup = GUICtrlCreateMenuitem("Faire un Backup des Inscriptions", $editmenu)
$separator1 = GUICtrlCreateMenuitem("", $editmenu)
$date = GUICtrlCreateDate("", 5, 880, 1, 2, $WS_TABSTOP)
GUICtrlCreateLabel("INFO DU JOUEUR", 66, 8)
GUICtrlCreateLabel("FICHE PERSONNEL", 66, 37)
GUICtrlCreateLabel("Prénoms", 10, 52)
$monprenom = GUICtrlCreateInput("", 96, 52, 130, 20)
GUICtrlSetTip($monprenom, "Prenom du Joueur")
GUICtrlCreateLabel("Noms de famille", 10, 72)
$monnom = GUICtrlCreateInput("", 96, 72, 130, 20)
GUICtrlCreateLabel("Adresse", 10, 92)
$monadresse = GUICtrlCreateInput("", 96, 92, 130, 20)
GUICtrlCreateLabel("Ville", 10, 112)
$monville = GUICtrlCreateInput("", 96, 112, 130, 20)
GUICtrlCreateLabel("Codepostal", 10, 132)
$moncodepostale = GUICtrlCreateInput("", 96, 132, 130, 20)
GUICtrlCreateLabel("Téléphone", 10, 152)
$montelephone = GUICtrlCreateInput("", 96, 152, 130, 20)
GUICtrlCreateLabel("Email", 10, 172)
$monemail = GUICtrlCreateInput("", 96, 172, 130, 20)
GUICtrlCreateLabel("CarteMaladie", 10, 192)
$moncarteass = GUICtrlCreateInput("", 96, 192, 130, 20)
GUICtrlCreateLabel("Age", 10, 212)
$monage = GUICtrlCreateInput("", 96, 212, 30, 20)
GUICtrlCreateLabel("FICHE PERSONNAGE", 66, 262)
GUICtrlCreateLabel("Nom de perso", 10, 282)
$monnomperso = GUICtrlCreateInput("", 96, 282, 130, 20)
GUICtrlCreateLabel("Race", 10, 302)
$monrace = GUICtrlCreateInput("", 96, 302, 130, 20)
GUICtrlCreateLabel("Classe", 10, 322)
$monclasse = GUICtrlCreateInput("", 96, 322, 130, 20)
GUICtrlCreateLabel("Clan", 10, 342)
$monclan = GUICtrlCreateInput("", 96, 342, 130, 20)

;STATS
GUICtrlCreateLabel("PERSONNAGE (suite)", 376, 8)
GUICtrlCreateLabel("AVANTAGES", 296, 37)
$monavant1 = GUICtrlCreateInput("", 246, 52, 180, 20)
$monavant2 = GUICtrlCreateInput("", 246, 72, 180, 20)
$monavant3 = GUICtrlCreateInput("", 246, 92, 180, 20)
$monavant4 = GUICtrlCreateInput("", 246, 112, 180, 20)
$monavant5 = GUICtrlCreateInput("", 246, 132, 180, 20)
$monavant6 = GUICtrlCreateInput("", 246, 152, 180, 20)
$monavant7 = GUICtrlCreateInput("", 246, 172, 180, 20)
$monavant8 = GUICtrlCreateInput("", 246, 192, 180, 20)
$monavant9 = GUICtrlCreateInput("", 246, 212, 180, 20)
$monavant10 = GUICtrlCreateInput("", 246, 232, 180, 20)
GUICtrlCreateLabel("DÉSAVANTAGES", 296, 267)
$mondesa1 = GUICtrlCreateInput("", 246, 282, 180, 20)
$mondesa2 = GUICtrlCreateInput("", 246, 302, 180, 20)
$mondesa3 = GUICtrlCreateInput("", 246, 322, 180, 20)
$mondesa4 = GUICtrlCreateInput("", 246, 342, 180, 20)
$mondesa5 = GUICtrlCreateInput("", 246, 362, 180, 20)
GUICtrlCreateLabel("COMPÉTENCES", 496, 37)
$moncompet1 = GUICtrlCreateInput("", 446, 52, 180, 20)
$moncompet2 = GUICtrlCreateInput("", 446, 72, 180, 20)
$moncompet3 = GUICtrlCreateInput("", 446, 92, 180, 20)
$moncompet4 = GUICtrlCreateInput("", 446, 112, 180, 20)
$moncompet5 = GUICtrlCreateInput("", 446, 132, 180, 20)
$moncompet6 = GUICtrlCreateInput("", 446, 152, 180, 20)
$moncompet7 = GUICtrlCreateInput("", 446, 172, 180, 20)
$moncompet8 = GUICtrlCreateInput("", 446, 192, 180, 20)
$moncompet9 = GUICtrlCreateInput("", 446, 212, 180, 20)
$moncompet10 = GUICtrlCreateInput("", 446, 232, 180, 20)
GUICtrlCreateLabel("SPHERE/CULTE/MAGIE", 476, 267)
$monmagie1 = GUICtrlCreateInput("", 446, 282, 180, 20)
$monmagie2 = GUICtrlCreateInput("", 446, 302, 180, 20)
$monmagie3 = GUICtrlCreateInput("", 446, 322, 180, 20)
$monmagie4 = GUICtrlCreateInput("", 446, 342, 180, 20)
$monmagie5 = GUICtrlCreateInput("", 446, 362, 180, 20)
$monmagie6 = GUICtrlCreateInput("", 446, 382, 180, 20)
$monmagie7 = GUICtrlCreateInput("", 446, 402, 180, 20)
$monmagie8 = GUICtrlCreateInput("", 446, 422, 180, 20)

GUISetState()

While 1
    $msg = GUIGetMsg()
    
    
    Select
        
        Case $msg = $GUI_EVENT_CLOSE
            ExitLoop
            
        Case $msg = $openbutton
            $message = "Choisis un joueur."
            $joueurimporter = FileOpenDialog($message, @ScriptDir, "Files (*ini)")
            $prenom = IniRead($joueurimporter, "Prenom", "Info", "")
            $nom = IniRead($joueurimporter, "Noms", "info", "")
            $adresse = IniRead($joueurimporter, "Adresse", "info", "")
            $ville = IniRead($joueurimporter, "Ville", "info", "")
            $codepostale = IniRead($joueurimporter, "CodePostale", "info", "")
            $age = IniRead($joueurimporter, "Age", "info", "")
            $telephone = IniRead($joueurimporter, "Telephone", "info", "")
            $email = IniRead($joueurimporter, "Email", "info", "")
            $carteass = IniRead($joueurimporter, "Carteass", "info", "")
            $nomperso = IniRead($joueurimporter, "Perso", "info", "")
            $race = IniRead($joueurimporter, "Race", "info", "")
            $classe = IniRead($joueurimporter, "Classe", "info", "")
            $clan = IniRead($joueurimporter, "Clan", "info", "")
            $avant1 = IniRead($joueurimporter, "Avantage1", "info", "")
            $avant2 = IniRead($joueurimporter, "Avantage2", "info", "")
            $avant3 = IniRead($joueurimporter, "Avantage3", "info", "")
            $avant4 = IniRead($joueurimporter, "Avantage4", "info", "")
            $avant5 = IniRead($joueurimporter, "Avantage5", "info", "")
            $avant6 = IniRead($joueurimporter, "Avantage6", "info", "")
            $avant7 = IniRead($joueurimporter, "Avantage7", "info", "")
            $avant8 = IniRead($joueurimporter, "Avantage8", "info", "")
            $avant9 = IniRead($joueurimporter, "Avantage9", "info", "")
            $avant10 = IniRead($joueurimporter, "Avantage10", "info", "")
            $desa1 = IniRead($joueurimporter, "desavantage1", "info", "")
            $desa2 = IniRead($joueurimporter, "desavantage2", "info", "")
            $desa3 = IniRead($joueurimporter, "desavantage3", "info", "")
            $desa4 = IniRead($joueurimporter, "desavantage4", "info", "")
            $desa5 = IniRead($joueurimporter, "desavantage5", "info", "")
            $compet1 = IniRead($joueurimporter, "competence1", "info", "")
            $compet2 = IniRead($joueurimporter, "competence2", "info", "")
            $compet3 = IniRead($joueurimporter, "competence3", "info", "")
            $compet4 = IniRead($joueurimporter, "competence4", "info", "")
            $compet5 = IniRead($joueurimporter, "competence5", "info", "")
            $compet6 = IniRead($joueurimporter, "competence6", "info", "")
            $compet7 = IniRead($joueurimporter, "competence7", "info", "")
            $compet8 = IniRead($joueurimporter, "competence8", "info", "")
            $compet9 = IniRead($joueurimporter, "competence9", "info", "")
            $compet10 = IniRead($joueurimporter, "competence10", "info", "")
            $magie1 = IniRead($joueurimporter, "magie1", "info", "")
            $magie2 = IniRead($joueurimporter, "magie2", "info", "")
            $magie3 = IniRead($joueurimporter, "magie3", "info", "")
            $magie4 = IniRead($joueurimporter, "magie4", "info", "")
            $magie5 = IniRead($joueurimporter, "magie5", "info", "")
            $magie6 = IniRead($joueurimporter, "magie6", "info", "")
            $magie7 = IniRead($joueurimporter, "magie7", "info", "")
            $magie8 = IniRead($joueurimporter, "magie8", "info", "")
            GUICtrlSetData($monprenom, $prenom)
            GUICtrlSetData($monnom, $nom)
            GUICtrlSetData($monadresse, $adresse)
            GUICtrlSetData($monville, $ville)
            GUICtrlSetData($moncodepostale, $codepostale)
            GUICtrlSetData($montelephone, $telephone)
            GUICtrlSetData($monemail, $email)
            GUICtrlSetData($moncarteass, $carteass)
            GUICtrlSetData($monage, $age)
            GUICtrlSetData($monnomperso, $nomperso)
            GUICtrlSetData($monrace, $race)
            GUICtrlSetData($monclasse, $classe)
            GUICtrlSetData($monclan, $clan)
            GUICtrlSetData($monavant1, $avant1)
            GUICtrlSetData($monavant2, $avant2)
            GUICtrlSetData($monavant3, $avant3)
            GUICtrlSetData($monavant4, $avant4)
            GUICtrlSetData($monavant5, $avant5)
            GUICtrlSetData($monavant6, $avant6)
            GUICtrlSetData($monavant7, $avant7)
            GUICtrlSetData($monavant8, $avant8)
            GUICtrlSetData($monavant9, $avant9)
            GUICtrlSetData($monavant10, $avant10)
            GUICtrlSetData($mondesa1, $desa1)
            GUICtrlSetData($mondesa2, $desa2)
            GUICtrlSetData($mondesa3, $desa3)
            GUICtrlSetData($mondesa4, $desa4)
            GUICtrlSetData($mondesa5, $desa5)
            GUICtrlSetData($moncompet1, $compet1)
            GUICtrlSetData($moncompet2, $compet2)
            GUICtrlSetData($moncompet3, $compet3)
            GUICtrlSetData($moncompet4, $compet4)
            GUICtrlSetData($moncompet5, $compet5)
            GUICtrlSetData($moncompet6, $compet6)
            GUICtrlSetData($moncompet7, $compet7)
            GUICtrlSetData($moncompet8, $compet8)
            GUICtrlSetData($moncompet9, $compet9)
            GUICtrlSetData($moncompet10, $compet10)
            GUICtrlSetData($monmagie1, $magie1)
            GUICtrlSetData($monmagie2, $magie2)
            GUICtrlSetData($monmagie3, $magie3)
            GUICtrlSetData($monmagie4, $magie4)
            GUICtrlSetData($monmagie5, $magie5)
            GUICtrlSetData($monmagie6, $magie6)
            GUICtrlSetData($monmagie7, $magie7)
            GUICtrlSetData($monmagie8, $magie8)
            
        Case $msg = $savebutton
            
            $prenom = GUICtrlRead($monprenom)
            $delim = "-"
            $nom = GUICtrlRead($monnom)
            $joueurimporter = $prenom & $delim & $nom & ".ini"
            IniWrite($joueurimporter, "Prenom", "info", $prenom)
            IniWrite($joueurimporter, "Noms", "info", $nom)
            $adresse = GUICtrlRead($monadresse)
            IniWrite($joueurimporter, "Adresse", "info", $adresse)
            $ville = GUICtrlRead($monville)
            IniWrite($joueurimporter, "Ville", "info", $ville)
            $codepostale = GUICtrlRead($moncodepostale)
            IniWrite($joueurimporter, "CodePostale", "info", $codepostale)
            $telephone = GUICtrlRead($montelephone)
            IniWrite($joueurimporter, "Telephone", "info", $telephone)
            $email = GUICtrlRead($monemail)
            IniWrite($joueurimporter, "Email", "info", $email)
            $carteass = GUICtrlRead($moncarteass)
            IniWrite($joueurimporter, "Carteass", "info", $carteass)
            $age = GUICtrlRead($monage)
            IniWrite($joueurimporter, "Age", "info", $age)
            $nomperso = GUICtrlRead($monnomperso)
            IniWrite($joueurimporter, "Perso", "info", $nomperso)
            $race = GUICtrlRead($monrace)
            IniWrite($joueurimporter, "Race", "info", $race)
            $classe = GUICtrlRead($monclasse)
            IniWrite($joueurimporter, "Classe", "info", $classe)
            $clan = GUICtrlRead($monclan)
            IniWrite($joueurimporter, "Clan", "info", $clan)
            $avant1 = GUICtrlRead($monavant1)
            IniWrite($joueurimporter, "Avantage1", "info", $avant1)
            $avant2 = GUICtrlRead($monavant2)
            IniWrite($joueurimporter, "Avantage2", "info", $avant2)
            $avant3 = GUICtrlRead($monavant3)
            IniWrite($joueurimporter, "Avantage3", "info", $avant3)
            $avant4 = GUICtrlRead($monavant4)
            IniWrite($joueurimporter, "Avantage4", "info", $avant4)
            $avant5 = GUICtrlRead($monavant5)
            IniWrite($joueurimporter, "Avantage5", "info", $avant5)
            $avant6 = GUICtrlRead($monavant6)
            IniWrite($joueurimporter, "Avantage6", "info", $avant6)
            $avant7 = GUICtrlRead($monavant7)
            IniWrite($joueurimporter, "Avantage7", "info", $avant7)
            $avant8 = GUICtrlRead($monavant8)
            IniWrite($joueurimporter, "Avantage8", "info", $avant8)
            $avant9 = GUICtrlRead($monavant9)
            IniWrite($joueurimporter, "Avantage9", "info", $avant9)
            $avant10 = GUICtrlRead($monavant10)
            IniWrite($joueurimporter, "Avantage10", "info", $avant10)
            $desa1 = GUICtrlRead($mondesa1)
            IniWrite($joueurimporter, "desavantage1", "info", $desa1)
            $desa2 = GUICtrlRead($mondesa2)
            IniWrite($joueurimporter, "desavantage2", "info", $desa2)
            $desa3 = GUICtrlRead($mondesa3)
            IniWrite($joueurimporter, "desavantage3", "info", $desa3)
            $desa4 = GUICtrlRead($mondesa4)
            IniWrite($joueurimporter, "desavantage4", "info", $desa4)
            $desa5 = GUICtrlRead($mondesa5)
            IniWrite($joueurimporter, "desavantage5", "info", $desa5)
            $compet1 = GUICtrlRead($moncompet1)
            IniWrite($joueurimporter, "competence1", "info", $compet1)
            $compet2 = GUICtrlRead($moncompet2)
            IniWrite($joueurimporter, "competence2", "info", $compet2)
            $compet3 = GUICtrlRead($moncompet3)
            IniWrite($joueurimporter, "competence3", "info", $compet3)
            $compet4 = GUICtrlRead($moncompet4)
            IniWrite($joueurimporter, "competence4", "info", $compet4)
            $compet5 = GUICtrlRead($moncompet5)
            IniWrite($joueurimporter, "competence5", "info", $compet5)
            $compet6 = GUICtrlRead($moncompet6)
            IniWrite($joueurimporter, "competence6", "info", $compet6)
            $compet7 = GUICtrlRead($moncompet7)
            IniWrite($joueurimporter, "competence7", "info", $compet7)
            $compet8 = GUICtrlRead($moncompet8)
            IniWrite($joueurimporter, "competence8", "info", $compet8)
            $compet9 = GUICtrlRead($moncompet9)
            IniWrite($joueurimporter, "competence9", "info", $compet9)
            $compet10 = GUICtrlRead($moncompet10)
            IniWrite($joueurimporter, "competence10", "info", $compet10)
            $magie1 = GUICtrlRead($monmagie1)
            IniWrite($joueurimporter, "magie1", "info", $magie1)
            $magie2 = GUICtrlRead($monmagie2)
            IniWrite($joueurimporter, "magie2", "info", $magie2)
            $magie3 = GUICtrlRead($monmagie3)
            IniWrite($joueurimporter, "magie3", "info", $magie3)
            $magie4 = GUICtrlRead($monmagie4)
            IniWrite($joueurimporter, "magie4", "info", $magie4)
            $magie5 = GUICtrlRead($monmagie5)
            IniWrite($joueurimporter, "magie5", "info", $magie5)
            $magie6 = GUICtrlRead($monmagie6)
            IniWrite($joueurimporter, "magie6", "info", $magie6)
            $magie7 = GUICtrlRead($monmagie7)
            IniWrite($joueurimporter, "magie7", "info", $magie7)
            $magie8 = GUICtrlRead($monmagie8)
            IniWrite($joueurimporter, "magie8", "info", $magie8)
            GUICtrlSetData($monprenom, "")
            GUICtrlSetData($monnom, "")
            GUICtrlSetData($monadresse, "")
            GUICtrlSetData($monville, "")
            GUICtrlSetData($moncodepostale, "")
            GUICtrlSetData($montelephone, "")
            GUICtrlSetData($monemail, "")
            GUICtrlSetData($moncarteass, "")
            GUICtrlSetData($monage, "")
            GUICtrlSetData($monnomperso, "")
            GUICtrlSetData($monrace, "")
            GUICtrlSetData($monclasse, "")
            GUICtrlSetData($monclan, "")
            GUICtrlSetData($monavant1, "")
            GUICtrlSetData($monavant2, "")
            GUICtrlSetData($monavant3, "")
            GUICtrlSetData($monavant4, "")
            GUICtrlSetData($monavant5, "")
            GUICtrlSetData($monavant6, "")
            GUICtrlSetData($monavant7, "")
            GUICtrlSetData($monavant8, "")
            GUICtrlSetData($monavant9, "")
            GUICtrlSetData($monavant10, "")
            GUICtrlSetData($mondesa1, "")
            GUICtrlSetData($mondesa2, "")
            GUICtrlSetData($mondesa3, "")
            GUICtrlSetData($mondesa4, "")
            GUICtrlSetData($mondesa5, "")
            GUICtrlSetData($moncompet1, "")
            GUICtrlSetData($moncompet2, "")
            GUICtrlSetData($moncompet3, "")
            GUICtrlSetData($moncompet4, "")
            GUICtrlSetData($moncompet5, "")
            GUICtrlSetData($moncompet6, "")
            GUICtrlSetData($moncompet7, "")
            GUICtrlSetData($moncompet8, "")
            GUICtrlSetData($moncompet9, "")
            GUICtrlSetData($moncompet10, "")
            GUICtrlSetData($monmagie1, "")
            GUICtrlSetData($monmagie2, "")
            GUICtrlSetData($monmagie3, "")
            GUICtrlSetData($monmagie4, "")
            GUICtrlSetData($monmagie5, "")
            GUICtrlSetData($monmagie6, "")
            GUICtrlSetData($monmagie7, "")
            GUICtrlSetData($monmagie8, "")
            RaceCheck()
        Case $msg = $nombre
            
            $sShellCmd = "DIR C:\final\*.ini /B > C:\joueursList.txt"
            RunWait(@ComSpec & " /c " & $sShellCmd, @TempDir)
            $CountLines = _FileCountLines("C:\joueursList.txt")
            MsgBox(64, "Joueurs Inscrit", "Il y a " & $CountLines & " joueurs d'inscrit.")
            
        Case $msg = $backup
            $datecheck = GUICtrlRead($date)
            $blabla = "Un Backup des fichiers a été créer en date du "
            $blabla2 = $blabla & $datecheck
            MsgBox(0, "Backup", $blabla2)
            DirCreate("C:\final\backup" & " " & $datecheck)
            FileCopy("C:\final\*.ini", "C:\final\backup" & " " & $datecheck)
            
        Case $msg = $clearbutton
            GUICtrlSetData($monprenom, "")
            GUICtrlSetData($monnom, "")
            GUICtrlSetData($monadresse, "")
            GUICtrlSetData($monville, "")
            GUICtrlSetData($moncodepostale, "")
            GUICtrlSetData($montelephone, "")
            GUICtrlSetData($monemail, "")
            GUICtrlSetData($moncarteass, "")
            GUICtrlSetData($monage, "")
            GUICtrlSetData($monnomperso, "")
            GUICtrlSetData($monrace, "")
            GUICtrlSetData($monclasse, "")
            GUICtrlSetData($monclan, "")
            GUICtrlSetData($monavant1, "")
            GUICtrlSetData($monavant2, "")
            GUICtrlSetData($monavant3, "")
            GUICtrlSetData($monavant4, "")
            GUICtrlSetData($monavant5, "")
            GUICtrlSetData($monavant6, "")
            GUICtrlSetData($monavant7, "")
            GUICtrlSetData($monavant8, "")
            GUICtrlSetData($monavant9, "")
            GUICtrlSetData($monavant10, "")
            GUICtrlSetData($mondesa1, "")
            GUICtrlSetData($mondesa2, "")
            GUICtrlSetData($mondesa3, "")
            GUICtrlSetData($mondesa4, "")
            GUICtrlSetData($mondesa5, "")
            GUICtrlSetData($moncompet1, "")
            GUICtrlSetData($moncompet2, "")
            GUICtrlSetData($moncompet3, "")
            GUICtrlSetData($moncompet4, "")
            GUICtrlSetData($moncompet5, "")
            GUICtrlSetData($moncompet6, "")
            GUICtrlSetData($moncompet7, "")
            GUICtrlSetData($moncompet8, "")
            GUICtrlSetData($moncompet9, "")
            GUICtrlSetData($moncompet10, "")
            GUICtrlSetData($monmagie1, "")
            GUICtrlSetData($monmagie2, "")
            GUICtrlSetData($monmagie3, "")
            GUICtrlSetData($monmagie4, "")
            GUICtrlSetData($monmagie5, "")
            GUICtrlSetData($monmagie6, "")
            GUICtrlSetData($monmagie7, "")
            GUICtrlSetData($monmagie8, "")
            
        Case $msg = $aboutitem
            MsgBox(0, "Lecteur Database Imladris", "Une Compillation Melf 2006")
    EndSelect
WEnd


GUIDelete()

Exit

Func Racecheck()
    If $monrace = "orc" Then
        FileCopy($joueurimporter, "C:\final\orc\")
    ElseIf $monrace = "elf" Then
        FileCopy($joueurimporter, "C:\final\elf\")
    ElseIf $monrace = "human" Then
        FileCopy($joueurimporter, "C:\final\human\")
    EndIf
EndFunc  ;==>Racecheck

Just some suggestions. Your script could be cut down to about 1/3 its current size if you loop most of what you are doing with your GUI Creation and manipulation.

Also in your RaceCheck() you were checking orc twice.. I changed ione of the checks to human.


AutoIt Scripts:Aimbot: Proof of Concept - PixelSearching Aimbot with several search/autoshoot/lock-on techniques.Sliding Toolbar - Add a nice Sliding Toolbar to your next script. Click the link to see an animation of it in action!FontInfo UDF - Get list of system fonts, or search to see if a particular font is installed.Get Extended Property UDF - Retrieve a files extended properties (e.g., video/image dimensions, file version, bitrate of song/video, etc)

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

Found it :)

Func Racecheck()
    If $race == "orc" Then
        FileCopy($joueurimporter, "C:\final\orc\")
    ElseIf $race == "Orc" Then
    FileCopy($joueurimporter, "C:\final\orc\")
    ElseIf $race == "elfe" Then
        FileCopy($joueurimporter, "C:\final\elfe\")
    ElseIf $race == "Elfe" Then
        FileCopy($joueurimporter, "C:\final\elfe\")
    Else 
        FileCopy($joueurimporter, "C:\final\humain\")
    EndIf
Edited by melf

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0