Skip to content

Function ALiVE_fnc_HashGet causes an Undefined variable error in function ALiVE_fnc_ProfileNameSpaceLoad #791

@scameronde

Description

@scameronde

Prerequisites

  • Can you reproduce the problem using ALiVE and CBA Only?
  • Are you running the latest version of ALiVE ?
  • Are you running the latest version of CBA_A3?
  • Have you attached an unbinarized SQM?
  • Have you attached your RPT (If the issue relates to data, also attach Server RPT and ALiVE Plugin Log)?
  • Have you attached screenshots of the Parameters set on the offending Module?

Description

In certain conditions, the function ALiVE_fnc_ProfileNameSpaceLoad throws an error and returns an isNil value.

Steps to Reproduce

  1. start a new scenario with local data persistence (so basically isNil (profileNamespace getVariable _mission))
  2. call "my_var" call ALiVE_fnc_ProfileNameSpaceLoad -> returns false
  3. server save scenario
  4. call "my_var" call ALiVE_fnc_ProfileNameSpaceLoad -> ALiVE_fnc_HashGet throws an error
  5. call ["my_var", true] call ALiVE_fnc_ProfileNameSpaceSave then call "my_var" call ALiVE_fnc_ProfileNameSpaceLoad -> returns true

Expected behavior: [What you expected to happen]

Step 4 should not throw an error. It might be OK to return false like in step 2 (the case with no initialized profile data)

Actual behavior: [What actually happened]

Step 4 throws an error and the function ALiVE_fnc_ProfileNameSpaceLoad, which it should not.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions