<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[Серый форум &mdash; Зажатие кнопки]]></title>
		<link>http://forum.script-coding.com/viewtopic.php?id=15261</link>
		<atom:link href="http://forum.script-coding.com/extern.php?action=feed&amp;tid=15261&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[Недавние сообщения в теме «Зажатие кнопки».]]></description>
		<lastBuildDate>Sun, 29 Mar 2020 17:48:27 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138672#p138672</link>
			<description><![CDATA[<p>Спасибо.</p>]]></description>
			<author><![CDATA[null@example.com (Murka)]]></author>
			<pubDate>Sun, 29 Mar 2020 17:48:27 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138672#p138672</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138671#p138671</link>
			<description><![CDATA[<div class="quotebox"><cite>Murka пишет:</cite><blockquote><p>Я правильно написал?</p></blockquote></div><p>Нет, усложнили.<br /></p><div class="codebox"><pre><code>*$z::
for k, v in bga := [[&quot;h&quot;, 100], [&quot;e&quot;, 250], [&quot;l&quot;, 500], [&quot;l&quot;, 750], [&quot;o&quot;, 1000]] {
	SendInput, % &quot;{&quot; . v[1] . &quot;}&quot;
	Sleep, v[2]
} until !GetKeyState(&quot;vk5A&quot;, &quot;P&quot;)
return</code></pre></div><p>Три точки не нужны, я просто показал, что можно продолжить.</p>]]></description>
			<author><![CDATA[null@example.com (teadrinker)]]></author>
			<pubDate>Sun, 29 Mar 2020 17:38:30 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138671#p138671</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138670#p138670</link>
			<description><![CDATA[<p><strong>teadrinker</strong></p><p>У меня ещё вопрос, зачем нужны точки внутри фигурных скобок?</p>]]></description>
			<author><![CDATA[null@example.com (Murka)]]></author>
			<pubDate>Sun, 29 Mar 2020 17:17:26 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138670#p138670</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138669#p138669</link>
			<description><![CDATA[<p><strong>teadrinker</strong></p><p>Я правильно написал?</p><div class="codebox"><pre><code>
*$z::
for k, v in bga := [[&quot;h&quot;, 100], [&quot;e&quot;, 250], [&quot;l&quot;, 500], [&quot;l&quot;, 750], [&quot;o&quot;, 1000]] {
	;MsgBox, % bga[k, 2]
	SendInput, % &quot;{&quot; . bga[k, 1] . &quot;}&quot;
	Sleep, % bga[k, 2]
} until !GetKeyState(&quot;vk5A&quot;, &quot;P&quot;)
return
</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (Murka)]]></author>
			<pubDate>Sun, 29 Mar 2020 17:16:23 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138669#p138669</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138666#p138666</link>
			<description><![CDATA[<p>В данном случае v — это массив вида [&quot;h&quot;, 100], соответственно к его элементам нужно обращаться по индексам, 1 и 2.</p>]]></description>
			<author><![CDATA[null@example.com (teadrinker)]]></author>
			<pubDate>Sun, 29 Mar 2020 16:38:21 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138666#p138666</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138665#p138665</link>
			<description><![CDATA[<p><strong>teadrinker</strong></p><p>Не могу понять в чем проблема. При нажатии на клавишу ничего не происходит.</p><div class="codebox"><pre><code>
*$z::
for k, v in [[&quot;h&quot;, 100], [&quot;e&quot;, 250], [&quot;l&quot;, 500], [&quot;l&quot;, 750], [&quot;o&quot;, 1000]] {
   SendInput, % &quot;{&quot; . v . &quot;}&quot;
   Sleep, % v
} until !GetKeyState(&quot;vk5A&quot;, &quot;P&quot;)
return
</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (Murka)]]></author>
			<pubDate>Sun, 29 Mar 2020 16:31:12 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138665#p138665</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138659#p138659</link>
			<description><![CDATA[<p><strong>teadrinker</strong></p><p>.</p>]]></description>
			<author><![CDATA[null@example.com (Murka)]]></author>
			<pubDate>Sun, 29 Mar 2020 15:41:34 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138659#p138659</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138656#p138656</link>
			<description><![CDATA[<div class="codebox"><pre><code>for k, v in [[&quot;F5&quot;, 100], [&quot;F6&quot;, 250], [&quot;5&quot;, 300] ...] </code></pre></div>]]></description>
			<author><![CDATA[null@example.com (teadrinker)]]></author>
			<pubDate>Sun, 29 Mar 2020 15:34:06 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138656#p138656</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138655#p138655</link>
			<description><![CDATA[<p><strong>teadrinker</strong></p><p>А что если задержка будет всё время разной? 100, 250, 300</p>]]></description>
			<author><![CDATA[null@example.com (Murka)]]></author>
			<pubDate>Sun, 29 Mar 2020 15:25:00 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138655#p138655</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138652#p138652</link>
			<description><![CDATA[<p>Эх, <strong>Murka</strong>...<br /></p><div class="codebox"><pre><code>*$z::
for k, v in [&quot;F5&quot;, &quot;F6&quot;, &quot;5&quot;, &quot;6&quot;, &quot;7&quot;, &quot;9&quot;, &quot;0&quot;, &quot;Tab 2&quot;] {
   SendInput, % &quot;{&quot; . v . &quot;}&quot;
   Sleep, 300
} until !GetKeyState(&quot;vk5A&quot;, &quot;P&quot;)
Return</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (teadrinker)]]></author>
			<pubDate>Sun, 29 Mar 2020 14:42:19 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138652#p138652</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138651#p138651</link>
			<description><![CDATA[<p><strong>GOSPODBOGTROICA</strong></p><p>Я пытался сделать код более компактным, но не получилось.<br /></p><div class="codebox"><pre><code>
#SingleInstance, Force

*$z::
While GetKeyState(&quot;vk5A&quot;, &quot;P&quot;)
{
SendInput, {f5}
sleep, 300
If GetKeyState(&quot;vk5A&quot;, &quot;P&quot;) = 0
	break
SendInput, {f6}
sleep, 300
If GetKeyState(&quot;vk5A&quot;, &quot;P&quot;) = 0
	break
SendInput, {5}
sleep, 300
If GetKeyState(&quot;vk5A&quot;, &quot;P&quot;) = 0
	break
SendInput, {6}
sleep, 300
If GetKeyState(&quot;vk5A&quot;, &quot;P&quot;) = 0
	break
SendInput, {7}
sleep, 300
If GetKeyState(&quot;vk5A&quot;, &quot;P&quot;) = 0
	break
SendInput, {9}
sleep, 300
If GetKeyState(&quot;vk5A&quot;, &quot;P&quot;) = 0
	break
SendInput, {0}
sleep, 300
If GetKeyState(&quot;vk5A&quot;, &quot;P&quot;) = 0
	break
SendInput, {Tab 2}
sleep, 300
If GetKeyState(&quot;vk5A&quot;, &quot;P&quot;) = 0
	break
}
return
</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (Murka)]]></author>
			<pubDate>Sun, 29 Mar 2020 13:50:36 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138651#p138651</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138634#p138634</link>
			<description><![CDATA[<p><strong>Murka</strong> мне для доты 2, скрипт просто прокликивает все, а нужные способности могут не прожаться а он может выбрать другую цель, через процесс игры он не сможет проверять ?</p><p>А Скрипт можно остановить в тот момент когда отпускаешь кнопку, чтобы он до конца не тыкал и не ждал?<br /></p><div class="codebox"><pre><code>
*$z::
While GetKeyState(&quot;vk5A&quot;, &quot;P&quot;)
{
Sendinput, {f5}
sleep, 		
Sendinput, {f6}
sleep, 300
Sendinput, {5}
sleep, 300
Sendinput, {6}
sleep, 300
Sendinput, {7}
sleep, 300
Sendinput, {9}
sleep, 300
Sendinput, {0}
sleep, 300
Sendinput, {tab}{tab}
sleep, 300
}
return
</code></pre></div><p>Вообще желательно чтобы, он как то мог проверить выполнилось ли дейстиве или нет, а те каторые выполнились чтобы не повторялись, выполнялись только те каторые не выполнились, пока нажата кнопка, sleep, вообще поидее не нужна, просто действия перескакивают или не выполняются, приходиться зажимать кнопку, чтобы они по новой нажались, какие то кнопки прожались, отпускаю кнопку, скрипт до конца выполняется, можно остановить в тот момент когда отпускаю?</p>]]></description>
			<author><![CDATA[null@example.com (GOSPODBOGTROICA)]]></author>
			<pubDate>Sat, 28 Mar 2020 18:37:05 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138634#p138634</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138633#p138633</link>
			<description><![CDATA[<p><strong>GOSPODBOGTROICA</strong></p><p>Для какой игры вам нужен этот скрипт?</p>]]></description>
			<author><![CDATA[null@example.com (Murka)]]></author>
			<pubDate>Sat, 28 Mar 2020 18:12:48 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138633#p138633</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138632#p138632</link>
			<description><![CDATA[<p><strong>GOSPODBOGTROICA</strong></p><p>http://www.script-coding.com/AutoHotkey/Hotkeys.html Ну вот вам справочка. Там говорится про эти *, $ символы.</p>]]></description>
			<author><![CDATA[null@example.com (Murka)]]></author>
			<pubDate>Sat, 28 Mar 2020 18:11:06 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138632#p138632</guid>
		</item>
		<item>
			<title><![CDATA[Re: Зажатие кнопки]]></title>
			<link>http://forum.script-coding.com/viewtopic.php?pid=138631#p138631</link>
			<description><![CDATA[<p><strong>Murka</strong><br />Спасибо все четко работает, а можно расшифровать *$z, обязательно так писать или можно просто z или &quot;vk5A&quot; или &quot;sc2C&quot; , и не подскажете чтобы только в определенном процессе работало? что прописать, и еще вопрос ahk может прочитать в игре нажалась ли кнопка или нет? ну в скрипте например она сработала а в игре может не сработала она может проверить?<br />Или проверить была ли нажата в игре кнопка, и не нажимать её, или новую ветку надо создавать на другой вопрос уже, заранее извиняюсь.</p>]]></description>
			<author><![CDATA[null@example.com (GOSPODBOGTROICA)]]></author>
			<pubDate>Sat, 28 Mar 2020 17:15:28 +0000</pubDate>
			<guid>http://forum.script-coding.com/viewtopic.php?pid=138631#p138631</guid>
		</item>
	</channel>
</rss>
