24.04.2018, 15:34
That's the whole project, you can open it using the DeveltStudio.
Here is the code of the button 'Join'.
And here is the code of the button 'Save'
Here is the code of the button 'Join'.
Code:
$ip = c("label_adress")->text;
if(c("label_adress")->text != "IP adresa"){
$server = "@echo off
cd $location
samp.exe $ip";
data::write($server, "samp.bat");
Run("samp.bat", false);
c("timer1")->enable = true;
c("sqPlayer1")->stop();
}else{
messageDlg("Niste uneli IP adresu!", mtError, MB_OK);
}
Code:
$nick = c("label_username")->text;
if(c("label_username")->text != "Korisnicko ime"){
writeRegKey(HKEY_USERS, "Software\SAMP\PlayerName", $nick, STRING);
writeRegKey(HKEY_USERS, "S-1-5-21-1739866482-1348050454-3081657855-1001\Software\SAMP\PlayerName", $nick, STRING);
hideForm(settings, SW_HIDE);
}else{
messageDlg("Niste uneli korisnicko ime!", mtError, MB_OK);
}


