Page MenuHomeFeedback Tracker

An error in BIS_fnc_hasItem
New, NormalPublic

Description

In the 2.12 version I started to get this error in logs:

Error in expression <orEach everyContainer _this;
 	[false, _found] select !isNil "_found"
 };
 if (_>
 Error position: <_found] select !isNil "_found"
 };
 if (_>
 Error Неопределенная переменная в выражении: _found
 File /temp/bin/A3/Functions_F/Inventory/fn_hasItem.sqf..., line 47

Can't find any problems in function calls in my scripts - and, more of that, nothing changed in those parts from previous versions.

Details

Severity
None
Resolution
Open
Reproducibility
Random
Operating System
Windows 7 x64
Category
General

Event Timeline

MaxP created this task.Apr 17 2023, 9:17 AM
MaxP updated the task description. (Show Details)Apr 17 2023, 9:27 AM
MaxP changed Reproducibility from Sometimes to Random.
dedmen added a subscriber: dedmen.May 1 2023, 5:38 PM

That function apparently expects to be called in "unscheduled" code

https://community.bistudio.com/wiki/Scheduler#Unscheduled_Environment

In there, undefined varibales like that will not throw errors

MaxP added a comment.May 1 2023, 6:14 PM

Hmm... Thanks. I think this info should be added to wiki.

This comment was removed by LouMontana.