|
| Author |
Message |
Calum Not Yet a God

Joined: 21 Feb 2004 Posts: 373 Location: england
   
|
Posted: Mon Mar 08, 2004 5:14 pm Post subject: |
|
|
| Code: | | if ($msg =~ /^invite (.*)/i) {<br />$self->invite('$1');<br />$self->sendmsg("Inviting $1, Remember this will only work if he/she is online");<br /> goto end;<br />} |
this doesnt seem to work if i type >invite the bot does nothing.
any ideas?
Edit : oops lol i forgot to end it with a ) after the /i lol
Edit : still doesnt work any ideas |
|
| Back to top |
|
 |
Calum Not Yet a God

Joined: 21 Feb 2004 Posts: 373 Location: england
   
|
Posted: Mon Mar 08, 2004 5:53 pm Post subject: |
|
|
| or *lazy* dot have to help :ph34r: lol :wacko: |
|
| Back to top |
|
 |
Keenie Almost An Agent

Joined: 31 Oct 2003 Posts: 1071
 
|
Posted: Mon Mar 08, 2004 5:58 pm Post subject: |
|
|
| Quote: | | $self->invite('$1'); |
take off the quotes around $1, single quotes meen literally '$1' and not the value of $1
also dont bump your posts, others are from other time zones, and some of even have lives and dont spend 24/7 refreshing looking for new posts |
|
| Back to top |
|
 |
jeanhub Almost An Agent

Joined: 14 Feb 2004 Posts: 1138
 
|
Posted: Mon Mar 08, 2004 10:23 pm Post subject: |
|
|
try this...
| Code: | | <br />if ($msg =~ /^invite (.*)$/) {<br />&send($self,"Remember this will only work if he/she is online.","$username");<br />$self->invite($1);<br />} |
|
|
| Back to top |
|
 |
mat007 Almost An Agent

Joined: 12 Jan 2004 Posts: 1375
   votes: 2
|
Posted: Mon Mar 08, 2004 10:35 pm Post subject: |
|
|
Ok heres an invite command for maya im going to ost a few maya commands in downloads..
| Code: | | if ($msg =~ /^invite (.*)$/) {<br />&send($self,"Inviting $1 please wait $username\nRemember this will only work if He or she is online!");<br />$self->invite("$1");<br />return;<br />} |
|
|
| Back to top |
|
 |
|