Twisted spin the bottle!

By GlobalAnomaly on Nov 10, 2009

Well, one of my friends made a spin the bottle script, and it made me remember a script I saw on here a while back (http://www.hawkee.com/snippet/5746/) and I thought I'd try to make that persons idea work with a spin the bottle game.

on *:text:.Spin:#: {
  if (%Spin.Spinning != yes) {
    if ($sock(spin)) sockclose spin
    sockopen spin www.watchout4snakes.com 80
    set %Spin.nick  $nick(#,$r(1,$nick(#,0)))
    sockmark spin # %Spin.nick
    set %Spin.Spinning yes
    set %Spin.Spinner $nick
    set %Spin.chan #
  }
  else {
    .msg # The bottle is already spinning!
  }
}

on *:sockopen:spin: {
  sockwrite -n $sockname GET /creativitytools/RandomWord/RandomPhrase.aspx HTTP/1.1
  sockwrite -n $sockname Host: watchout4snakes.com
  sockwrite -n $sockname User-Agent: Spin the bottle
  sockwrite -n $sockname $crlf
}

on *:sockread:spin: {
  var %r | sockread %r | tokenize 32 %r
  if ($regex(%r,main_lblPhrase.+>(.+)</span>)) {
    tokenize 32 $sock($sockname).mark $regml(1)
    .describe %Spin.Chan %Spin.Spinner spins the bottle... %Spin.Spinner must $3- %Spin.nick
    set %Spin.Spinning no
    unset %Spin.Spinner
    unset %Spin.nick
    unset %Spin.chan
    return
  }
  if ($1 == </HTML>) sockclose $sockname
}

Comments

Sign in to comment.
GlobalAnomaly   -  Nov 15, 2009

lmao I thought of doing that, but after scripting it I grew lazy and didn't feel like changing annything T_T

Thank you though :P

 Respond  
Testor   -  Nov 15, 2009

should add a check for .spin, instead of always doing a randnick, if there's a name specified, set spinnick to that, not random. if not, use random.

Nice idea btw.

 Respond  
GlobalAnomaly   -  Nov 11, 2009

lmao >_>; It's one of a kind!

 Respond  
Ghost-writer   -  Nov 11, 2009

lol :> sockets in a spin the bottle, good job.

 Respond  
GlobalAnomaly   -  Nov 10, 2009

_>;...It makes no sense at all. It's fun. :P

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.