Originally Posted By: Riamus2
I made a very detailed script that allows for some really interesting control of that kind of thing and allows for easily adding a wide variety of types of commands and responses. However, it's not entirely ready for public use so I can't give it out at this time.

However, for a very basic setup, that is easy to edit, just do this:

Code:
on *:text:!*:#yourchannel: {
  if ($readini(mycommands.ini,$1)) {
    describe $chan $replace($readini(mycommands.ini,n,$1,$rand(1,$ini(mycommands.ini,$1,0))),#2#,$2)
  }
}


Then, create a file called mycommands.ini and format it like this:

Quote:

[!taco]
1=launches a delicious taco toward #2#
2=gives #2# a delicious taco
[!othercommand]
1=something
2=something else


#2# in the ini refers to word #2. In your example, that is the person's nick. If you need additional words, the $replace() can be updated to change #3# to $3, etc.

This isn't as configurable as is possible, but it's quickly set up and easy to change.

Replace #yourchannel with your channel name. And if you need commands that don't start with !, then remove that from the on text event and just use * instead of !*.



I could not get that to work, i must of been setting it up wrong frown


Got this error

* Invalid parameters: $readini (line 2, Taco.ini)

I put: on *:text:!*:#yourchannel: { part into taco.ini

then i did the other part in mycommands

I did change #yourchannel to the channel btw

Last edited by DJJIGGLER; 14/04/11 08:52 PM.