Jump to content

MTAMA Scripting


Si|ent

Recommended Posts

cheers for that,

The thing I want really is so it lists the ingame players when you type !playing

I have written already a script that tells the stats of an individual, but I was wondering if it can LIST the players that are in game is all.

I dont know if it is actually possible but i think it probably is from the scripts I have modified.

Also I have kinda modified the shitlist script so you can kick people your server with your clan tag who arnt members. I have had some problems with this so I slapped this together:

alias mta.join { 
 echo -a $1- $mta.name($1,$2)
 if ($read(members.txt,w,$mta.name($1,$2))) { 
     mta.say $1 Welcome $mta.name($1,$2) to the clan server
 }
 elseif ( isin $mta.name($1,$2)) {
     mta.say $1 $mta.name($1,$2) is not a member of this clan.
     mta.kick $1 $2
 } 
}

You basically write a members.txt, putting all your members names in it and then the script kicks anyone who joins with your tag who isnt a member and welcomes people who are in the members list. And the replace the with you clan alias, be it in my case FMJ.

Dont know if this is useful to anyone but it is working well for me.

Also, if you want to reserve a particular name for a single IP address, say if you have a static one like me, then that can be done like this:

alias mta.join { 
 echo -a $1- $mta.name($1,$2)
 if ( isin $mta.name($1,$2)) && ($mta.ip($1,$2) == )) { 
     mta.say $1 Welcome message if you wish
 }
 elseif ( isin $mta.name($1,$2)) {
     mta.say $1 $mta.name($1,$2) wrong IP
     mta.kick $1 $2
 } 
}

This basically reserves that name for that ip, so you dont get imposters. Ive had some trouble with them aswell :P.

Hope someone finds these useful.

cheers

Link to comment
  • Replies 1.3k
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Yeah... it's pretty easy, I have quite a few clans added:

  echo -s $1- $mta.name($1,$2)
 if (Clan Tag isin $mta.name($1,$2)) {
   mta.say $1 That clan is not allowed here.
   mta.kick $1 $2
 }

That goes under mta.join. The name will be printed in the status window and then checked to see if it matches. It'd probably be more accurate if you'd add the clan tag's style too (in ULK's case, {ULK}).

You can replace mta.kick with mta.ban if you'd like.

Link to comment

download the mtama that is the mirc admin for MTA it's found on the downloads page. That will auto update after you load it and any script in the mirc root dir will be able to load into the mtama

MTA Mirc Admin = MTAMA

Idea :idea:

Is it possible to run a !stats style script that keeps a record between two ppl since they have been in game?

example:

Me and Wheelman have been in the server for 20 mins and 8 ppl are having a stubby war. I want to see how many times I have killed him/he has killed me so I type

!vrs 5 (5 being Wheelman's ID)

maybe even a little text for whoever is winning like _______ is owning

Seems possible but again I am so money at thinking crap up but I can't make it happen.... Im useless :oops:

Link to comment

Duffbeer, very easy to get it to pm you or even beep on a keyword or trigger, for instance under mta.txt

if (!admin isin $3-) {

/msg duffbeer admin required on server $1

}

Player types !admin youll get a message box appear saying you are required on server in whichever mtama slot

Link to comment

Idea :idea:

Is it possible to run a !stats style script that keeps a record between two ppl since they have been in game?

It is possible, but it isn't that easy. I've got a challenge script running at the Brakke student server, and the [NL] Calslaan 7-1 server(currently down).

I'd like to pass you the script, but it has a verry nasty bug which i want fix before publishing. Please try the function, so i can test it some more.

Comment are welcome!

Harry

Link to comment
yeah dan i told u how to do that ages ago...

The fmj servers have quite a few bans and reservations on it now :D

Oli no you didn't tell me that script ages ago so don't lie, you haven't told me any scripts. Oh and Andy is in NBK now.

Link to comment

okay can some one help me..

I want my script so that is says some thing when I give a ingame command..

got it this far:

alias mta.text {

if (($mta.name($1,$2) == myname) && ($3 == !summit)) {

mta.say $1 blabla.

but it says in the mirc window:

mta.say insuficiant parameters (or somthingl like that but then without the spelling mistakes..:))

And it doesn't work

what do i need to change..??

Edited by Guest
Link to comment

i got a script that i made

alias mta.join {
 mta.say 1 Welcome $mta.name(1,$2) to " ".
 mta.say 1 There are $mta.players(1)-3 / $mta.maxplayers(1) players currently on.
 mta.say 1 Current Mode is : $mta.type(1).
}

can you please optimize it and i want to add to this how many people are in game and who is out, The script does work to.

ex:

<3 Player in game and 4 out of the game.>

Thanks :D, youi can use the script to :D

Link to comment

can you please optimize it and i want to add to this how many people are in game and who is out, The script does work to.

Try using these methods:

alias mta.ingame {
 set %playerid 0
 set %count 0
 while ( $mta.maxplayers($1) > %playerid ) {
   if ( $ini( $+ $1 $+ .ini, ID $+ %playerid ) ) {
     if ($mta.game($1, %playerid) == 1) {
       %count = %count + 1
     }
   }
   %playerid = %playerid + 1
 }
 unset %playerid
 !return %count
}

alias mta.outgame {
 set %playerid 0
 set %count 0
 while ( $mta.maxplayers($1) > %playerid ) {
   if ( $ini( $+ $1 $+ .ini, ID $+ %playerid ) ) {
     if ($mta.game($1, %playerid) == 2) {
       %count = %count + 1
     }
   }
   %playerid = %playerid + 1
 }
 unset %playerid
 !return %count
} 

Link to comment
Talk from the server to irc

 alias mta.text {
 if ( ( !irc isin $3 ) && ( $4 != $null ) ) {
   /msg #channel Msg from server: " $+ $mta.name($1,$2) $+ : $4- $+ "
 }
}

i have put this in my remote and how can it say something from my server?

i dont get it ;)

Link to comment
Guest
This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...