Jump to content

Tommis

MTA Contributors
  • Posts

    163
  • Joined

  • Last visited

Member Title

  • MTA Contributor

Details

  • Location
    Canada
  • Occupation
    Hardware & Lifeguard
  • Interests
    Currently soon taking my Internet Solutions Devoloper.

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Tommis's Achievements

Busta

Busta (15/54)

0

Reputation

  1. If they manage to compile the MTA 0.5 source code, updating the client would still consume too much time and effort. The developers are focusing on future task's, such as MTA SA Deathmatch.
  2. Hey, EDITED It is a very simple attack. UDP flood to the MTA Server's client port. What I have done is added many rules in my firewalls and coded a very simple Linux bash script to check every second and firewall the ips accordingly. You could also just add some rules into iptables dropping all packets with a certain length. Cya, Tommis
  3. It is made to stretch any image to full screen.
  4. Hey, Yes, very nice. Forgot to say it has full transperency support. =P But ye like I said, very simple script. Yet so powerfull ;D Cya, Tommis
  5. Ye, Already tried that. But quite a bit of people have trouble downloading it. (Takes longer than 5 seconds). So I thought screw it, they will see it the second time around when they join. Cya, Tommis
  6. Hey, Very simple script, yet very powerful. Since lots of people have found this useful (to whom I have given it too), I thought I would release it. This is basicaly a script in which, after a player joins, it will display a full screen logo (no matter what resolution they are using) for 15 seconds. This picture will be put on top of everything including the chatbox. Some known bugs are; - Player needs to download this resource. If he/she downloads it slow, will not display the first time - Image is never displayed for the whole 15 seconds. All depends on how long it takes the players game to load into your server - If you start adding more and more images to the players screen, might be hard to remove this one This is a resource, just put it in your resources folder, refresh or restart your server and load this resource. It is called start. Other than that, enjoy! http://www.x-serverz.com/downloads/start.zip Cya, Tommis
  7. Hey, Seems like if you set a MTU size, this will happen. Someone will join, get black screen then about 3-5 seconds later time out. (This is with DP2) Cya, Tommis
  8. Ah, true. Alright. Ill keep that message there for other people, might help them out.
  9. Hey, Alright, where to start. This might be a long read, but bear with me. It all started back in DP1, I was finding when the client was downloading files from the server (client side script files), it usually went quite slow. Soon after this, I found the httpdownloadurl and I decided to start using it. This is where the trouble began. I put the address in, made sure all the files were unzipped to their own folders with the correct folder names and that everything was accessible publicly via my webserver. Everything was a go. So i restarted the server, joined, and voila, no problems. Soon after this I was noticing many players joining, then disconnecting after about 2-3 seconds. I got intouch with these players and they all were reporting a download error 9. So, I thought to myself how they could be getting the download error, and I couldnt be getting that error. The reason they were getting the error and I wasn't is because I already had all of the client files downloaded from before I set the httpdownloadurl in. So i went into my client mtasadm folder and found the folder resources. I deleted that folder, started up the game and joined. And, just as i predicted, download error 9. I did a little investigation into this issue, but not much because i really thought it was a bug with mta, seeing how this was the first release. Please note, everything worked fine without the httpdownloadurl. So now DP2 comes around, and I am very excited to see if the httpdownloadurl bug was fixed. I got everything ready, set what had to be set, uploaded what had to be uploaded and started the server. I made sure my clients resources was empty, so i would redownload all the resources needed from the httpdownloadurl that was set in the server. I join the server, and..download error 9. I screamed in agony and pain. So, i decided to do some trial and error (the last option..oh god). I wanted to make sure 100% this was not a mistake of mine. Below is the semi long list of stuff i checked to make sure it was not a mistake of mine. - Made sure all files were there and unzipped in their seperate folders - Made sure (On my linux webserver) permissions were set correctly on ALL files and folders - Made sure in the httpdownloadurl section of my mtaserver.conf that i had the url without the trailing slash - Made sure the slash's were the correct direction - Made sure everything was spelt correctly - Read the wiki for this, and made sure everything met the requirements - Did quite a bit more, but can't remember at this time I then decided to go deeper in the trial and error, and to test it on one of my windows web servers. Who knows, maby it was Linux acting up with permissions, apache or something of that manner. So, went through the above checklist, one my one, made sure nothing was wrong. Connected, 2 seconds later, download error 9. From the investigation I did with DP1, i located it to be the admin resource, but I cannot confirm this, becuase with DP2, any resource client file download gives that error when httpdownloadurl is set. So now I am really desperate (spent quite a few hours on this, and wanted to find a way to fix it), and started talking to lil_toady. He gave me some pointers all stated in the above list. Nothing worked. Then he redirected me to http://curl.haxx.se/libcurl/c/libcurl-errors.html and to look under 'CURLE_REMOTE_ACCESS_DENIED (9)'. So I did, and it says there the following; This was not the problem. I tested many times to make sure everything was accessible publicly. Ontop of that, I tested on many web servers, all in different locations around the world. So, any pointers towards fixing this problem would be greatly apprecitated. Or if this is a bug, if you could look into it for the next release, I am sure many others would really appreciate it, not only me. Sorry for the long message and thanks for your time. Cya, Tommis
  10. Hey, Take a look at this http://www.mircscripts.org/showdoc.php?type=tutorial&id=1531 Might be some help. Or This.. ;-------------- - ---- - - - ; FTP by praetorian ; [email protected] ; http://detox.xs3.com ;---------------- - - - ; this snippet allows you to upload and download files to and from an ftp server. ; contains signals so you may easily create your own front end or integrate it into an existing script. ; ; use this code however you like, i commented and organized it to help you in case you want to write your own. ; ; syntax: /ftp <"local file"> <"remote file"> ; note: filenames must be complete paths and contained in quotes, i.e. "c:\myfile.ext" ; ; CHANGES on 10/04/2004: ; - added signal ftp.start ; sent when a transfer is initiated. use this to open custom @wins or dialogs. ; - added signal ftp.connect ; sent when a control connection to the server is opened. ; - added signal ftp.close ; sent when raw 221 (goodbye) is recieved from the server. ; - added signal ftp.error ; sent when an error occurs when connecting or communicating with the ftp server, in regards to the control connection. ; this signal was missing from the original code (oops!) ; ;-------------------------- ------------------------------------ - - - ;-------------------- - - ; FTP control connection ;------------ - ----- - - alias ftp { var %sn $+(ftp.,$gettok($2,1,58),.,$ticks),%lf = $gettok($1-,2,34),%rf = $gettok($1-,4,34) ; open socket to ftp server and mark it with login and file info sockopen %sn $gettok($2,1,58) $iif($gettok($2,2,58),$ifmatch,21) sockmark %sn $1 $3 $4 %lf $+ * $+ %rf ; set timer to check for connection timeout $+(.timerftpt,%sn) 1 30 ftp_timeout %sn $gettok($2,1,58) .signal ftp.start $gettok($2,1,58) } alias ftp_timeout { ; if no response from server, close socket and send timeout signal sockclose $1 .signal ftp.timeout $2 } on 1:sockopen:ftp.*:{ ; if connect error, send error signal if ($sockerr) { .signal -n ftp.error $deltok($gettok($sockname,2-,46),-1,46) $sock($sockname).wsmsg | return } ; if no error, send connect signal else { .signal -n ftp.connect $deltok($gettok($sockname,2-,46),-1,46) } ; turn timeout timer off $+(.timerftpt,$sockname) off } on 1:sockread:ftp.*:{ ; send signal if error if ($sockerr) { .signal -n ftp.error $deltok($gettok($sockname,2-,46),-1,46) $sock($sockname).wsmsg | return } :read ; read socket data sockread %fd ; make sure socket data isnt null, parse it if (%fd) { tokenize 32 $sock($sockname).mark ; response 220 (welcome text), send user if (220* iswm %fd) { sockwrite -n $sockname user $2 } ; response 331 (password required), send password if (331* iswm %fd) { sockwrite -n $sockname pass $3 } ; response 230 (logged in), send CWD command to enter the right directory ; (used a loop in case of multiple directories) if (230* iswm %fd) { var %p = $nofile($gettok($4-,2,42)),%p = $iif($right(%p,1) = \,$left(%p,-1-),%p),%i = 1 if ($count(%p,\)) { while ($gettok(%p,%i,92)) { sockwrite -n $sockname CWD $ifmatch sockmark $sockname $+($iif($1 = download,d,u),%i) $2- inc %i } } else { sockwrite -n $sockname CWD %p } } ; response 250 (CWD command successful), send TYPE I (binary) if (250* iswm %fd) { sockwrite -n $sockname TYPE I } ; response 200 (type set), send PASV to enter passive mode if (200* iswm %fd) { sockwrite -n $sockname PASV } ; response 227 (entering passive mode), open data connection and begin transfer if (227* iswm %fd) { ; if transfer type is download, send RETR and open socket to server if ($1 = download) || ($1 = d1) { sockwrite -n $sockname RETR $nopath($gettok($4-,2,42)) ftp_datadownload $gettok($gettok(%fd,2,40),1,41) $4- } ; if transfer is upload, send STOR, open socket to server and begin uploading elseif ($1 = upload) || ($1 = u1) { sockwrite -n $sockname STOR $nopath($gettok($4-,1,42)) ftp_dataupload $gettok($gettok(%fd,2,40),1,41) $gettok($4-,1,42) } ; used in case multiple CWD commands were issued; makes sure connection is made ; on most current remote port elseif ($right($1,1) isnum) { sockmark $sockname $+($left($1,1),$calc($right($1,1) - 1)) $2- } } if (150* iswm %fd) { ; find socket that is downloading this file and mark it with the size var %i = 1,%filn = $gettok($gettok(%fd,8-,32),1,40),%fils = $gettok($gettok(%fd,2,40),1,32) while ($sock(ftpdatadownload.*,%i)) { var %im = $ifmatch if ($nopath($gettok($gettok($sock(%im).mark,2,32),2,42)) = %filn) { sockmark %im %fils $gettok($sock(%im).mark,2-,32) | break } inc %i } } ; response 226 (transfer complete), send QUIT if (226* iswm %fd) { sockwrite -n $sockname QUIT } ; signal ftp text response .signal ftp.text $deltok($gettok($sockname,2-,46),-1,46) %fd ; response 221 (goodbye), transfer complete, send close signal if (221* iswm %fd) { .signal ftp.close $deltok($gettok($sockname,2-,46),-1,46) } } if ($sockbr) { goto read } } ;----------- - --- - - ; FTP upload ;-------- -------- - - alias ftp_dataupload { var %fn = $2- tokenize 44 $1 var %fi = $replace($1-4,$chr(32),$chr(46)) var %fp = $longip($+(0.0.,$replace($5-7,$chr(32),$chr(46)))) var %sn = $+(ftpdataupload.,%fi,.,$ticks) ; open socket and mark it with needed info sockopen %sn %fi %fp sockmark %sn 0 %fn ; set a timer to check for connection timeout $+(.timerftpt,%sn) 1 30 ftp_timeout %sn %fi } on 1:sockopen:ftpdataupload.*:{ ; send error signal if error if ($sockerr) { .signal ftp.dataconnection.error $sock($sockname).wsmsg | return } ; send connect signal if no error else { .signal ftp.dataconnection.connect $sock($sockname).ip $sock($sockname).port } ; cancel timeout $+(.timerftpt,$sockname) off tokenize 32 $sock($sockname).mark ; read file and send first packet bread $+(",$2-,") $1 4096 &bvar sockwrite $sockname &bvar ; mark socket with current position of file sockmark $sockname 4096 $2- } on 1:sockwrite:ftpdataupload.*:{ ; send error signal if error if ($sockerr) { .signal ftp.dataconnection.error $sock($sockname).wsmsg | return } tokenize 32 $sock($sockname).mark ; read file bread $+(",$2-,") $1 4096 &bvar var %s = $sock($sockname).ip $sock($sockname).port $file($+(",$2-,")).size $sock($sockname).sent $sock($sockname).to ; if data was read, send it if ($bvar(&bvar,0)) { sockwrite $sockname &bvar sockmark $sockname $calc($1 + 4096) $2- .signal ftp.dataconnection.send %s } ; if no data was read, file is finished sending, so close socket else { .signal ftp.dataconnection.send.close $deltok(%s,3,32) | sockclose $sockname } } on 1:sockclose:ftpdataupload.*:{ ; if error send signal, else send close signal if ($sockerr) { .signal ftp.dataconnection.error $sock($sockname).wsmsg | return } else { .signal ftp.dataconnection.send.close $sock($sockname).ip $sock($sockname).port $sock($sockname).sent $sock($sockname).to } } ;------------ -- - - ; FTP download ;------- - - alias ftp_datadownload { var %fn = $2- tokenize 44 $1 var %fi = $replace($1-4,$chr(32),$chr(46)) var %fp = $longip($+(0.0.,$replace($5-7,$chr(32),$chr(46)))) var %sn = $+(ftpdatadownload.,%fi,.,$ticks) ; open socket and mark it with needed data sockopen %sn %fi %fp sockmark %sn 0 %fn ; start timeout timer $+(.timerftpt,%sn) 1 30 ftp_timeout %sn %fi } on 1:sockopen:ftpdatadownload.*:{ ; send error signal if error if ($sockerr) { .signal ftp.dataconnection.error $sock($sockname).wsmsg | return } ; send connect signal if no error else { .signal ftp.dataconnection.connect $sock($sockname).ip $sock($sockname).port } ; cancel timeout $+(.timerftpt,$sockname) off } on 1:sockread:ftpdatadownload.*:{ ; if error, send signal if ($sockerr) { .signal ftp.dataconnection.error $sock($sockname).wsmsg | return } ; read socket :read sockread &fd ; write to file bwrite $gettok($gettok($sock($sockname).mark,2-,32),1,42) -1 -1 &fd ; if data is still waiting to be read if ($sockbr) { goto read } ; send signal .signal ftp.dataconnection.receive $sock($sockname).ip $sock($sockname).port $gettok($sock($sockname).mark,1,32) $sock($sockname).rcvd $sock($sockname).to } on 1:sockclose:ftpdatadownload.*:{ ; if error send signal, else send close signal if ($sockerr) { .signal ftp.dataconnection.error $sock($sockname).wsmsg | return } else { .signal ftp.dataconnection.receive.close $sock($sockname).ip $sock($sockname).port $sock($sockname).rcvd $sock($sockname).to } } ;-------------- - - ; signals ;----------- - ; sent when a control connection starts on 1:signal:ftp.start:{ ; $1 = connection address\ip echo -s FTP: Opening connection to $1 } ; sent when a control connection successfully connects on 1:signal:ftp.connect:{ ; $1 = connection address\ip echo -s FTP: Connection to $1 successful. } ; sent when a control connection closes with raw 221 (goodbye) on 1:signal:ftp.close:{ ; $1 = connection address\ip echo -s FTP: Connection to $1 closed. } ; sent when a control connection recieves an error on 1:signal:ftp.error:{ ; $1 = connection address\ip ; $2 = error message echo -s FTP: Error connecting or communicating with $1 ( $+ $2 $+ ) } ; sent when a connection times out on 1:signal:ftp.timeout:{ ; $1 = connection address\ip echo -s FTP: Connection to $1 timed out. } ; sent when the ftp server sends text on 1:signal:ftp.text:{ ; $1 = connection address ; $2- = text echo -s FTP: $1 $+ : $2- } ; sent when an error occurs in a data connection on 1:signal:ftp.dataconnection.error:{ ; $1 = IP address ; $2 = port ; $3 = error message echo -s FTP: Error opening data connection ( $+ $3- $+ ). } ; sent when a data connection connects on 1:signal:ftp.dataconnection.connect:{ ; $1 = IP address ; $2 = port echo -s FTP: Data connection to $1 $+ : $+ $2 opened. } ; sent when an uploading data connection sends a packet on 1:signal:ftp.dataconnection.send:{ ; $1 = IP address ; $2 = port ; $3 = size of file ; $4 = total bytes sent ; $5 = seconds socket has been open (for calculating speed) var %p = $round($calc(($4 / $3) * 100),0) echo -s FTP: Uploaded $bytes($4).suf of $bytes($3).suf ( $+ %p $+ $chr(37) $+ ) to $1 ( $+ $bytes($calc($4 / $5)).suf $+ /s) } ; sent when a downloading data connection receives a packet on 1:signal:ftp.dataconnection.receive:{ ; $1 = IP address ; $2 = port ; $3 = file size ; $4 = total bytes received ; $5 = seconds socket has been open (for calculating speed) echo -s FTP: Received $bytes($4).suf of $bytes($3).suf ( $+ $calc(($4 / $3) * 100) $+ $chr(37) $+ ) from $1 ( $+ $bytes($calc($4 / $5)).suf $+ /s) } ; sent when an uploading data connection is closed\completed on 1:signal:ftp.dataconnection.send.close:{ ; $1 = IP address ; $2 = port ; $3 = total bytes sent ; $4 = seconds socket has been open (for calculating speed) echo -s FTP: Data connection to $1 $+ : $+ $2 closed (sent $bytes($3).suf in $duration($4) ( $+ $bytes($calc($3 / $4)).suf $+ /s)) } ; sent when a downloading data connection is closed\completed on 1:signal:ftp.dataconnection.receive.close:{ ; $1 = IP address ; $2 = port ; $3 = total bytes received ; $4 = seconds socket has been open (for calculating speed) echo -s FTP: Data connection to $1 $+ : $+ $2 closed (recieved $bytes($3).suf in $duration($4) ( $+ $bytes($calc($3 / $4)).suf $+ /s)) } Cya, Tommis[/code]
  11. Hey, Take a look around if there is a dll for that, if so, that would be the easiest method. Other than that, if that fails, then i guess your stuck with sockets. Lucky enough, mirc makes it quite easy to use sockets comparing to other launguages. Ask **lil_today bout that, hes quite skilled in that area. ;p Cya, Tommis
  12. Hey, Good job boylett, keep up the good work! Cya, Tommis
  13. Tommis

    Help me again plz

    Salut, Premierement mettre ce texte dans un fichier texte. Deuxiemement, renommer ce fichier texte a un .mrc. Maintenant le charger avec mIRC. Mon français est faible. Désolé. Ne l'a pas utiliser souvent. (English = Im just telling him how to save in txt, rename and load.) au revoir, Tommis
  14. Hey, Good job, keep up the good work. Cya, Tommis
×
×
  • Create New...