mIRC Homepage

Need help.

Posted By: facelessrage

Need help. - 13/12/05 09:29 PM

Okay, I need some help...I really want to make a script but I am a complete idiot when it comes to mIRC scripting.

Basically I want it so that when someone types : !setup mapnamehere -- It executes this command.../rcon map mapnamehere...

But the thing is is that their are different maps...so like someone could type !map lol.bsp and it would execute /rcon map lol.bsp

Any help is highly appreciated..
Posted By: schaefer31

Re: Need help. - 13/12/05 10:32 PM

This will work but it does not validate that the map exists. The only error checking I added was to check that the map must be more than 4 characters and the last 4 characters must be ".bsp"

Code:
on 1:TEXT:!map *:[color:red]#YourChannel[/color]:{
  if ($len($strip($2)) > 4 && $right($strip($2),4) == .bsp) { rcon map $strip($2) }
}
Posted By: facelessrage

Re: Need help. - 14/12/05 06:34 PM

I really just need this a little more simple. If I do !map blah the script doesnt recognize it because it doesnt have .bsp after it....and when I do the !map blah.bsp...it sends the command /rcon map blah.bsp.bsp....but the thing is I just need the /rcon map blah

The server doesnt recognize it if it has .bsp after it...just need the !map whatever and it does /rcon map whatever.

Thanks alot
Posted By: NeUtRoN_StaR

Re: Need help. - 14/12/05 07:14 PM

the command your referenceing the whole rcon thing
really needs to be entered in the console portion of a valve game like css
or if you arent familiar with it theres a program called hlsw that allows you to enter rcon commands monitor the server and it even has its on irc bot that relays stats into the irc channel you designate

so... what you really need is mirc to take what you say and enter it into hlsw
which im assuming you use, if you dont you should
i could be wrong and maybe have overlooked something
anyways good luck
Posted By: facelessrage

Re: Need help. - 14/12/05 07:38 PM

I actually have a script for IRC that connects and sends RCON commands through irc...thats the whole ./rcon alias thing laugh

I just need it to be triggered on !map

Thanks alot...
Posted By: genius_at_work

Re: Need help. - 14/12/05 07:42 PM

Try this:
Code:
on *:TEXT:!map &:#yourchannel:rcon map $remove($strip($2),.bsp)


If someone types !map blah.bsp it will send the command /rcon map blah If they type !map blah it will send /rcon map blah If they type !map the.cool.map.bsp it will send /rcon map the.cool.map

-genius_at_work
Posted By: facelessrage

Re: Need help. - 14/12/05 08:14 PM

Do you have a Paypal account Genius? Im sending you 5 dollars.

Thanks a load.
Posted By: genius_at_work

Re: Need help. - 14/12/05 10:20 PM

:P

-genius_at_work
© 2019 mIRC Discussion Forums