Page MenuHomeFeedback Tracker

inAreaArrayIndexes in dev/profiling stops taking indexes as input
New, NormalPublic

Description

It appears like inAreaArrayIndexes has had its behaviour changed between stable and dev/profiling, causing an error in antistasi. Unsure if it is intentional, but couldn't find any relevant patch notes in the dev changelogs.

Refs this bug in antistasi, which has some more background: https://github.com/official-antistasi-community/A3-Antistasi/issues/3488

14:45:24 Bad conversion: array
14:45:24 Error in expression <ng = _x;
private _indexes = _rebMarkers inAreaArrayIndexes [getPosATL _x, 500, 5>
14:45:24   Error position: <inAreaArrayIndexes [getPosATL _x, 500, 5>
14:45:24   Error 0 elements provided, 3 expected
14:45:24 File x\A3A\addons\core\functions\Save\fn_saveLoop.sqf..., line 169

Code in context is here: https://github.com/official-antistasi-community/A3-Antistasi/blob/93a57b5f2acc928483afdab851e232b835848dde/A3A%2Faddons%2Fcore%2Ffunctions%2FSave%2Ffn_saveLoop.sqf#L170

Details

Severity
Minor
Resolution
Open
Reproducibility
Always
Operating System
Windows 11 x64
Category
Scripting
Steps To Reproduce
  1. Load dev/profiling branch
  2. Do an antistasi community edition persistent save
  3. Error occurs

Event Timeline

hawkowl created this task.Wed, Feb 5, 1:52 AM
hawkowl renamed this task from inAreaArrayIndexes in dev/profiling stops taking indexes as output to inAreaArrayIndexes in dev/profiling stops taking indexes as input.
This comment was removed by LouMontana.
jaj22 added a subscriber: jaj22.Thu, Feb 6, 8:28 PM

Title correction:
The problem is that inAreaArrayIndexes throws an error on profiling branch if you pass it an array of marker strings as the left-hand input. This works correctly on stable 2.18.

Trivial replication:
Drop down a marker in the editor. Start mission. Run:
["marker_0"] inAreaArrayIndexes [markerPos "marker_0", 100, 100];

Returns [0] on stable. Throws RPT error on perf branch.

The behaviour with a non-existent marker is also different. Returns [] on stable, throws RPT error on perf branch.