Im sorta confused why your using $rand and putting it has a identifier but shortest way of describing whatever to chan is..
on *:TEXT:*:*: {
if (lol isin $1-) { describe $chan $read(.\txt\lol.txt) }
; the script is self explanatory if lol is in any words when someone says it then it describes which is /me to $chan a line from txt\lol.txt
}
$read command usually already randomly picks it.. but if you want something otherwise just tell me a bit more explanation