Jump to content
Sign in to follow this  
Alpine_gremlin

Invalid Number/Generic Error in Expression

Recommended Posts

baseCampItems = [sBag1,sBag2,tin,fuel,tent1,tent2,wood,box,can1,can2,shovel,fire1,axe,stump,arsenalBox];

 

Can I not pass object variable names into an array? I feel like I should know this by now 😕

Share this post


Link to post
Share on other sites
13 hours ago, opusfmspol said:

fuel is a command.  Needs to be named something else....

Also a good practice to make variable names as unique as possible, to avoid complications with script commands, BI variables as well as other third party scripts/addons.

In case of the threadstarter variables could come with a prefix like  AG_, then probably some descriptor like _obj_ or _rsc_, so in case of fuel it could be AG_rsc_fuel or AG_obj_jerryCan1 etc.

Well worth it in the long run.

 

Cheers

  • Like 1
  • Thanks 1

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×