PtokaX forum

Archive => Archived 4.0 boards => Help with Lua 4 scripts => Topic started by: Themaster on 15 November, 2004, 19:23:14

Title: PM stuff
Post by: Themaster on 15 November, 2004, 19:23:14
what is the command to do in PM

like !help in PM
Title:
Post by: enema on 15 November, 2004, 19:54:59
prefix = "!"

function DataArrival(user,data)
if strsub(data, 1, 1) == "<" then
data=strsub(data,1,strlen(data)-1)
s,e,cmd = strfind(data,"%b<>%s+(%S+)")

if cmd == prefix.."your_cmd_here" then
user:SendPM(Bot, "your text here")

end
This should do it...
Title:
Post by: Themaster on 15 November, 2004, 20:05:27
sry . I can't use help in my script...it was that command i was looking for...
Title:
Post by: enema on 15 November, 2004, 20:17:06
well... It seems, that you want somekind of text to apear in PM if something happens... what should happen to make PM apear? you have choices like - function on timer, function on certain data arrival (if certain stuff in chat is posted, like cmd), function on user connect etc... so figure out what exactlly do you wish for and tell to others! Im sure, we can help you!

P.S., there was an error In my previos post. I edited it
Title:
Post by: Themaster on 15 November, 2004, 20:24:42
if i do +help in PM then is nothing happen