Jump to content

Scopey

Member
  • Content Count

    10
  • Joined

  • Last visited

  • Medals

Posts posted by Scopey


  1. im tired and brain dieing... setting it global???

    publicvariable "SCOPY_mycounter"; ????

    defining to player didnt work...

    player setVariable ["SCOPY_mycounter", SCOPY_amountofbombs, true];
    
    SCOPY_amountofbombs = player getVariable "SCOPY_mycounter";

    i have even tired defining it in init.sqf

    10 hours scripting for a release this weekend...grr

    still the first problem is stopping me... but i have made about 20 new scripts working...


  2. i trying to get a user defined variable in intgr form to be shared between scripts.

    example.

    _amountofbombs      = ctrlText 4;
    if (!(_amountofbombs call ISSE_str_isInteger)) then {_amountofbombs = "0";};
    _amountofbombs      = _amountofbombs call ISSE_str_StrToInt;  
    if (_amountofbombs < 0) then {_amountofbombs = 0;};

    gets the user input fine.

    then

    buttonSetAction [3, format["if ((lbCurSel 1) >= 0) then {[(lbData [1, (lbCurSel 1)]), %1, ctrlText 4] execVM ""createbombs.sqf""; closedialog 0; [0,0,0,[%1]] execVM ""bombshopdialog.sqf"";};", _bombshopNum] ];

    calls the next script to activate when button pressed.

    but the next script wont get any variables from previous scripts.

    should i define as follows?

    in first script:

    _bombcounter setVariable ["mycounter", _amountofbombs, true];

    in script that activates on button:

    _amountofbombs = _bombcounter getVariable "mycounter";

    and do i need to define _bombcounter in my init.sqf?

    or am i just having a brain fart?

    any help welcomed

×