Jump to content

Recommended Posts

HI all,

 

i want try to do a little script who call picture on center screen VIA a shortcut.

i know how to add simple logo, but i want activate that (2 différents exactly) with a keyboard shortcuts (activate desactivate), no want add action.

i have start code no error in visualcode (i use), but nothing on the screen .

i lock for call the .paa

init.sqf is ok & .hpp too.

if they are a simple you welcome 

 

 

Crosshair_key                               = 0x0E;

 

[player] spawn {

 

    disableSerialization;

    waitUntil {!(isNull (findDisplay 46))};

    _display = findDisplay 46;

    _display displayAddEventHandler["KeyDown", {

    params ["_displayorcontrol", "_key", "_shift", "_ctrl", "_alt"];

 

    if(_key isEqualto Crosshair_key) 

            then {   

            player setVariable ["cross", true];

            _image = "scripts\crosshair\images\crosshair_32.paa";

            

 

            }else{

            player setVariable ["cross", false];

            _image = "scripts\crosshair\images\crosshair_32.paa";




 

        };

    }];

};

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×