home *** CD-ROM | disk | FTP | other *** search
/ Treasure Hunt 2001 PRESSKIT / TH2001_PRESSKIT.iso / demo / scol_install / Partition / comm / comapi2.pkg < prev    next >
Encoding:
Text File  |  2000-09-18  |  765 b   |  38 lines

  1. /* Comapi2.pkg */
  2.  
  3. defcom skip=skip;; 
  4. defcom ChatACK = ChatACK S;; 
  5. defcom ComConnected = ComConnected S;; 
  6.  
  7. fun APIcnx ()= 
  8. {
  9.   _on _channel skip []; 
  10. };; 
  11.  
  12. fun __ChatACK (nick)= 
  13.   _on _channel ChatACK [nick]; 
  14.   _on APIchn ComConnected [nick]; 
  15.   _status strcat strcat strcat nick " on IP " _channelIP _channel " opens a new chat window (API)."; 
  16.   _load "comm/comphone.pkg"; 
  17.   _load "comm/comchat.pkg"; 
  18.   _load "comm/comapi3.pkg"; 
  19.   _script mkscript InitChat [nick ChatRoom]; 
  20. };; 
  21.  
  22. defcom ComClosed=ComClosed;; 
  23.  
  24. fun __ChatNACK (nick)= 
  25.   _closechannel; 
  26.   _on APIchn ComClosed []; 
  27.   0 
  28. };; 
  29.  
  30. fun _connected ()= 
  31.   _on _channel skip []; 
  32.   _SETfocus mainw; 
  33.   _on _channel ChatStart [_GETtext nickname]; 
  34. };;
  35.