chrislabricole Posted October 22, 2007 Share Posted October 22, 2007 Hello ! (sorry for my english...) I made a IRC script to say "Welcome !" in the chatbox, but, everybody can read the message on the server... I would like to this message say only at the person who is connecting my script it : on *:SIGNAL:mta.join: { mta.text $1 Welcome ! } i have think of it: on *:SIGNAL:mta.join: { mta.pm $1 $2 Welcome ! } but, that code doesn't march What is the code for sending a PM at the only person who is connecting on the server?? Thanks Link to comment
SanZoR Posted October 22, 2007 Share Posted October 22, 2007 on *:SIGNAL:mta.join: {mta.pm $1 $2 Hello ($mta.nick($1,$2) $+ , and welcome to this server! } It works Link to comment
lil Toady Posted October 22, 2007 Share Posted October 22, 2007 Lil'San^,^u<3, you lie, you have a mistake in your script so it can't work.. that's an individual message that will be said only when you join: on *:SIGNAL:mta.join:{ if ($mta.nick($1,$2) == chrislabricole) mta.text $1 Welcome $mta.nick($1,$2) $+ , the boss! } And this is when anybody joins but will put the nick of the joined player in the message: [code]on *:SIGNAL:mta.join:{ mta.text $1 Welcome $mta.nick($1,$2) $+ ! } [/code] $1 - Server ID the player joined. $2 - Player ID So $mta.nick($1,$2) - the nick of the joined player. Link to comment
[UVA]Bart Posted October 22, 2007 Share Posted October 22, 2007 and you say you can script lil^san /me shakes my head at him in ! Link to comment
chrislabricole Posted October 22, 2007 Author Share Posted October 22, 2007 no, when i say "individual message", i mean that send un PM at the guys who is connecting... so on *:SIGNAL:mta.join: { mta.pm $1 $2 Welcome $mta.nick($1,$2) ! } I would like that send "Welcome !" at only the person who is joining (PM at guys) Thanks ! ^^ Link to comment
lil Toady Posted October 22, 2007 Share Posted October 22, 2007 on *:SIGNAL:mta.join:{ mta.pm $1 $2 Welcome $mta.nick($1,$2) $+ ! } Link to comment
[UVA]Bart Posted October 22, 2007 Share Posted October 22, 2007 dam your good lil^toady lol just beat me to the $+ lol Link to comment
chrislabricole Posted October 22, 2007 Author Share Posted October 22, 2007 on *:SIGNAL:mta.join:{ mta.pm $1 $2 Welcome $mta.nick($1,$2) $+ ! } so, this code doesn't work.... but.... what's the "$+" in code ????? Thanks for your helping ! Link to comment
MB|Lagzilla Posted October 22, 2007 Share Posted October 22, 2007 Erm that would work and is exactly what you want, the $+ is a function seperator I think? I know what it does but not what it's called. Link to comment
[UVA]Bart Posted October 22, 2007 Share Posted October 22, 2007 i use $+ to join to words when writing ini's , hash or text as it doesnt show the text when you put say hello! so that would be hello $+ ! which joins them together ask toady for a more detailed explination Link to comment
chrislabricole Posted October 22, 2007 Author Share Posted October 22, 2007 Sorry, i don't understand your english, I'm french, i speak little english.... Could you give me a code that works ? please Thanks Link to comment
MB|Lagzilla Posted October 22, 2007 Share Posted October 22, 2007 What the hell? That does work! Link to comment
chrislabricole Posted October 22, 2007 Author Share Posted October 22, 2007 There are no PM to send... Link to comment
lil Toady Posted October 22, 2007 Share Posted October 22, 2007 $+ makes 2 words merge. 'hello $+ world' will return 'helloworld' Why do we need that? cause if we do $mta.name($1,$2)! it will not work, if we want to merge an alias with some text we use $+ And uh, the code doesn't work? Have you pasted it into some script? What's your mta:ma version and is it connected? Scripts enabled? Remember, you can not have to same signals in one script, so if you had 'on *:SIGNAL:mta.join:{' line in the script you pasted the code to it will not work Link to comment
chrislabricole Posted October 22, 2007 Author Share Posted October 22, 2007 my mta version is "MTA:SA R1"(mod Race) i have pasted on *:SIGNAL:mta.join:{mta.pm $1 $2 Welcome $mta.nick($1,$2) $+ ! } in the file "script.mrc" and this file is included by "General" > "Scripts..." Remember, the script : on *:SIGNAL:mta.join: {mta.text $1 Welcome $mta.nick($1,$2) ! } work ! (but everybody can read the message on the server... ) I wasn't put the 2 script together... I don't know why this code doesn't work : on *:SIGNAL:mta.join:{mta.pm $1 $2 Welcome $mta.nick($1,$2) $+ ! } Thanks Link to comment
[UVA]Bart Posted October 22, 2007 Share Posted October 22, 2007 alter the first one to mta.pm $1 $2 instead of mta.text $1 Link to comment
chrislabricole Posted October 22, 2007 Author Share Posted October 22, 2007 this???? on *:SIGNAL:mta.join:{mta.text $1 $2 Welcome $mta.nick($1,$2) $+ ! } it send in chatbox : 2 Welcome nickname! (the server say this message at everybody...) Link to comment
[UVA]Bart Posted October 22, 2007 Share Posted October 22, 2007 this????on *:SIGNAL:mta.join:{mta.text $1 $2 Welcome $mta.nick($1,$2) $+ ! } it send in chatbox : 2 Welcome nickname! (the server say this message at everybody...) ok replace your bit with this on *:SIGNAL:mta.join:{ mta.pm $1 $2 Welcome $mta.nick($1,$2) $+ ! } Link to comment
SanZoR Posted October 23, 2007 Share Posted October 23, 2007 OMG THIS TOPIC IS SO LAME!!! Someone has problems with 3 line scripts This is so funny PS, what i posted works for 100% sure!!! OMGLOLWTF EDIT: I think this guy has problems with basic things. Maybe he tried to put this script INSIDE of script? You need to make new .txt file or .mrc file to use this. Else, take the join signal off, and insert script under mta.join line in GUS. So i suggest you just simply do new .txt file and put this script there, and load this to mirc. Link to comment
lil Toady Posted October 23, 2007 Share Posted October 23, 2007 OMG THIS TOPIC IS SO LAME!!!Someone has problems with 3 line scripts This is so funny PS, what i posted works for 100% sure!!! Exactly what you posted doesn't work for sure..... So who's lame after that? But what the others posted should work. As it should be mta.pm $1 $2 Welcome $mta.nick($1,$2) $+ ! Link to comment
SanZoR Posted October 23, 2007 Share Posted October 23, 2007 OMFG on *:SIGNAL:mta.join: {mta.pm $1 $2 Hello $mta.nick($1,$2) $+ , and welcome to this server! } Fixed, lol Link to comment
[FMJ]ParadoX Posted October 23, 2007 Share Posted October 23, 2007 OMG THIS TOPIC IS SO LAME!!!Someone has problems with 3 line scripts Yes you do. GG K THX BAI Link to comment
chrislabricole Posted October 23, 2007 Author Share Posted October 23, 2007 So, a have create a new file .mrc (script.mrc), i have put in : on *:SIGNAL:mta.join: {mta.pm $1 $2 Hello $mta.nick($1,$2) $+ , and welcome to this server! } With "Multi Theft Auto mIRC Admin v4.15 by Areon" I have included script.mrc by : General > Scripts... I have click on Load button and i have browser my script.mrc ==> * Scripts: "C:\Program Files\mIRC\script.mrc" loaded. There is the only file (script.mrc) included What the problem ? Thanks Link to comment
[UVA]Bart Posted October 23, 2007 Share Posted October 23, 2007 put that in and save it then reconnect to the server via mta:ma aeron and in the window if you have done it correctly it will say "My Script Reactivated" on *:SIGNAL:mta.connect { .timer 1 2 mta.text $1 My Script Reactivated } on *:SIGNAL:mta.join { mta.pm $1 $2 Hello $mta.nick($1,$2) $+ , Welcome To My Server. } Link to comment
chrislabricole Posted October 23, 2007 Author Share Posted October 23, 2007 your script say [20:57] My Script Reactivated but it not say "Hello Nick , Welcome To My Server." when a person connecting on my server... What the new problem ? Link to comment
Recommended Posts