.

Posts Tagged “süper sözlük mirc kodu”

Selam mIRC kullanıcıları. Şimdi sizler’e istediğiniz dil’i istediğiniz dil’e çevirebiliceğiniz süper bir sözlük mirc kodu vericeğim.

Dil’den Dile Çeviri mIRC Kodu

menu menubar,status,channel,query {
-
Translation v1.0 { dialog $iif($dialog(trans),-x,-md) trans trans }
-
}

;============================== DIALOG

dialog trans {
title “Translation v1.0″
size -1 -1 128 168
option dbu notheme
combo 1, 4 9 59 250, size drop
text “From:”, 2, 4 1 25 8
text “To:”, 3, 65 1 25 8
combo 4, 65 9 59 250, size drop
edit “”, 5, 4 29 120 52, multi return vsbar
text “Text:”, 6, 4 21 25 8
text “Translation:”, 7, 4 84 29 8
edit “”, 8, 4 92 120 52, read multi return vsbar
box “”, 9, -7 144 141 4
button “&Clipboard”, 10, 48 152 37 12
button “&OK”, 11, 85 152 37 12, ok
button “&Translate!”, 12, 4 152 37 12
}
on *:dialog:trans:sclick:1:{ %from = $did(1).seltext }
on *:dialog:trans:sclick:4:{ %to = $did(4).seltext }
on *:dialog:trans:sclick:10:{
var %a = 1
while (%a <= $did(8,0).lines) {
if (%a == 1) { clipboard $did(8,%a).text }
else { clipboard -a $+($chr(160),$did(8,%a).text) }
inc %a
}
}
on *:dialog:trans:close:0:{
unset %answer
unset %att
}
on *:dialog:trans:init:0:{
%att = 5
var %lng = ar,bg,zh-CN,zh-TW,hr,cs,da,nl,en,fi,fr,de,el,hi,it,ja,ko,no,pl,pt,ro,ru,es,sv
var %lng2 = Arabic,Bulgarian,Chinese (Simp.),Chinese (Trad.),Croatian,Czech,Danish,Dutch,English,Finnish,French,German,Greek,Hindi,Italian,Japanese,Korean,Norwegian,Polish,Portuguese,Romanian,Russian,Spanish,Swedish
var %a = 1, %b
while ($gettok(%lng2,%a,44)) {
%b = $ifmatch
did -a trans 1 %b
did -a trans 4 %b
if (%from == %b) { did -c trans 1 %a }
elseif (%to == %b) { did -c trans 4 %a }
inc %a
}
did -f trans 5
}
on *:dialog:trans:sclick:12:{
if (!$did(5).text || !$did(4).seltext || !$did(1).seltext || $did(4).seltext == $did(1).seltext) { beep | return }
unset %txt
var %a = 1, %b
while ($did(5,%a).text) {
%b = %b $ifmatch
inc %a
}
var %txt = $replace(%b,$chr(39),%!039,$chr(44),%!2C,$chr(35),%!32,!,%!31,$chr(36),%!24,’,%!27,$chr(40),%!28,$chr(41),%!29)
did -ra trans 8 Translating…
translate %txt
%att = 5
}

;============================== ALIASES

alias -l translate {
sockclose xtranslate
sockopen xtranslate google.com 80
sockmark xtranslate $1-
}
alias -l striphtml {
var %p = 1, %b = $remove($replace($1-,>,$+(>,$chr(32)),<,$+($chr(32),<,)),$chr(35),amp), %c
while ($gettok(%b,%p,32)) {
%c = $ifmatch
if (*&*;* iswm %c) {
var %g = $remove(%c,&,amp,#,1,2,3,4,5,6,7,8,9,0)
var %left = $gettok(%c,1,38)
var %right = $gettok(%c,2,59)
var %middle = $remove(%c,%left,%right,&,$chr(35),;)
%g = $replace(%g,;,$chr(%middle))
%b = $replace(%b,%c,%g) | %p = 0
}
elseif (*<* iswm %c || *</* iswm %c || *solid* iswm %c || *px* iswm %c || *:* iswm %c && $remove(%c,:) !isnum || */* iswm %c || *’* iswm %c || *&* iswm %c || *<*>* iswm %c || *=* iswm %c || *”* iswm %c || *>* iswm %c || $+(*,$chr(40),*) iswm %c || $+(*,$chr(41),*) iswm %c || $+(*,$chr(123),*) iswm %c || $+(*,$chr(125),*) iswm %c) { %b = $remove(%b,%c) | %p = 0 }
inc %p
}
return %b
}
alias -l endtranslate {
did -ra trans 8 Nothing found.
unset %a
}
alias -l checkfile {
if (%txt) {
did -ra trans 8 $striphtml($remove(%txt,$+($chr(32),$chr(32)),</textarea))
unset %txt
}
else { did -ra trans 8 Nothing found. }
}

;============================== EVENTS

on *:sockopen:xtranslate:{
var %lng = ar,bg,zh-CN,zh-TW,hr,cs,da,nl,en,fi,fr,de,el,hi,it,ja,ko,no,pl,pt,ro,ru,es,sv
var %from = $gettok(%lng,$did(trans,1).sel,44)
var %to = $gettok(%lng,$did(trans,4).sel,44)
if ($sockerr > 0 && $dialog(trans)) { did -ra trans 8 Socket error(s). Try again later. | return }
var %get = $+(http://translate.google.com/translate_t?&sl=,%from,&tl=,%to,&text=,$replace($sock($sockname).mark,$chr(32),+))
sockwrite -n $sockname GET %get HTTP/1.1
sockwrite -n $sockname Host: $+(www.google.com,$str($crlf, 2))
}
on *:sockread:xtranslate:{
if ($sockerr > 0 && $dialog(trans)) { did -ra trans 8 Socket error(s). Try again later. | return }
sockread -f 8096 &a
while ($sockbr > 0) {
if ($bfind(&a,1,id=suggestion>)) {
var %a = $ifmatch
bset -t &a %a $bvar(&a,%a,990000000).text
tokenize 32 $gettok($bvar(&a,%a,99000000000).text,2,62)
%txt = $1-
}
elseif ($bfind(&a,1,</textarea>)) {
%txt = %txt $gettok($bvar(&a,1,99000000000).text,1,60)
}
sockread 8096 &a
}
.timercheck -o 1 1 checkfile
}

Bu kodu remotelerinize ekleyiniz ve kanala sağ tıkladığınızda en alt’da çıkacaktır.

Tags: dil mirc kodu, sözlük mirc kodu, süper çeviri kodu, süper çeviri addonu, addonlar

Comments Yorum Yok »