P

PapaReap

Member

Last active 7 years ago

  1. 8 years ago
    Thu Aug 20 19:39:43 2015

    @SpyderBlack723, this works brilliantly. I was close, but no cigar :(

    No re-write necessary unless you want to make it more clear for future people like myself looking for correct answers. I'm new to ALiVE myself, but finding it quite interesting.

    This opens up a whole new world on what our missions can include :)

    Thank you very much for your guidance.

  2. Thu Aug 20 06:03:00 2015

    Does anyone know if there a check to see if the mission has any previous custom data set without getting errors?

    For the example script below everything is fine except for my conditon check on whether or not my custom data exists, my problem is -

    isTask1complete = ["task1complete"] call ALiVE_fnc_getData 

    If it doen't already exist it will error out. My isNil check is not correct in checking this data.
    Any ideas would be welcome. Thank you.

    Custom data, set in previous mission by trigger which saves and returns "true" as it should, is -

    if (isServer) then { ["task1complete", "true"] call ALiVE_fnc_setData; }; 

    Script below -

    if (isServer) then { 
        if (isNil "isTask1Complete") then { 
            isTask1complete = "false"; publicVariable "isTask1complete"; 
        }; 
    }; 
    
    waitUntil { sleep 10; !isNil "ALIVE_profileSystemInit" }; 
    
    if (isServer && isDedicated) then { 
        if !(isNil "(['task1complete'] call ALiVE_fnc_getData)") then { // this condition check does not work!!!
            isTask1complete = ["task1complete"] call ALiVE_fnc_getData; publicVariable "isTask1complete"; 
        }; 
    }; 
  3. Tue Aug 18 07:23:34 2015
    P PapaReap joined the forum.