Post reply

Warning: this topic has not been posted in for at least 120 days.
Unless you're sure you want to reply, please consider starting a new topic.
Name:
Email:
Subject:
Message icon:

Verification:

shortcuts: hit alt+s to submit/post or alt+p to preview


Topic Summary

Posted by: morbid
« on: February 16, 2011, 04:19:06 pm »

Ah yes, only used sockets for "tinyurl" link create and display. Nice scripts. BTW "FMyLife" rocks :D

Thanks, and yes FML does rock. I also have sockets for text from last night and I fail at pick up's


Nice Script, Your a hell of a scripter xD


Thank you Jane.
Posted by: Jane
« on: February 16, 2011, 02:35:31 pm »

Nice Script, Your a hell of a scripter xD
Posted by: King_Hual
« on: February 15, 2011, 08:51:39 pm »

Ah yes, only used sockets for "tinyurl" link create and display. Nice scripts. BTW "FMyLife" rocks :D
Posted by: morbid
« on: February 15, 2011, 06:02:45 pm »

So Yes I'm really into inputs and aliases.
Screw dialogs.

Also, I am very fond of the sites such as Bash.org
and Fmylife.com

Here are a couple of inputs (and text) sockets

Bash
Code: [Select]
on *:input:*:if ($regex($1-,/^\+bash?\s?(\d+)?$/iS)) $iif($regml(1),$bash(#,$v1),$bash(#))
on $*:text:/^~bash?\s?(\d+)?$/iS:#:$iif($regml(1),$bash(#,$v1),$bash(#))
alias -l bash {
  if (!$($+(%,f,$1),2)) { inc -u4 $+(%,f,$1)
    if ($sock($+(bash,$1))) sockclose $+(bash,$1)
    sockopen $+(bash,$1) www.bash.org 80
    sockmark $+(bash,$1) $+(/?,$iif($2,$2,random)) msg $1 4,1[14,1Bash4,1]
  }
}
on *:sockopen:bash*: {
  sockwrite -n bash* GET $gettok($sock($sockname).mark,1,32) HTTP/1.1
  sockwrite -n bash* Host: $+($sock($sockname).addr,$str($crlf,2))
}
on *:sockread:bash*: {
  var %bash | sockread %bash
  if ($regex(%bash,/<center.+>(Quote.+does not exist.)<\/font>/)) {
    $gettok($sock($sockname).mark,2-,32) $regml(1)
    sockclose $sockname
  }
  elseif ($regex(%bash,/^(<p class=.+>|)(\S.+)(<br \/>|<\/p>)/)) {
    $gettok($sock($sockname).mark,2-,32) $replace($regml(2),&lt;,<,&gt;,>,&quot;,",&nbsp;,$chr(32),&amp;,&)
  }
  if ($regml(3) = </p>) { sockclose $sockname }
}


and for FMyLife
Code: [Select]
on *:input:*:if ($regex($1,/^\+fml$/iS)) $fml(#)
on $*:text:/^~fml$/iS:#:$fml(#)
alias -l fml {
  if (!%f) { inc -u4 %f
    if ($sock(fu_ck)) sockclose fu_ck
    sockopen fu_ck www.fmylife.com 80 
    sockmark fu_ck msg $1 14,1[4,1F My Life14,1]
  }
}
on *:sockopen:fu_ck: {
  sockwrite -n fu_ck GET /random HTTP/2.0
  sockwrite -n fu_ck Host: $+($sock(fu_ck).addr,$str($crlf,2))
}
on *:sockread:fu_ck: {
  var %fuc_kit | sockread %fuc_kit
  if ($regex(%fuc_kit,/<a href=.+fmllink">(Today.+FML)<\/a><\/p>/)) {
    $sock(fu_ck).mark $regsubex($regml(1),/[^<]*>|<[^>]*>|<[^>]*|&quot;/g,$chr(32))
    sockclose fu_ck
  }
}

The commands are as followed

For you it would be +(trigger) here
For someone else it would be ~(trigger)

I.e.
Quote
:|: 12:01 :|: |@ morbid |  +bash
:|: 12:01 :|: |@ morbid | [Bash] <ck3k> i wonder how people with parkingson's disease wipe their ass
:|: 12:01 :|: |@ morbid | [Bash] <ck3k> that must be a **** trial
:|: 12:01 :|: |@ morbid | [Bash] <ck3k> i bet muhammed ali has a whole staff hired just to do that
and

Quote
:|: 12:01 :|: |@ morbid |  +fml
:|: 12:01 :|: |@ morbid | [F My Life] Today, I went to a family dinner. While waiting to be seated, a guy walked by and I looked to see if he was hot. Then my grandma yelled, Get your eyeballs back in your head and quit staring at boys! The whole restaurant heard her. Including the guy. And yes, he was hot. FML