Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- alias -l getsite {
- if (!$1-) || (!$isid) { return 0 }
- var %com = getsite_ $+ $rand(1,1000000)
- .comopen %com MSXML2.SERVERXMLHTTP.6.0
- noop $com(%com,Open,1,bstr,GET,bstr,$1-,bool,false) $com(%com,Send,1) $com(%com,ResponseText,2)
- var %a = $left($com(%com).result,4096)
- :error
- reseterror
- if ($com(%com)) { .comclose %com }
- if ($comerr) { return 0 }
- return $iif(%a,$v1,0)
- }
- alias -l mod { return $iif($msgtags(user-type).key == mod || $mid(#,2-) == $nick, $true) }
- on *:LOGON:*: {
- raw CAP REQ :twitch.tv/membership
- raw CAP REQ :twitch.tv/tags
- raw CAP REQ :twitch.tv/commands
- }
- ON *:TEXT:*:#: {
- tokenize 32 $strip($1-)
- if ($1 == !define) {
- if (!$mod) { return }
- if (!$2) { .msg $chan ( $+ $nick $+ ): Error, Not enough parameteres! | return }
- var %d = $getsite(https://api.alixe.pro/define/?term= $+ $2-)
- if (!%d) { .msg $chan ( $+ $nick $+ ): There are not any details founded. | return }
- .msg $chan ( $+ $nick $+ ): %d
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement