Meowzors Posted October 7, 2014 Report Share Posted October 7, 2014 I am trying to check a crate for a certain number of an item.... i tried this... _playerName = name player; //line 7 _mags=magazineCargo Crate; //line 8 _weps=weaponCargo Crate; //line 9 _OreQTY={_x == "PartOre"} count _mags; _PoleQTY={_x == "ItemPole"} count _mags; ... which results in this error.... _mags=magazineCargo Crate; _weps=weaponCargo Crate> Error position: <Crate; _weps=weaponCargo Crate> Error Missing ; File mpmissions\__CUR_MP.Tavi\custom\finish_build.sqf, line 8 Can anyone tell me whats going on here??? There are no missing ; as far as I can see here... Link to comment Share on other sites More sharing options...
0 mimic Posted October 7, 2014 Report Share Posted October 7, 2014 How about this: _OreQTY={ _x == "PartOre"; } count _mags; _PoleQTY={ _x == "ItemPole"; } count _mags; Link to comment Share on other sites More sharing options...
0 Meowzors Posted October 8, 2014 Author Report Share Posted October 8, 2014 the missing semi colon in the RPT points to line 8... line 8 is: _mags=magazineCargo Crate; a semi colon inside of the count _mags is not needed ( i did however try putting one there when I originally had all my lines with "count magazoneCargo Crate"--still said missing ; ) Link to comment Share on other sites More sharing options...
0 Zupa Posted October 8, 2014 Report Share Posted October 8, 2014 well, then use a counter in the loop, thats not that bad ^^ Link to comment Share on other sites More sharing options...
0 Zupa Posted October 8, 2014 Report Share Posted October 8, 2014 https://community.bistudio.com/wiki/magazineCargo magazineCargo is arma 3 only u need to use the following https://community.bistudio.com/wiki/getMagazineCargo _OreQTY={ if(_x == "PartOre")then{ _mags select 1 select forEachIndex; }; } forEach_mags select 0; _PoleQTY={ if(_x == "ItemPole")then{ _mags select 1 select forEachIndex; }; } forEach _mags select 0; Link to comment Share on other sites More sharing options...
0 Meowzors Posted October 8, 2014 Author Report Share Posted October 8, 2014 Ah I looked at that page like 20 times and didn't see that it was for arma 3 lol thanks Link to comment Share on other sites More sharing options...
0 Zupa Posted October 8, 2014 Report Share Posted October 8, 2014 put as launchparameter the following: -showScriptErrors it will show u all the client side errors in a black window INgame ^^ when it happens very usefull for dev Link to comment Share on other sites More sharing options...
0 Meowzors Posted October 8, 2014 Author Report Share Posted October 8, 2014 Always do. Only error it showed was about a missing semi colon should have been undefined variable I feel like Link to comment Share on other sites More sharing options...
Question
Meowzors
I am trying to check a crate for a certain number of an item....
i tried this...
which results in this error....
Can anyone tell me whats going on here??? There are no missing ; as far as I can see here...
Link to comment
Share on other sites
7 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now