Untitled
public text v1 · immutableon *:TEXT:*:#: {
if ($rand(1,20) == 1) {
if ($0 < 3) { halt }
var %a = 1, %b = 1, %c = 0, %d
while (%a <= $lines(phrase.txt)) {
if ($numtok($read(phrase.txt,%a),32) >= 3) {
var %b = 1, %c = 0
while (%b <= $0) {
if ($istok($read(phrase.txt,%a),$gettok($1-,%b,32),32)) inc %c
if (%c == 3) { var %d = %d $+ $chr(9) $+ %a | break }
inc %b
}
}
inc %a
}
msg $chan $read(phrase.txt,$gettok(%d,$rand(1,$numtok(%d,9)),9))
}
}