Fulqrum Publishing Home   |   Register   |   Today Posts   |   Members   |   UserCP   |   Calendar   |   Search   |   FAQ

Go Back   Official Fulqrum Publishing forum > Fulqrum Publishing > IL-2 Sturmovik: Cliffs of Dover

IL-2 Sturmovik: Cliffs of Dover Latest instalment in the acclaimed IL-2 Sturmovik series from award-winning developer Maddox Games.

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #11  
Old 04-17-2012, 03:27 PM
Artist's Avatar
Artist Artist is offline
Approved Member
 
Join Date: Jan 2010
Posts: 362
Default

The Autohotkey solution (using the North/South of a POV hat), assuming that <Ctrl>+<Insert> ("Control Insert") is assigned to Camera, Keys, "Hold to adjust Field of View":

Code:
#Persistent
iIdStick = 1
SetTimer, watchPOV_Stick, 5

watchPOV_Stick:
    bFirst := true
    while(true){
        GetKeyState, iPOV, %iIdStick%JoyPOV  ; Get position of the POV control.

        ; Some joysticks might have a smooth/continous POV rather than one in fixed increments.
        ; To support them all, use a range:
        if iPOV < 0                                            ; No angle to report
            break
        else if (iPOV > 31500) OR (iPOV >= 0 AND iPOV < 4500){      ; 315 to 360 to 45 degrees: Forward
            zoomViewIn(bFirst)
            bFirst := false
        }
        else if (iPOV >= 13500) AND (iPOV <= 22500){           ; 135 to 180 to 225 degrees: Backward
            zoomViewOut(bFirst)
            bFirst := false
        }
        else
            break
    }
    return

zoomViewOut(bFirst){
    if(bFirst){
        MouseMove 0, 1200, 0
    }
    Send !{Insert down}
    MouseMove 0, -1, 0, R
    Send !{Insert up}
    return 0
}    
zoomViewIn(bFirst){
    if(bFirst){
        MouseMove 0, 0, 0
    }
    Send !{Insert down}
    MouseMove 0, 1, 0, R
    Send !{Insert up}
    return 0
}
Artist
__________________
Ceterum censeo the mixture axis should be supported in IL-2 1946' DeviceLink.

-------------------------------------------------------------

Last edited by Artist; 04-17-2012 at 03:54 PM.
Reply With Quote
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 01:35 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 2007 Fulqrum Publishing. All rights reserved.