Автоматизация и боты

 Помощь      Поиск      Пользователи
Сайт Кибор     Программируемый кликер Кибор     Видео обучение     Заказать бот

 Страниц (2): « 1 [2]   

> Описание: надо заменить данные переменной с кириллицы на латынь
Zireael
Отправлено: 24 Октября, 2018 - 14:35:35
Post Id



Пользователь
Эксперт


Покинул форум
Сообщений всего: 4398
Дата рег-ции: Нояб. 2017  
Репутация: 580




Вы не можете скопировать готовый код?
Было:
CODE:
for (int n=0; n<aw; n++)
{

Стало:
 Цитата:
for (int n=0; n<aw; n++)
} // откуда взялась закрывающая скобка?

 Цитата:
string text_KIB;
int sum_symbol_KIB;
int n_readtext_KIB;
int color_text_KIB_5[1];
color_text_KIB_5[0]=0;
double correct_symbol_KIB[45];
loadsymbolbase("C:\Users\Windows_7\Downloads\basetext.sib" );
win w_KIB;
int ex_KIB, ey_KIB, sum_KIB, x_KIB, y_KIB;

start_();

sum_symbol_KIB=readtext(RU | MARK, #text_KIB, 8, 1, -1, 50, -1, #color_text_KIB_5[0], -1, 0, 50, 1064, 208, 1317, 222, w_KIB);
for (n_readtext_KIB=0; n_readtext_KIB<sum_symbol_KIB; n_readtext_KIB++)correct_symbol_KIB[n_readtext_KIB]=symbolcorrect(n_readtext_KIB);

char t[999];
strcpy(#t[0], text_KIB);
int aw=size(text_KIB);
text_KIB="";
for (int n=0; n<aw; n++)
{
if (t[n]=='а' )text_KIB=text_KIB+"a";
if (t[n]=='б' )text_KIB=text_KIB+"b";
// и тд.
// сюда дописать какие буквы на какие менять
// остальное не надо менять
}
messagebox (text_KIB);

function start_()
{
pause(1000);
int x, y;
getmouse(x, y);
w_KIB=getwindow(0, x, y);
ex_KIB=w_KIB.widthclient; ey_KIB=w_KIB.heightclient;
}


if (fopen ("D:\програмирование-2\1zenoposter\RubSerf\Capcha_Rubserf\тест.txt", "w" )!=0)
{
fwrite(text_KIB);
fclose();//закрываем файл
}
 
 Top
marjachok
Отправлено: 24 Октября, 2018 - 16:27:54
Post Id



Пользователь
Прохожий


Покинул форум
Сообщений всего: 15
Дата рег-ции: Окт. 2018  
Репутация: 0




Zireael ,
Всё равно выдаёт "Ошибка for"
CODE:
string text_KIB;
int sum_symbol_KIB;
int n_readtext_KIB;
int color_text_KIB_5[1];
color_text_KIB_5[0]=0;
double correct_symbol_KIB[45];
loadsymbolbase("C:\Users\Windows_7\Downloads\basetext.sib" );
win w_KIB;
int ex_KIB, ey_KIB, sum_KIB, x_KIB, y_KIB;

start_();

sum_symbol_KIB=readtext(RU | MARK, #text_KIB, 8, 1, -1, 50, -1, #color_text_KIB_5[0], -1, 0, 50, 1064, 208, 1317, 222, w_KIB);
for (n_readtext_KIB=0; n_readtext_KIB<sum_symbol_KIB; n_readtext_KIB++)correct_symbol_KIB[n_readtext_KIB]=symbolcorrect(n_readtext_KIB);

char t[999];
strcpy(#t[0], text_KIB);
int aw=size(text_KIB);
text_KIB="";
for (int n=0; n<aw; n++)
{
if (t[n]=='а' )text_KIB=text_KIB+"a";
if (t[n]=='б' )text_KIB=text_KIB+"b";
if (t[n]=='в')text_KIB=text_KIB+"v";
if (t[n]=='г')text_KIB=text_KIB+"g";
if (t[n]=='д')text_KIB=text_KIB+"d";
if (t[n]=='е')text_KIB=text_KIB+"e";
if (t[n]=='ё')text_KIB=text_KIB+"e";
if (t[n]=='ж')text_KIB=text_KIB+"gh";
if (t[n]=='з')text_KIB=text_KIB+"z";
if (t[n]=='и')text_KIB=text_KIB+"i";
if (t[n]=='й')text_KIB=text_KIB+"j";
if (t[n]=='к')text_KIB=text_KIB+"k";
if (t[n]=='л')text_KIB=text_KIB+"l";
if (t[n]=='м')text_KIB=text_KIB+"m";
if (t[n]=='н')text_KIB=text_KIB+"n";
if (t[n]=='о')text_KIB=text_KIB+"o";
if (t[n]=='п')text_KIB=text_KIB+"p";
if (t[n]=='р')text_KIB=text_KIB+"r";
if (t[n]=='с')text_KIB=text_KIB+"s";
if (t[n]=='т')text_KIB=text_KIB+"t";
if (t[n]=='у')text_KIB=text_KIB+"u";
if (t[n]=='ф')text_KIB=text_KIB+"f";
if (t[n]=='х')text_KIB=text_KIB+"h";
if (t[n]=='ц')text_KIB=text_KIB+"c";
if (t[n]=='ы')text_KIB=text_KIB+"y";
if (t[n]=='ч')text_KIB=text_KIB+"ch";
if (t[n]=='ш')text_KIB=text_KIB+"sh";
if (t[n]=='щ')text_KIB=text_KIB+"sch";
if (t[n]=='ь')text_KIB=text_KIB+y";
if (t[n]=='ъ')text_KIB=text_KIB+"y";
if (t[n]=='э')text_KIB=text_KIB+"e";
if (t[n]=='ю')text_KIB=text_KIB+"yu";
if (t[n]=='я')text_KIB=text_KIB+"ya";
// и тд.
// сюда дописать какие буквы на какие менять
// остальное не надо менять
}
messagebox (text_KIB);

function start_()
{
pause(1000);
int x, y;
getmouse(x, y);
w_KIB=getwindow(0, x, y);
ex_KIB=w_KIB.widthclient; ey_KIB=w_KIB.heightclient;
}


if (fopen ("D:\програмирование-2\1zenoposter\RubSerf\Capcha_Rubserf\тест.txt", "w" )!=0)
{
fwrite(text_KIB);
fclose();//закрываем файл
}
 
 Top
Kibor
Отправлено: 24 Октября, 2018 - 16:34:37
Post Id



Администратор
Эксперт


Покинул форум
Сообщений всего: 8098
Дата рег-ции: Март 2013  
Откуда: Одесса
Репутация: 355




 marjachok пишет:
Всё равно выдаёт "Ошибка for"

Видите что не идет подсветка синтаксиса и нет нумерации скобок?
И причина.
 
 Top
marjachok
Отправлено: 24 Октября, 2018 - 17:06:01
Post Id



Пользователь
Прохожий


Покинул форум
Сообщений всего: 15
Дата рег-ции: Окт. 2018  
Репутация: 0




Kibor ,
А сейчас выскакивает окно с надписью "sc" и записывает в текстовый документ "sc"
CODE:
string text_KIB;
int sum_symbol_KIB;
int n_readtext_KIB;
int color_text_KIB_5[1];
color_text_KIB_5[0]=0;
double correct_symbol_KIB[45];
loadsymbolbase("C:\Users\Windows_7\Downloads\basetext.sib" );
win w_KIB;
int ex_KIB, ey_KIB, sum_KIB, x_KIB, y_KIB;

start_();

sum_symbol_KIB=readtext(RU | MARK, #text_KIB, 8, 1, -1, 50, -1, #color_text_KIB_5[0], -1, 0, 50, 1064, 208, 1317, 222, w_KIB);
for (n_readtext_KIB=0; n_readtext_KIB<sum_symbol_KIB; n_readtext_KIB++)correct_symbol_KIB[n_readtext_KIB]=symbolcorrect(n_readtext_KIB);

char t[999];
strcpy(#t[0], text_KIB);
int aw=size(text_KIB);
text_KIB="";
for (int n=0; n<aw; n++)
{
if (t[n]=='а' )text_KIB=text_KIB+"a";
if (t[n]=='б' )text_KIB=text_KIB+"b";
if (t[n]=='в')text_KIB=text_KIB+"v";
if (t[n]=='г')text_KIB=text_KIB+"g";
if (t[n]=='д')text_KIB=text_KIB+"d";
if (t[n]=='е')text_KIB=text_KIB+"e";
if (t[n]=='ё')text_KIB=text_KIB+"e";
if (t[n]=='ж')text_KIB=text_KIB+"gh";
if (t[n]=='з')text_KIB=text_KIB+"z";
if (t[n]=='и')text_KIB=text_KIB+"i";
if (t[n]=='й')text_KIB=text_KIB+"j";
if (t[n]=='к')text_KIB=text_KIB+"k";
if (t[n]=='л')text_KIB=text_KIB+"l";
if (t[n]=='м')text_KIB=text_KIB+"m";
if (t[n]=='н')text_KIB=text_KIB+"n";
if (t[n]=='о')text_KIB=text_KIB+"o";
if (t[n]=='п')text_KIB=text_KIB+"p";
if (t[n]=='р')text_KIB=text_KIB+"r";
if (t[n]=='с')text_KIB=text_KIB+"s";
if (t[n]=='т')text_KIB=text_KIB+"t";
if (t[n]=='у')text_KIB=text_KIB+"u";
if (t[n]=='ф')text_KIB=text_KIB+"f";
if (t[n]=='х')text_KIB=text_KIB+"h";
if (t[n]=='ц')text_KIB=text_KIB+"c";
if (t[n]=='ы')text_KIB=text_KIB+"y";
if (t[n]=='ч')text_KIB=text_KIB+"ch";
if (t[n]=='ш')text_KIB=text_KIB+"sh";
if (t[n]=='щ')text_KIB=text_KIB+"sch";
if (t[n]=='ь')text_KIB=text_KIB+"y";
if (t[n]=='ъ')text_KIB=text_KIB+"y";
if (t[n]=='э')text_KIB=text_KIB+"e";
if (t[n]=='ю')text_KIB=text_KIB+"yu";
if (t[n]=='я')text_KIB=text_KIB+"ya";
// и тд.
// сюда дописать какие буквы на какие менять
// остальное не надо менять
}
messagebox (text_KIB);

function start_()
{
pause(1000);
int x, y;
getmouse(x, y);
w_KIB=getwindow(0, x, y);
ex_KIB=w_KIB.widthclient; ey_KIB=w_KIB.heightclient;
}


if (fopen ("D:\програмирование-2\1zenoposter\RubSerf\Capcha_Rubserf\тест.txt", "w" )!=0)
{
fwrite(text_KIB);
fclose();//закрываем файл
}
 
 Top
Kibor
Отправлено: 24 Октября, 2018 - 17:18:53
Post Id



Администратор
Эксперт


Покинул форум
Сообщений всего: 8098
Дата рег-ции: Март 2013  
Откуда: Одесса
Репутация: 355




Распознается значит так.
 
 Top
marjachok
Отправлено: 01 Ноября, 2018 - 19:39:43
Post Id



Пользователь
Прохожий


Покинул форум
Сообщений всего: 15
Дата рег-ции: Окт. 2018  
Репутация: 0




Kibor ,
А сейчас выскакивает окно с надписью "sc" и записывает в текстовый документ "sc"
CODE:
string text_KIB;
int sum_symbol_KIB;
int n_readtext_KIB;
int color_text_KIB_5[1];
color_text_KIB_5[0]=0;
double correct_symbol_KIB[45];
loadsymbolbase("C:\Users\Windows_7\Downloads\basetext.sib" );
win w_KIB;
int ex_KIB, ey_KIB, sum_KIB, x_KIB, y_KIB;

start_();

sum_symbol_KIB=readtext(RU | MARK, #text_KIB, 8, 1, -1, 50, -1, #color_text_KIB_5[0], -1, 0, 50, 1064, 208, 1317, 222, w_KIB);
for (n_readtext_KIB=0; n_readtext_KIB<sum_symbol_KIB; n_readtext_KIB++)correct_symbol_KIB[n_readtext_KIB]=symbolcorrect(n_readtext_KIB);

char t[999];
strcpy(#t[0], text_KIB);
int aw=size(text_KIB);
text_KIB="";
for (int n=0; n<aw; n++)
{
if (t[n]=='а' )text_KIB=text_KIB+"a";
if (t[n]=='б' )text_KIB=text_KIB+"b";
if (t[n]=='в')text_KIB=text_KIB+"v";
if (t[n]=='г')text_KIB=text_KIB+"g";
if (t[n]=='д')text_KIB=text_KIB+"d";
if (t[n]=='е')text_KIB=text_KIB+"e";
if (t[n]=='ё')text_KIB=text_KIB+"e";
if (t[n]=='ж')text_KIB=text_KIB+"gh";
if (t[n]=='з')text_KIB=text_KIB+"z";
if (t[n]=='и')text_KIB=text_KIB+"i";
if (t[n]=='й')text_KIB=text_KIB+"j";
if (t[n]=='к')text_KIB=text_KIB+"k";
if (t[n]=='л')text_KIB=text_KIB+"l";
if (t[n]=='м')text_KIB=text_KIB+"m";
if (t[n]=='н')text_KIB=text_KIB+"n";
if (t[n]=='о')text_KIB=text_KIB+"o";
if (t[n]=='п')text_KIB=text_KIB+"p";
if (t[n]=='р')text_KIB=text_KIB+"r";
if (t[n]=='с')text_KIB=text_KIB+"s";
if (t[n]=='т')text_KIB=text_KIB+"t";
if (t[n]=='у')text_KIB=text_KIB+"u";
if (t[n]=='ф')text_KIB=text_KIB+"f";
if (t[n]=='х')text_KIB=text_KIB+"h";
if (t[n]=='ц')text_KIB=text_KIB+"c";
if (t[n]=='ы')text_KIB=text_KIB+"y";
if (t[n]=='ч')text_KIB=text_KIB+"ch";
if (t[n]=='ш')text_KIB=text_KIB+"sh";
if (t[n]=='щ')text_KIB=text_KIB+"sch";
if (t[n]=='ь')text_KIB=text_KIB+"y";
if (t[n]=='ъ')text_KIB=text_KIB+"y";
if (t[n]=='э')text_KIB=text_KIB+"e";
if (t[n]=='ю')text_KIB=text_KIB+"yu";
if (t[n]=='я')text_KIB=text_KIB+"ya";
// и тд.
// сюда дописать какие буквы на какие менять
// остальное не надо менять
}
messagebox (text_KIB);

function start_()
{
pause(1000);
int x, y;
getmouse(x, y);
w_KIB=getwindow(0, x, y);
ex_KIB=w_KIB.widthclient; ey_KIB=w_KIB.heightclient;
}


if (fopen ("D:\програмирование-2\1zenoposter\RubSerf\Capcha_Rubserf\тест.txt", "w" )!=0)
{
fwrite(text_KIB);
fclose();//закрываем файл
}
 
 Top
Zireael
Отправлено: 02 Ноября, 2018 - 00:50:46
Post Id



Пользователь
Эксперт


Покинул форум
Сообщений всего: 4398
Дата рег-ции: Нояб. 2017  
Репутация: 580




Смысл повторять одно и тоже сообщение?
Какой текст распознался, то и записало в файл.
Проверяйте координаты, может распознаёт не там где надо.
 
 Top
Страниц (2): « 1 [2]
Сейчас эту тему просматривают: 1 (гостей: 1, зарегистрированных: 0)
« Вопросы и решение проблем »


Все гости форума могут просматривать этот раздел.
Только зарегистрированные пользователи могут создавать новые темы в этом разделе.
Только зарегистрированные пользователи могут отвечать на сообщения в этом разделе.
 




Powered by