| View previous topic :: View next topic |
| Author |
Message |
liloshell Voice
Joined: 25 Aug 2010 Posts: 2
|
Posted: Wed Aug 25, 2010 7:58 am Post subject: ansa.tcl does not work properly |
|
|
Hallo everybody,
Here I have a question regarding the recent deprecation of putdccraw and the sintyax of the new putdcc or putdccnow.
The script i was using contains :
| Code: |
proc ansa:send { str } {
set str "$str\n"
putdccraw 0 [string length $str] $str
}
|
I do not know the exact sintyax for use putdcc or putdccnow instead of
putdccraw.
here an eggdrop dcc message: Tcl error [ansa:request]: putdccraw is deprecated. Please use putdcc/putnow instead.
Please let me know.
Thank you everybody.  |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Wed Aug 25, 2010 10:01 am Post subject: |
|
|
Try reading the doc/tcl-commands.doc file..
| doc/tcl-commands.doc wrote: | | putnow <text> [-oneline]
| Description: sends text to the server immediately, bypassing all queues.
| Use with caution, as the bot may easily flood itself off the server.
| Options:
| -oneline: send text up to the first \r or \n, discarding the rest
| Returns: nothing
| Module: server |
_________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
liloshell Voice
Joined: 25 Aug 2010 Posts: 2
|
Posted: Fri Aug 27, 2010 2:23 pm Post subject: |
|
|
dear friend, you gave me a good spot to correct the ansa.tcl
using this code :
| Code: | proc ansa:send { str } {
set str "$str\n"
putnow $str -oneline
} |
instead of the older one the tcl is now working.
I am still testing if nothing is lost cutting the part of the code....
Thank's a lot.  |
|
| Back to top |
|
 |
MIODude Voice
Joined: 09 Oct 2006 Posts: 32
|
Posted: Mon Oct 04, 2010 8:59 pm Post subject: |
|
|
Sorry to resurrect an old thread - but I'm getting the exact same error.. but, i'm not using putdccraw! I'm using putnow
I tried his code below exactly as is, and I still get the same error.. I recently just updated the bot from 1.6.9 to 1.6.20. Is there something else that would generate this error?
| Code: |
proc ansa:send { str } {
set str "$str\n"
putnow $str -oneline
}
|
edit: AAAhh.. stupid me.. i had other scripts with the procedure called putnow that was calling the putdccraw command... ok.. fixed |
|
| Back to top |
|
 |
|