mIRC Home    About    Download    Register    News    Help

Print Thread
#259735 19/01/17 01:04 PM
Joined: Oct 2016
Posts: 22
W
wobY Offline OP
Ameglian cow
OP Offline
Ameglian cow
W
Joined: Oct 2016
Posts: 22
Is there any really good in-depth sockets tutorials on YouTube or in a written step-by-step pdf file? I've been reading the written one by the dev of mIRC but I just don't get it smirk Sockets are completely new thing to me and I learn faster by watching video so it would be awesome if there's a tutorial on YouTube. I'm trying to use the decapi for things like uptime and the latest tweet and youtube vid.

What I currently have(Not sure if its correct. This is all I know about sockets):
Code:
alias uptime {
  sockopen -e uptime decapi.me 443
}

on *:SOCKOPEN:uptime: {
  sockwrite -nt $sockname GET $+(/twitch/uptime.php?channel=woby_tv) HTTP/1.1
  sockwrite -nt $sockname Host: decapi.me
  sockwrite $sockname $crlf
}

Joined: Jul 2006
Posts: 4,130
W
Hoopy frood
Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 4,130
https://en.wikichip.org/wiki/mirc/sockets

Wikichip/mirc/ handles all mIRC Scripting topics except binary variables.


#mircscripting @ irc.swiftirc.net == the best mIRC help channel
Joined: Apr 2010
Posts: 969
F
Hoopy frood
Offline
Hoopy frood
F
Joined: Apr 2010
Posts: 969
If you are intention is to hit the Twitch API, you can use My JSON Parser to easily make requests and retrieve data out of the response.

I also have a few scripts to make dealing with twitch a bit easier called mTwitch(they depend on the json parser above). With mTwitch.Core.mrc and mTwitch.StateToTopic.mrc there are custom events raised through signal to indicate things like stream online/offline:

Code:
on *:SIGNAL:mTwitch.StreamOnline:{
  echo -a $1 is online
}

on *:SIGNAL:mTwitch.StreamOffline:{
  echo -a $1 is offline
}


I am SReject
My Stuff

Link Copied to Clipboard