Need help
 

News:

29 December 2022 - PtokaX 0.5.3.0 (20th anniversary edition) released...
11 April 2017 - PtokaX 0.5.2.2 released...
8 April 2015 Anti child and anti pedo pr0n scripts are not allowed anymore on this board!
28 September 2015 - PtokaX 0.5.2.1 for Windows 10 IoT released...
3 September 2015 - PtokaX 0.5.2.1 released...
16 August 2015 - PtokaX 0.5.2.0 released...
1 August 2015 - Crowdfunding for ADC protocol support in PtokaX ended. Clearly nobody want ADC support...
30 June 2015 - PtokaX 0.5.1.0 released...
30 April 2015 Crowdfunding for ADC protocol support in PtokaX
26 April 2015 New support hub!
20 February 2015 - PtokaX 0.5.0.3 released...
13 April 2014 - PtokaX 0.5.0.2 released...
23 March 2014 - PtokaX testing version 0.5.0.1 build 454 is available.
04 March 2014 - PtokaX.org sites were temporary down because of DDOS attacks and issues with hosting service provider.

Main Menu

Need help

Started by ?StIfFLEr??, 24 April, 2009, 07:06:11

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

?StIfFLEr??

Can anyone help me understand the strings of lua.
Like example what does this stands for i am not able to get "(Data, "%b<>%s(%S+)%s+(%S+)|")"

Madman

Well, I asume that this line is found in ChatArrival.
_,_,A,B = string.find(Data, "%b<>%s(%S+)%s+(%S+)|")

%b<> is anything between <>, this would be the nick of the user sending the chat
%s is a space, %s+ is one space or more.
%S+ is anything else then space.
| (endpipe) is the end of the incomming data/line

So the statemet would only be correct if someone wrote something like this:
test this
nice string
catch me
!cmd arg

A would be test,nice,catch or !cmd
B would be this,string,me or arg

It would fail on
!test arg1 arg2
this is my text
We suffer in silence, we lurk in the shadows, we kill in the night
Site currently down, ETA of returning online is 2099 ;p

?StIfFLEr??

Thanks Mutor and madman you both are just awesome.
Sorry for not posting the full script because it did not had any credits in it ..
So i thought it would be wrong in posting that script here.
I was trying to learn through your and madman's script and understanding them but comparing it with other scripts.
I know it sounds ridiculous but it made me learn a bit of it will surely look forward to the link you provided mutor.
Thanks a Lot mutor and madman you both have been a great help in learning whatever i have learnt so far.

SMF spam blocked by CleanTalk