Jump to content

Sky Slate Blueberry Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate
Photo

Befehlreihenfolge


  • Please log in to reply
1 reply to this topic
ragman1976
  • Members
  • 8 posts
  • Last active: Jul 20 2015 11:32 AM
  • Joined: 02 Jan 2014

Hallo,

 

ich verwende für ein Spiel folgendes Script (siehe unten). Es ist wahrscheinlich etwas unprofessionell, aber es tut fast was ich möchte, allerdings ist die Reihenfolge wie sie letztendlich ausgeführt wird nicht die, die ich mir vorstelle.Wenn ich das Script mit F1 starte wird folgendes ausgegeben:

 

212379*012379*982379*012379*9*8P12379*2379*9*8P012379*9*8P2379*12379*9*8P012379*

 

Ich möchte, dass bevor Numpad3, NumpadMult und Numpad7 gesendet wird erst fünf mal Numpad8 gesendet wird und verstehe gerade nicht warum das nicht passiert.

 

wie kann ich das Script ändern damit die von mir gewünschte Reihenfolge eingehalten wir?

 

Gruß und Danke

 

 

 

 

 
 
   
F1::      
 
send {F11} ;Combatlog an
SetTimer,TNumpad2,1000 ;EP2W
send, {Numpad2}
sleep, 600
SetTimer,TNumpad1,1200 ;DEM
send, {Numpad1}
sleep, 800
SetTimer,TNumpad0,1000 ;EP2W (EP2S)
send, {Numpad0}
sleep, 500
SetTimer,TNumpad9,500 ;TT1
send, {Numpad9}
SetTimer,TP,500 ;Befehle mehrfach 
 
;sleep, 600 ;Puffer Allerlei
 
Check = 1
loop
{
if check = 0
break
 
Loop 5
{
Send {Numpad8}
sleep, 500
}
 
;sleep, 2500     
send, {Space}
 
;SetTimer, TSpace, 1100 ;Feuer
;SetTimer,TF,700 ;INTER
SetTimer,TNumpad3,1000 ;Drohnen
SetTimer,TNumpadMult,1000 ;Filler
SetTimer,TNumpad7,1000 ;Aux2Bat
 
Sleep, 17500
}
send, test
Return
 
 
 
F2::
send {F12} ;aus
check = 0
SetTimer,TNumpad0,Off
SetTimer,TNumpad1,Off
SetTimer,TNumpad2,Off
;SetTimer, TSpace,Off
 
Return
 
F5::
 
send {F12} ;aus
check = 0
SetTimer,TNumpadMult,Off
SetTimer,TP,Off
SetTimer,TNumpad0,Off
SetTimer,TNumpad1,Off
SetTimer,TNumpad2,Off
SetTimer,TNumpad3,Off
SetTimer,TNumpad7,Off
SetTimer,TNumpad9,Off
SetTimer,TF,Off
 
;SetTimer, TSpace,Off
 
Return
 
 
TNumpad0:
Send,{Numpad0}
TNumpad1:
Send,{Numpad1}
TNumpad2:
Send,{Numpad2}
TNumpad3:
Send,{Numpad3}
TNumpad7:
Send,{Numpad7}
TNumpad9:
Send,{Numpad9}
TNumpadMult:
Send,{NumpadMult}
 
Return
 
TP:
Send,P
Return
 
;TSpace:
; Send,{Space}
;Return
   
TF:
Send,F
Return
 
F4::
Loop 8
{
Send {F5}
sleep, 50
}
return
 
 
q:: ;Erster Angriff ISA, kein TT
send {F11} ;Combatlog an
Loop 5
{
Send {Numpad4}
SetTimer,TNumpad7,1000
sleep, 500
}
sleep, 200
send {space1}
return
 
e:: ;Angriff für Gruppen manuell
send {F11} ;Combatlog an
SetTimer,TF,500 ;INTER
Loop 8
{
Send {Numpad5}
;SetTimer,TNumpad7,1000
sleep, 500
}
sleep, 500
send {space}
SetTimer,TF,500
return
 
F9::
suspend, on
return
 
F10::
suspend, off
return
 
 

Pause:: ExitApp 



Rohwedder
  • Members
  • 130 posts
  • Last active: Nov 10 2015 03:43 PM
  • Joined: 06 Feb 2013

Viele deiner Subroutinen haben kein Return. Wenn du in

TNumpad2:
Send,{Numpad2}
TNumpad3:
Send,{Numpad3}
TNumpad7:
Send,{Numpad7}

auf das Label TNumpad2 springst, wird nicht nur {Numpad2} gesendet, sondern gleich auch {Numpad3}, {Numpad7} .. bis endlich ein Return kommt.

 

Obiger Ausschnitt sollte so aussehen:

TNumpad2:
  Send,{Numpad2}
Return
TNumpad3:
  Send,{Numpad3}
Return
TNumpad7:
  Send,{Numpad7}
Return