TinTin++ Mud Client The TinTin++ message board

 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
TinTin++ Mud Client

help of script

 
Post new topic   Reply to topic    The TinTin++ message board Forum Index -> Finished Scripts
View previous topic :: View next topic  
Author Message
afee



Joined: 17 Jul 2011
Posts: 24

PostPosted: Sun Jul 17, 2011 3:03 pm    Post subject: help of script Reply with quote

I have problem to post on help section
i have
Code:
#action {Znajdujesz %9.}


and when i check #echo %9

i get something like that
Code:
Znajdujesz jasnofiot.
#echo %9
         �
Back to top
View user's profile Send private message
Scandum
Site Admin


Joined: 03 Dec 2004
Posts: 3770

PostPosted: Sun Jul 17, 2011 4:04 pm    Post subject: Reply with quote

Probably best to use: #showme {%9}

If the mud uses UTF-8 you could try: #config {CHARSET} {UTF-8}
Back to top
View user's profile Send private message Send e-mail
afee



Joined: 17 Jul 2011
Posts: 24

PostPosted: Mon Jul 18, 2011 10:13 am    Post subject: Reply with quote

still this same
Back to top
View user's profile Send private message
Scandum
Site Admin


Joined: 03 Dec 2004
Posts: 3770

PostPosted: Mon Jul 18, 2011 9:07 pm    Post subject: Reply with quote

Alright, what is it supposed to display?
Back to top
View user's profile Send private message Send e-mail
afee



Joined: 17 Jul 2011
Posts: 24

PostPosted: Tue Jul 19, 2011 9:33 am    Post subject: Reply with quote

ok have something like that
MUD give
Code:

You find smt like that.


Script have
Code:

#action {You find %9.}
  {
       #list {smth}{find}{%9}{variable};
       ......
       .......
  }


%9 must return "smt like that"
Back to top
View user's profile Send private message
Scandum
Site Admin


Joined: 03 Dec 2004
Posts: 3770

PostPosted: Tue Jul 19, 2011 8:33 pm    Post subject: Reply with quote

That's not a whole lot to go by.

If you can create a small script that reproduces the problem I can look into it. The following works for me and sets $result to 2:

Code:

#list smth create {smt like this} {smt like that} {smt like what}

#action {You find %9.}
{
    #list {smth} {find} {%9} {result}
}

#showme {You find smt like that.}
#showme {$result}
Back to top
View user's profile Send private message Send e-mail
afee



Joined: 17 Jul 2011
Posts: 24

PostPosted: Wed Jul 20, 2011 2:21 pm    Post subject: Reply with quote

This is all script
Code:

#list {ziola_n}{create}{Adanat}
#list {ziola_o}{create}{maly szorstki lisc}
#list {ziola_u}{create}{brak danych}
#list {ziola_z}{create}{maly szorstki lisc}
#list {ziola_lm}{create}{male szorstkie liscie}
#list {ziola_w}{create}{brak danych}

#list {ziola_n}{add}{Aesuryn}
#list {ziola_o}{add}{tajemnicze ciemnoniebieskie ziolo}
#list {ziola_u}{add}{zjedz}
#list {ziola_z}{add}{tajemnicze ciemnoniebieskie ziolo}
#list {ziola_lm}{add}{tajemnicze ciemnoniebieskie ziola}
#list {ziola_w}{add}{Łaki bretonskie}

........

#action {Znajdujesz %6.}
  {
   #regexp {Znajdujesz %6.}{Znajdujesz {.*}.}{#variable {znajdz} {&1}};
   #sh {$znajdz};
   #sh {{ziola_z}{find}{$znajdz}{add}{zioloz}};   
   #list {ziolo_z}{add}{find}{$znajdz}{add}{zioloz};   
   #list {ziolo_n}{get}{{$zioloz}}{%2};
   #list {ziolo_o}{get}{{$zioloz}}{%3};
   #list {ziolo_z}{add}{get}{{$zioloz}}{%4};
   #list {ziolo_w}{get}{{$zioloz}}{%5};
   #showme {<070>+--------------+----------------------};
   #showme {<070>| Nazwa        | %2};
   #showme {<070>| Opis         | %3};
   #showme {<070>| Zastosowanie | %4};
   #showme {<070>| Wystepowanie | %5};
   #showme {<070>+--------------+----------------------};
   }


when mud give
Code:

Znajdujesz tajemnicze ciemnoniebieskie ziolo.


$zioloz could return 2

but not return is any problem to find more than 1 word in row?

EDIT:

OK WORK CORECT
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    The TinTin++ message board Forum Index -> Finished Scripts All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Get TinTin++ Mud Client at SourceForge.net. Fast, secure and Free Open Source software downloads Get TinTin++ Mud Client at SourceForge.net. Fast, secure and Free Open Source software downloads
TinTin++ Homepage

Powered by phpBB © 2001, 2002 phpBB Group