<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Серый форум &mdash; AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
	<link rel="self" href="https://forum.script-coding.com/extern.php?action=feed&amp;tid=15753&amp;type=atom" />
	<updated>2020-10-28T20:22:38Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=15753</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142954#p142954" />
			<content type="html"><![CDATA[<p><strong>CD_MyAcO</strong>, <a href="https://ru.wikipedia.org/wiki/%D0%A2%D0%B0%D0%B1%D1%83%D0%BB%D1%8F%D1%86%D0%B8%D1%8F">Табуляция</a>.</p>]]></content>
			<author>
				<name><![CDATA[qqlexa]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=39096</uri>
			</author>
			<updated>2020-10-28T20:22:38Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142954#p142954</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142946#p142946" />
			<content type="html"><![CDATA[<p><strong>qqlexa</strong> Но ведь если в блокноте кодить, надо раз 20 отступов делать для 1 строки. И это время затратно.</p>]]></content>
			<author>
				<name><![CDATA[CD_MyAcO]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=41152</uri>
			</author>
			<updated>2020-10-28T18:11:16Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142946#p142946</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142939#p142939" />
			<content type="html"><![CDATA[<p><strong>CD_MyAcO</strong>, независимо от среды программирования стоит обращать на стиль кода.</p>]]></content>
			<author>
				<name><![CDATA[qqlexa]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=39096</uri>
			</author>
			<updated>2020-10-28T15:32:27Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142939#p142939</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142925#p142925" />
			<content type="html"><![CDATA[<p><strong>qqlexa</strong><br />Я писал ранее в блокноте <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" /><br />Уже скачал полноценную нормальную программу для кодинга ахк</p>]]></content>
			<author>
				<name><![CDATA[CD_MyAcO]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=41152</uri>
			</author>
			<updated>2020-10-28T12:46:01Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142925#p142925</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142923#p142923" />
			<content type="html"><![CDATA[<p><strong>CD_MyAcO</strong>, делайте отступы для лучшего прочтения:<br /></p><div class="codebox"><pre><code>
~LButton &amp; RButton::
sleep 1000
GetKeyState(&quot;LButton&quot;)
loop
{
	if GetKeyState(&quot;LButton&quot;, &quot;P&quot;)
	{
		if GetKeyState(&quot;RButton&quot;, &quot;P&quot;)
			click
		else
			break
	}
	else
		break
}
return
</code></pre></div><p>Преподователи советуют использовать скобки даже на одну строку, в случае, если нужно будет дописать - вы не сломаете ничего, кроме тела условного оператора:<br /></p><div class="codebox"><pre><code>
~LButton &amp; RButton::
sleep 1000
GetKeyState(&quot;LButton&quot;)
loop
{
	if GetKeyState(&quot;LButton&quot;, &quot;P&quot;)
	{
		if GetKeyState(&quot;RButton&quot;, &quot;P&quot;)
		{
			click
		}
		else
		{
			break
		}
	}
	else
	{
		break
	}
}
return
</code></pre></div><p>Так же есть практика, когда открываете скобку на той же строчке:<br /></p><div class="codebox"><pre><code>
~LButton &amp; RButton::
sleep 1000
GetKeyState(&quot;LButton&quot;)
loop {
	if GetKeyState(&quot;LButton&quot;, &quot;P&quot;) {
		if GetKeyState(&quot;RButton&quot;, &quot;P&quot;) {
			click
		}
		else {
			break
		}
	}
	else {
		break
	}
}
return
</code></pre></div><p>Но это уже вкусовщина. <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" /></p>]]></content>
			<author>
				<name><![CDATA[qqlexa]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=39096</uri>
			</author>
			<updated>2020-10-28T11:43:42Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142923#p142923</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142919#p142919" />
			<content type="html"><![CDATA[<p>Всё, я уже сам разобрался.<br /></p><div class="codebox"><pre><code>~LButton &amp; RButton::
sleep 1000
GetKeyState(&quot;LButton&quot;)
loop
{
if GetKeyState(&quot;LButton&quot;, &quot;P&quot;)
{
if GetKeyState(&quot;RButton&quot;, &quot;P&quot;)
click
else
break
}
else
break
}
return</code></pre></div>]]></content>
			<author>
				<name><![CDATA[CD_MyAcO]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=41152</uri>
			</author>
			<updated>2020-10-28T10:30:44Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142919#p142919</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142887#p142887" />
			<content type="html"><![CDATA[<p><strong>Botsy</strong> Метки я нашёл в интернете, но скрипт всё равно не работает пока зажата клавиша.<br /></p><div class="codebox"><pre><code>~LButton &amp; RButton::
1:
While GetKeyState(&quot;LButton&quot;)
{
click
Goto, 1
}
return</code></pre></div>]]></content>
			<author>
				<name><![CDATA[CD_MyAcO]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=41152</uri>
			</author>
			<updated>2020-10-27T19:28:55Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142887#p142887</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142884#p142884" />
			<content type="html"><![CDATA[<p><strong>CD_MyAcO</strong> возможно нельзя повторно использовать клавишу, которая используется для хоткея.</p>]]></content>
			<author>
				<name><![CDATA[Botsy]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=41069</uri>
			</author>
			<updated>2020-10-27T19:19:53Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142884#p142884</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142883#p142883" />
			<content type="html"><![CDATA[<p><strong>Botsy</strong> Это тот же цикл что и я написал.</p>]]></content>
			<author>
				<name><![CDATA[CD_MyAcO]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=41152</uri>
			</author>
			<updated>2020-10-27T19:17:38Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142883#p142883</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142881#p142881" />
			<content type="html"><![CDATA[<p><strong>CD_MyAcO</strong> А так ? Если не поможет, то я больше не знаю.<br /></p><div class="codebox"><pre><code>
~LButton &amp; RButton::

While GetKeyState(&quot;LButton&quot;)
{
click ; или Send {LButton}
}
return
</code></pre></div>]]></content>
			<author>
				<name><![CDATA[Botsy]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=41069</uri>
			</author>
			<updated>2020-10-27T19:16:08Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142881#p142881</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142880#p142880" />
			<content type="html"><![CDATA[<p><strong>Botsy</strong> Я где то находил маяки на просторах интернета, но давно их не использовал. Поэтому забил как они работают.</p>]]></content>
			<author>
				<name><![CDATA[CD_MyAcO]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=41152</uri>
			</author>
			<updated>2020-10-27T19:08:24Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142880#p142880</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142879#p142879" />
			<content type="html"><![CDATA[<p><strong>Botsy</strong> Тогда зациклиться на 1 клике и будет работать бесконечно. Мне нужно пока зажата - работает, отпустили - не работает.<br />Я пробовал такой код. Но я не знаю как ставить маяки(Когда доходит до кода, возвращает туда где поставлен маяк. В этом случаи если после клика стоит код(хз как там он пишеться) то он возвращается до маяка под названием которое указанное, который ищет в коде.)<br /></p><div class="codebox"><pre><code>~LButton &amp; RButton::
While GetKeyState(&quot;LButton&quot;)
click
return</code></pre></div><p>К примеру с маяком<br /></p><div class="codebox"><pre><code>~LButton &amp; RButton::
1:
While GetKeyState(&quot;LButton&quot;)
{
click
mayak, 1 
}
return</code></pre></div>]]></content>
			<author>
				<name><![CDATA[CD_MyAcO]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=41152</uri>
			</author>
			<updated>2020-10-27T19:06:57Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142879#p142879</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142878#p142878" />
			<content type="html"><![CDATA[<p><strong>CD_MyAcO</strong> Мб так получиться.<br /></p><div class="codebox"><pre><code>
~LButton &amp; RButton::
loop
{
click
}
return
</code></pre></div>]]></content>
			<author>
				<name><![CDATA[Botsy]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=41069</uri>
			</author>
			<updated>2020-10-27T19:01:57Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142878#p142878</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142877#p142877" />
			<content type="html"><![CDATA[<p><strong>Botsy</strong><br />Вот цикл работает, но он работает только раз.<br /></p><div class="codebox"><pre><code>~LButton &amp; RButton::
click
return</code></pre></div><p>Если сделать такой же, только с клавиатурой. То он будет работать пока зажата кнопка клавиатуры(потому что когда зажата кнопка клавиатуры то клавиша подаёт 1 клик, затем немерено пока не отпуститься клавиша. А в мышке только 1 раз то есть нажатый, и отпущенный.) Как это исправить?</p><div class="codebox"><pre><code>Numpad0::
click
return</code></pre></div>]]></content>
			<author>
				<name><![CDATA[CD_MyAcO]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=41152</uri>
			</author>
			<updated>2020-10-27T19:00:47Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142877#p142877</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: При нажатии 2 клавиш миши выполняется цикл]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=142876#p142876" />
			<content type="html"><![CDATA[<p><strong>CD_MyAcO</strong> Я не понимаю, не понятно объясняете.</p>]]></content>
			<author>
				<name><![CDATA[Botsy]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=41069</uri>
			</author>
			<updated>2020-10-27T18:57:23Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=142876#p142876</id>
		</entry>
</feed>
