Page MenuHomeFeedback Tracker

getMissionConfigValue returns a hash instead of value
Closed, ResolvedPublic

Description

For the record, on 1.56RC but it isn't available in product version. RC isn't available in Game Version, so I hope choosing the stable branch would be correct for RC.

Based on the description in the BIKI, getMissionConfigValue seems to behave erratically. Rather than returning the relevant value as a number, text or array, it seems rather to return a hash.

Details

Legacy ID
2050722120
Severity
None
Resolution
Duplicate
Reproducibility
Always
Category
Scripting
Steps To Reproduce

General directions

  • Create a custom class in your description.ext.
  • Set a value of some sort within the class.
  • Try to fetch the value with getMissionConfigValue.

Specific example

  • Add the attached description.ext to a mission.
  • Go ingame and type the following in the debug console:

hint format["Value: %1", getMissionConfigValue "CfgAutodoor" >> "Vehicles" >> "Land_Airport_side_base_F" >> "doorList"];

  • Observe as it displays something like this in the hint dialog:

Value: 02558CB8

Additional Information

For the sake of readability, I've added the example description.ext I use as an attachment rather than pasting it here.

The following excerpts from the BIKI is what makes this seem like incorrect behaviour:

  • "Returns value of given scenario attribute from the 1st tier."
  • "Return Value: Number, String or Array, depending on the attribute value type. Nil when the attribute is undefined."

Currently, in order to get the value you still have to fall back on the old getNumber/getText/getArray commands combined with getMissionConfig.

Event Timeline

Kresjah edited Steps To Reproduce. (Show Details)Feb 14 2016, 4:45 PM
Kresjah edited Additional Information. (Show Details)
Kresjah set Category to Scripting.
Kresjah set Reproducibility to Always.
Kresjah set Severity to None.
Kresjah set Resolution to Duplicate.
Kresjah set Legacy ID to 2050722120.May 8 2016, 1:43 PM