Macros

From Iris2

Jump to: navigation, search
(notes)
(example : bandage-loop)
Line 183: Line 183:
=== example : bandage-loop ===
=== example : bandage-loop ===
-
<pre>job.create(function()  
+
<pre>
-
   while (true) do MacroCmd_BandageSelf() job.wait(3*1000) end  
+
 
-
end)</pre>
+
SetMacro("f3", function()  gMyBandageLoopActive = ~gMyBandageLoopActive    end)
 +
 
 +
job.create(function()  
 +
   while (true) do  
 +
    if (gMyBandageLoopActive) then MacroCmd_BandageSelf() end
 +
    job.wait(3*1000)  
 +
  end  
 +
end)
 +
 
 +
</pre>

Revision as of 00:19, 25 July 2010

Personal tools