Jump to content
syrasia

[SOLVED] How to add information to object in WeaponHolder?

Recommended Posts

Hey there,

 

I am working with WeaponHolder and I need to add additional information to each object/item.

 

Only solution I could come up with until now is a additional array on the holder with the data, parallel to the object count.

I have done some tests, and it seem to be consistent, but still want to ask the community on this: 

Do the objects always get the same order? I am using "weaponCargo" to get the items-names. My observation is, you get an array with the order, in witch they got add to the holder.

 

Or can I add a variable to the objects directly? Would be way cleaner. Can't find that solution tho. Weird, as mags do have round count, right?

Share this post


Link to post
Share on other sites

You can track magazines by netID and backpacks directly by the object instance, that’s about it

  • Like 2
  • Thanks 1

Share this post


Link to post
Share on other sites

Alright, that is a solid answer. Thanks KK.

 

So I will do with arrays and saving it parallel. I call this solved and will do my scripting around it.

  • Like 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

×