Здравствуйте, гость ( Вход | Регистрация )

 
Ответить в эту темуОткрыть новую тему
> Multi macro mouse wait
kaltorak
сообщение 23.10.2021, 15:14
Сообщение #1


**

Neophyte
Сообщений: 17
Регистрация: 12.10.2021
Группа: Пользователи
Наличность: 5
Пользователь №: 20.106
Возраст: 30



I'm running a macro in 5 windows of a certain game... when you get to a part of the macro you need to use mouse to click on some options... is there any way in uopilot to tell other macros in progress that they should wait the other macro complete the click process and then use the mouse? Because otherwise it starts clicking wildly within the 5 windows simultaneously and doesn't execute the code correctly. I think maybe I have to do this excerpt in lua, but I'm not sure how, if possible send me links with reference of the function that I'll give a study I'm still a beginner... thanks again!
Пользователь в офлайнеDelete PostОтправить личное сообщение
Вернуться в начало страницы
+Ответить с цитированием данного сообщения
kaltorak
сообщение 28.10.2021, 0:24
Сообщение #2


**

Neophyte
Сообщений: 17
Регистрация: 12.10.2021
Группа: Пользователи
Наличность: 5
Пользователь №: 20.106
Возраст: 30



No solution about this? (IMG:style_emoticons/default/unsure.gif)
Пользователь в офлайнеDelete PostОтправить личное сообщение
Вернуться в начало страницы
+Ответить с цитированием данного сообщения
shrewdo
сообщение 28.10.2021, 18:32
Сообщение #3


**

Neophyte
Сообщений: 31
Регистрация: 10.10.2021
Группа: Пользователи
Наличность: 0
Пользователь №: 20.100
Возраст: 39



show your code to see and understand it first then maybe can help, you want to bind the click to a specific window?
Пользователь в офлайнеDelete PostОтправить личное сообщение
Вернуться в начало страницы
+Ответить с цитированием данного сообщения
kaltorak
сообщение 31.10.2021, 0:55
Сообщение #4


**

Neophyte
Сообщений: 17
Регистрация: 12.10.2021
Группа: Пользователи
Наличность: 5
Пользователь №: 20.106
Возраст: 30



Цитата(shrewdo @ 28.10.2021, 18:32) *

show your code to see and understand it first then maybe can help, you want to bind the click to a specific window?


I will try to explain in detail:
I have 4 windows of a game running uopilot code that basically just uses keyboard functions. With the exception of the time when it is necessary to talk to an NPC by clicking on him and when for some reason the character is disconnected and needs to enter a PIN code to access the character again.

Then my problem comes up, because sometimes 3 game windows need to use the mouse either to talk to the NPC or enter the PIN, that's when the macro gets out of control and sometimes starts clicking in the wrong places, opening windows in the game, walking with the character in a direction that he shouldn't be walking, finally I believe it has become clear...

I thought the only way to solve this would be a function that would make each tab of the 4 macros know when the mouse is occupied in one of the other tabs and give a wait until the mouse is released by the other macro tab, maybe there could be another solution, but it was the only one I could think of. If this is the only option, the question is... is this possible? How would I do this? I needed a light at the end of this tunnel... lol

PS: I reinforce once again that the same code is running in 4 UOpilot tabs, each linked to a different window.

PIN execution code by clicks:
Код
//1 PIN
:iniciopin
set $a findimage (0, 0 1920,1080 (imgs\0.bmp) %arr 2)
wait 1s
if $a > 90
    move_smooth %arr[1 1] %arr[1 2]
    wait 2s
    left [1 1]
    wait 2s
    move_smooth 407, 369
end_if

//2 PIN
set $a findimage (0, 0 1920,1080 (imgs\0.bmp) %arr 2)
wait 1s
if $a > 90
    move_smooth %arr[1 1] %arr[1 2]
    wait 2s
    left [1 1]
    wait 2s
    move_smooth 407, 369
end_if

//3PIN
set $a findimage (0, 0 1920,1080 (imgs\9.bmp) %arr 2)
wait 1s
if $a > 90
    move_smooth %arr[1 1] %arr[1 2]
    wait 2s
    left [1 1]
    wait 2s
    move_smooth 407, 369
end_if


//4 PIN
set $a findimage (0, 0 1920,1080 (imgs\3.bmp) %arr 2)
wait 1s
if $a > 90
    move_smooth %arr[1 1] %arr[1 2]
    wait 2s
    left [1 1]
    wait 1s
    move_smooth 407, 369
end_if


Execution code to talk to NPC:
Код
//Click NPC to open talk window
set $npc 467, 478

:npcopen
kright $npc
wait 1s
kright $npc
Пользователь в офлайнеDelete PostОтправить личное сообщение
Вернуться в начало страницы
+Ответить с цитированием данного сообщения
shrewdo
сообщение 3.11.2021, 13:11
Сообщение #5


**

Neophyte
Сообщений: 31
Регистрация: 10.10.2021
Группа: Пользователи
Наличность: 0
Пользователь №: 20.100
Возраст: 39



you using this codes all together in the same script? its easy and way better to use it each code in a seperate uopilot tab so each code will be working on the windows of the game you specified for it, i run 12x client of a game means 12 windows and i set each code to each window with clicks and it works fine even if one of them dc.

which game you playing talismanonline?
Пользователь в офлайнеDelete PostОтправить личное сообщение
Вернуться в начало страницы
+Ответить с цитированием данного сообщения

Ответить в эту темуОткрыть новую тему
2 чел. читают эту тему (гостей: 2, скрытых пользователей: 0)
Пользователей: 0

 

- Текстовая версия | Версия для КПК Сейчас: 28.3.2024, 19:12
Designed by Nickostyle