Jump to content

MTA: Joining Help


Marty-Bond

Recommended Posts

Im Trying Ta Make This Script So MTAPlayer Will Be Kicked And The Messages Wont Appear, My Problem Is That It Kick`s EveryOne That Enter`s The Server!

on *:SIGNAL:mta.join:{

if ($mta.name($1,$2) == James-Bond) {

if ($mta.name($1,$2) == MTAPlayer) {

mta.say $1 || Welcome To The Bond Family RPG & DM Server ||

mta.say $1 || The Current Weather Is: $mta.weather($1,$2) $+ . ||

mta.say $1 || Market Status || Market: $readini(stockdata.ini,marketstatus,marketstatus)) || Resell: $readini(stockdata.ini,resellstatus,resellstatus)) ||

if ($readini($rpg.dir $+ rpg.ini,$mta.name($1,$2),Lead == Leader)) mta.say $1 || Bond Synce Accepted Welcome Bond Leader ||

if ($rpg.isclan($1,$2) == $true) mta.say $1 || Bond Synce Accepted ||

.timer 1 5 mta.msg $1 $2 For Script Help Type: !help

}

else mta.say $1 You Are Banned From Bond Forever You Shit Head. | .timer 1 1 mta.kick $1 $2

}

else mta.say $1 Please Change Your Name And Return | .timer 1 1 mta.kick $1 $2

}

Link to comment

first remove all the extra | and || 's ...use $chr(124) for | then apply some decent formating

like

if (bla == 0 )  {
 if (bla2 == 1)  {
 mta.text $1 bla
 }
} 

use [ code ] [ / code ]

then .. use proper variables and functions .. and come back if its not working :P

Link to comment

Ok I Did What You Said But Still Doesn`t Work...

if ($mta.name($1,$2) == MTAPlayer) {

mta.say $1 $chr(124) Welcome To The Bond Family RPG & DM Server $chr(124)

mta.say $1 $chr(124) The Current Weather Is: $mta.weather($1,$2) $+ . $chr(124)

mta.say $1 $chr(124) Market Status $chr(124) Market: $readini(stockdata.ini,marketstatus,marketstatus)) $chr(124) $chr(124) Resell: $readini(stockdata.ini,resellstatus,resellstatus)) $chr(124)

if ($readini($rpg.dir $+ rpg.ini,$mta.name($1,$2),Lead == Leader)) mta.say $1 $chr(124) Bond Synce Accepted Welcome Bond Leader $chr(124)

if ($rpg.isclan($1,$2) == $true) mta.say $1 $chr(124) Bond Synce Accepted $chr(124)

.timer 1 5 mta.msg $1 $2 For Script Help Type: !help

}

else mta.say $1 $mta.name($1,$2) Please Change Your Name And Return. | .timer 1 1 mta.kick $1 $2

}

Link to comment

CoZ, you can read codes... even if it isn't in code tags :P

Here is a good code:

[syntax=mIRC] if ($mta.name($1,$2) != MTAPlayer) {

mta.say $1 $chr(124) Welcome To The Bond Family RPG & DM Server $chr(124)

mta.say $1 $chr(124) The Current Weather Is: $mta.weather($1,$2) $+ . $chr(124)

mta.say $1 $chr(124) Market Status $chr(124) Market: $readini(stockdata.ini,marketstatus,marketstatus)) $chr(124) $chr(124) Resell: $readini(stockdata.ini,resellstatus,resellstatus)) $chr(124)

if ($readini($rpg.dir $+ rpg.ini,$mta.name($1,$2),Lead == Leader)) mta.say $1 $chr(124) Bond Synce Accepted Welcome Bond Leader $chr(124)

if ($rpg.isclan($1,$2) == $true) mta.say $1 $chr(124) Bond Synce Accepted $chr(124)

.timer 1 5 mta.msg $1 $2 For Script Help Type: !help

}

else {

mta.say $1 $mta.name($1,$2) Please Change Your Name And Return.

.timer 1 1 mta.kick $1 $2

}

}[/lua]

Edited by Guest
Link to comment
CoZ, you can read codes... even if it isn't in code tags :P

Here is a good code:

  if ($mta.name($1,$2) != MTAPlayer) {
   mta.say $1 $chr(124) Welcome To The Bond Family RPG & DM Server $chr(124)
   mta.say $1 $chr(124) The Current Weather Is: $mta.weather($1,$2) $+ . $chr(124)
   mta.say $1 $chr(124) Market Status $chr(124) Market: $readini(stockdata.ini,marketstatus,marketstatus)) $chr(124) $chr(124) Resell: $readini(stockdata.ini,resellstatus,resellstatus)) $chr(124)
   if ($readini($rpg.dir $+ rpg.ini,$mta.name($1,$2),Lead == Leader)) mta.say $1 $chr(124) Bond Synce Accepted Welcome Bond Leader $chr(124)
   if ($rpg.isclan($1,$2) == $true) mta.say $1 $chr(124) Bond Synce Accepted $chr(124)  
   .timer 1 5 mta.msg $1 $2 For Script Help Type: !help
 }
 else {
   mta.say $1 $mta.name($1,$2) Please Change Your Name And Return.
   .timer 1 1 mta.kick $1 $2
 }
}

Nice It Works Now Thank You.

Link to comment
yeah ok...

Did you really writed that RPG for GUS? Doesn't think so :P

The difference between == and != is something else than VC and SA ;)

its based on tommis x14, and what got added and changed isnt really rocket science .. but i did add a lot :o

Link to comment
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...