TODO: * add tree-like GUI for actions et al (like wintin, but with more options) * #action has more options (variable as priority; force end of line, recursive --toggle all or 1 line only) * #path et al * parse variable et al smartly -- currently backslash \ is parsed more than once * Do we need "chat" command introduced by tintin++1.83 ? * #buffer command, will send critical commands in a row in ONE buffer to avoid break of the commands by lag. * action/variable/alias et al add one more field: origin, this will help organizing the scripts * add more ansi-escape support, fix the color in substitute/highlight 1.83d1 (4/14/2006): * new #slow2 command, default #purge won't purge queued cmds by #slow2 * multiple log files. Now one could, e.g., keep 1 long log, while use other log files to make sophisticated robot. 1.83c4 (4/3/2006): * fixed a bug on #toggle (onoff[] index overflow) * Added new option: #toggle TCP_NODELAY to enable/disable Nagle algorithm. For now, yTin defaults to disable Nagle algorithm. Please give feedback if you experience any differences. 1.83c3 (3/27/2006): * Added #toggle message delimiter * fixed a small bug for the unicode version, released the unicode version for desperate users only. Not extensively tested (and there are a few problems). 1.83c2 (10/19/2002): * fixed buggy version 1.83c1 * fixed some buffer overflow (not all for sure) * new command: #system2, for windows only 1.83b (8/29/2002): * new command: #while 1.83a5 (4/19/2002): * BUFFER_SIZE increased to 8192; Windows version: stack size increased from 1M to 4M, hopefully less stack overflow. * #bell has more options, see #help bell (update your tt_help.txt) * fixed a bug of get_arg_in_braces() due to handling {{xxx}} * fixed function, now can do: @myfunc{{this is arg1} {this is arg2} arg3} * #write/#writesession commands now also write functions * {xxx} command is now interpreted as xxx. * #log command now have append mode (with the + option in the 2nd parameter) * Added macro for meta keys under Unix. * Added pseudo variable $_OS (WIN32 or UNIX). 1.82g1 (7/25/2001): * Web links help->"Check new version" et al were changed accordingly in yTin * http://ytin.sourceforge.net is updated and is now the office homepage * Added more features for readline (#help split) * tab complete now recogonize variables * Welcome Vasantha Crabb as a new developer! Now yTin CVS at http://sourceforge.net is up and working. All are welcome to join the open source development of yTin. 1.82f4 (7/22/2001): * fixed a minor bug on #toggle * fixed bugs on tabs' location (hopefully) * fixed the last mem-leak (in rltab.cpp ==> TinTin++ need similar fixes) * bug fix on text wrap introduced by 1.82f0 * added links to homepage, online help to windows version 1.82e6 (6/11/2001): * some hacks on Unicode version * possibly fixed the color bleed bug caused by scrolling for windows version * fixed #purist bug in windows version, add into help * windows version: increased the space for #setprompt status bar (hard coded) * added fix to treat tabs in com file as space, also made CR-LF.sh nicer (thanks: ovema@sol.no) * set global action ignore to TRUE before quit yTin to avoid some dead loops. * added readline.txt for trouble-shooting installing on unix. * changed tintin_puts(.., NULL) behavior, now most broadcasting messages using tintin_puts() will be actioned for each session (WARNING: actions on these may crash yTin, report to me if u see any.) 1.82d0 (12/19/2000): * updated tt_help.txt for #tabsave command. * addopted fixes by Vasantha Crabb . Thanks, Vasantha! [btw, Vasantha compiled it under Apple Mac OS X UN*X (Darwin 1.2 codebase)] * fixed ansi bugs on split mode * parse variables on #retab and #tabsave command. 1.82c8 (12/12/2000): * added new toggle option: #toggle skiptelnetseq, see new help file for details. * changed default newline back to "\r\n" * fixed to make it work with gcc2.96 * fixed bug from #zap and #end (Brandy1 reported how to repeat the bug, THANKS!) * #sysecho, #log command now will try to create the last layer of directory for u * fixed the bug on #help introduced by 1.82c3 * new #stripansi command (help file updated) * setprompt will strip ansicolor et al 1st * #toggle big5 1 will handle BIG5 code correctly. 1.82b4 (11/9/2000): * history using !text was in reversing order for windows version, fixed. * merged TinTin++'s configure/make fixes. * updated tt_help.txt (english version). Please post any un-documented changed so I will keep help file updated. * changed #forall command, use delimiter instead ',' now. NOTE: one need to change old rc files to reflect the change * added #toLower, changed help.cpp so that mixed case commands can find help too * input bar now resizes with main window (thanks: newtype ) * added ".SUFFIXES: .cpp .o" into Makefile.in (Thanks: Roman Emelyanov ) * !string is now implemented in windows version (for history expansion) * added an option to keep the last input line (zMud behavior) 1.82a3 (9/4/2000): * fixed the bug on #gag command (thanks Petter), also fixed #substitute (c.f. http://pub4.ezboard.com/fytinytin.showMessage?topicID=109.topic) * #toggle speedwalk 1 will have old TinTin++ behavior, #toggle speedwalk 2 will be the yTin "smart" option, treat single se, sw as 1 direction rather than {s;e} and {s;w} .... * added $HOME as pseudo variable, it is environment variable of HOME * added #syscat command (like #sysecho, try to simulate #system echo and #system cat for convenience under windows) * Wow! Perl is now integrated smoothly in yTin under windows. No stdout though, nor can you do redirection. Use files to store results! TRY: #system perl hello.pl, in hello.pl, write sth to a FILE and check it! I consider this worth to jump from 1.80 to 1.82. 1.80o3 (8/11/2000): * when #toggle raw 1, will negotiate terminal type, some unix hosts requie this * fixed the LAST mem leak, o3 version is very stable now, although I met 1 crash * fixed the bug for gag, now #gag {MSG} == #sub {MSG} {}, makes more sense, eh? * changed all tt++ files to cpp files, more error checking to avoid bugs, and (hopefully) fix all the crashes due to session changes among these functions. (Example: #action {MSG} {#zap} will no longer crash ...) 1.80n7 (7/28/2000): * fixed a bug that yTin won't show single "." (old #substitute, #gag need to be changed later) * now arrow keys are enabled for #toggle raw 1" mode * added an option to treat ^[[1m as BOLD or HIGHCOLOR (windows only) * #toggle raw (windows only), interactive mode, to avoid frequent usage of #raw in some case (some BBS, or, potentially, vi, emacs ...), there is a menu command to toggle it off (have not find an ideal hot key for this yet, suggestion?) updated help file. * fixed wrong width (by 1) when ansi-colors involved * NEW: #raw command, send bytes without newline at end. Sample: #func chr {#chr _ {%%0};#res $_} Now #raw @chr{4} will send ctrl-D, #raw @chr{27} will send ESC, #raw @chr{1}d to send ctrl-A, d ... * bug fix: now will be able to do more like telnet, try to use it on bbs, telnet ... * get rid of the part of code that requires wininet.dll and rasapi.dll. Hate the idea that one has to have IE and RAS installed to use yTin. * #substitute comes b4 #substring now, i.e., #sub == #substitute not #substring. * #ping2 command, pseudo ping command for systems that support TELNET option TIMING (MudOS and most unix hosts support it, while some muds do not, use $_msec for self-made ping2) * #telnet command (see updated help file) * pseudo variable $_time (same as $time, just a better name since it is global) $_msec ($time in millisecond) * fixed a bug of #ctoi (#ctoi is for Chinese GB code only) 1.80m7 (6/15/2000): * #boss 0 will only hide the current window (windows version) * fixed a crash bug: #al tl tell;tl x a{b { * fixed a bug that does not parse variables in #highlight * added an experimental command #GBfilter, no documentation yet, and eventually will get rid of it and replace it with a generic command #filter * fixed a bug that shows an extra newline * fixed bugs for #ifexist and #ifmatch, thanks "Petter". * fixed a bug for finding default tintinrc for windows version. * #version command now also forces passwd mode off (mud like medievia only begin the remote_echo on, does not show remote_echo off afterwards, need manually turn if off -- for create new char only, a bug?) 1.80l10 (5/21/2000): * Added new option to check internet (winsock mess up with ytin when modem is dialing, toggle checkInternet to prevent crash). if u see any #debug message showing no Internet while u actually have, post in ytin discussion board please! * #action {test%0} {#var test {%%0}} works for %0 like ^[[1;32m now fix in 1.80g and h made {#var test %0} work only. Now both shall work (test!) * #delimiter now do not echo if it is unchanged * added YoonChan Jhi proposed fix for syserr() in util.c * the commands loop, geti, strncmp now do math calculation in the interger part e.g.: #loop {1, $l+6} {commands ...} works now * fixed a small unpleasant part in math calculation (1.80l1 is a buggy version) * for ansi colors, added complimentary color part (- in the dialog) * handles #if {[$str=[xx]]} now, test it! * added configuration for 16 ansi colors for windows version 1.80k4 (5/1/2000): * #cr now take arguments, for change the newline behavior (e.g., \n, \r\n) * finally fixed a winsock blocking bug, NEXT: trying to fix free(ses) * fixed an infinite loop for windows version when copy/paste * single ne, nw, se, su, et al, under speedwalk, will not be interpreted, no need /alias ne {northeast} now (it was from my old code 1 yr ago, but somehow this feature was not added later) 1.80j1 (3/26/2000): * fixed windows version clipboard error * fixed some bug for #textin, will input LONG line as 1 line now * new commands #decrypt, #encrypt, see new help file for details * #boss for windows, now can supply a new password for security 1.80i7 (3/19/2000): * fixed the most ansi bugs for windows, now it is easier to add more ANSI/vt100 compatible commands in the near future * added tab completion for windows version * added rename, remove, fputs, fread, fwrite for file operation * added an option for windows version, when paste, replace all (single or pair) by the specified string (default is ) * #var {x} {} now set the string x represented to "" 1.80i (3/9/2000): * added fclose, fopen, fseek, feof, fgets, together with sysecho, will be OK for basic file I/O now! (updated tt_help.txt) 1.80h1 (2/28/2000): * fixed a long existed bug of variable like $a1 * changed the style of #getitemnr, now index starts from 0, consistent with all other similar functions (hope this won't cause too much trouble) 1.80h (2/25/2000): * new command: #delimiter , for #getitemnr, #getlistlength * finally decide to get rid of redundant commands: postpad, prepad, removestring, getvarvalue, random, ifstrequal (redundant commands make the learning curve longer for newbie) * fixed some un-satisfactory features introduced since version 1.80g 1.80g (2/18/2000): * new: al2variable, var2alias (see new tt_help.txt) * made satisfactory improvement on action/alias et al example: /al {test} {/var a1 %1;/var a2 %2;/var a3 %3;/var a4 %4} try to compare the result with old versions: test 1 {2 2;2} 3 test 1 {/if {a} {b}} 3 1.80f1 (2/13/2000): * updated some helps in tt_help.txt * re-arranged status/toolbar, #setprompt now set message on satus bar for windows * showme command now works in files again (good for debug) 1.80f (2/8/2000): * added macro/unmacro commands for windows (Unix with readline is underway) * fixed a small memory leak 1.80e3 (2/1/2000): * yTin now handles termtype for MudOS smartly, if necessary, #version command will send termtype again at same time 1.80d (1/31/2000): * ytin handles some telnet sequence NOW! as a result, can telnet to regular telnet port, and no need to worry about DEFAULT_PW_TEXT to disable showing password * fixed a bug on #sysecho 1.80c (1/25/2000): * added a feature that will make use number as session name OK ##2 forces ytin check session name, #2 means twice. 1.80c (1/19/2000): * hopefully fixed -O2 option broken problem for redhat6.1, thanks for tag (liaody@mit.edu) * added Is_Alnum() macro, instead of '_' || isalnum(). isalnum()'s behaviour is unpredicted for different platform/locale * fixed a bug to cause crash due to #tickoff when it is no longer in queue (#purge command did that, now won't) * valid_session(ses) double checks valid session, shall prevent a lot of crashes (if crashes still exist, most likely can be fixed with this double check. Other crashes: buffer overflow ..) * fixed a bug on #substr, make it more compatible to Perl's convention * fixed a bug on queue due to change of queue recursively (crash bug) New in yTin1.80b03 (1/11/00): * new #slow command, different than zMud's idea. #slow 5 will send 5 commands and wait for server's packets, ... (also, it is a mode, like #pause do) #slow + #pause is quite good balance for most mud, and can be tuned to satisfy different lag. * purge now take arguments, default is 1, purges the pending commands by #pause, #sleep and #slow, #purge 0 only purges #slow and #pause New in yTin1.80b02: * 1/6/00: enhanced #echo function. show more infomation when toggle echo true. Moreover, when toggle echo 2, will show raw action instead of replacing %1, %2 ... New in yTin1.80b01: * I found out the TinTin++1.75 did not enable Happy's functions. Now it is enabled, and fixed so that it will work on yTin's fixed parsing. * added 3 c-style commands: strlen, strrchr, strstr and 3 perl-style commands: chr, ord and substr. I think string operations is thus complete, while some functions like #ifstring, #postpad, #prepad is obsolete. NOTE: there is an obvious difference between tintin's commands and regular functions. I feel it is convenient to adopt the well known syntax like: #strstr {this is string1} {str}, while assign the return value to perl style default variable $_. Like Happy pointed out b4, it is also convenient for users define: #function {strstr} {#strstr {%%1} {%%2};#result $_}. * enhanced #boss command (for Windows only). Hide all ytin windows. To show them all again, just start another instance of ytin. Features in my TinTin++1.76a2 (as I posted on this board before): Major fixes: * added commands: #sleep, #pause, #purge. With #sleep (people used to use #system sleep to handle certain things...), one can actually add infinite customer made ticks. #pause can buffer the commands and send it out in an time delay, while #purge is possible to delete pending commands that not yet sent out. * fixed parsing errors, {#math x $x+1;#math x $x+1} now gives x=x+2 instead of only +1. This fix is one of the debating one, since Happy argued that this will cause some old tintin codes broken. * fixed the long existing bug of "missing actions on broken packet". Namely, if the packets arrives as "THIS I" + "S A TRIGGER MESSAGE", it was not getting attention from action {THIS IS A TRIGGER MESSAGE}. This does not fix some confusing when a broken line might give action to two different priority (and, this cannot be fixed unless we have an option to action sth before newline, or force it to wait for newline). * added "dummy session", when port is 0, the session is a faked one. Useful for auto-connection, a feature long waited. Minor fixes: * fixed some memory leaks. It is nice that MSVC will warn u of this under windows. :) * read_file now handles multi-line for 1 command, skips newlines also, read_file was skipping things after ; on 1st line * fixed textin, won't crash when file too large * added lots of necessary features to make variables works on most tintin commands, like #system, #ticksize .... * made most of toggle like commands take abosolute value as well (i.g., #speedwalk 0, #message var 0), added a new #message read. * added a new command toggle, it does both set and toggle. Intention of this to use this to replace other toggle like command (#toggle speedwalk 0), also added other toggles: #toggle stripcolor will decide if actions will strip colors b4 parsing. * added a #cd commands, to handle chdir or pwd. * fixed math operation's priority, old TinTin's math priority made things like + higher than * (cannot remember it clearly now, but I remember I fixed things like this). also + and -'s priority is not the same! This makes (a-b+c) to do (a-(b+c)). Added a new operator //, which meant to be % (module), but it is not only confusing to code this, but also confusing to use it, IMO, to handle whether it is %0 ... %4 or module(a,4), and how many %%'s to add in {}'s. :D * added smart handling of variables like $a4, $a4.data, no need to write as ${a4}.data in this typical case (this fix was in my version of TinTin++ prior than Happy's fix, and I think happy's fix is complete, while still convenient not to add {} for most cases. ofcuz, ${a4}.data still works, as it should be. * added global variables. variables started with '_' are all global variables (except $_, I kept it to be local variables for each session, as a default variable, of Perl style.) * system now take a few optional arguments. This fix meant to be mainly for use it under Windows. I think need some votes on how to handle the default, and if some1 is good at Windows programming, I need suggestion/fixes on this as well. (default option now appends >> tintin.out to system's command, so the output is be able to show under Windows, and actually actionable under both Unix and Windows. But ack, it causes trouble if u want to do things like #system vi myfile. Have to use #system {vi myfile} {1} in this case). * added != for string comparison #if {[xx!=yy]}, also make un-assigned variables be smart to act like integer 0 or string "".