How to change the itemindex ?

Making or wanting help making your own asset? Check in here
Post Reply
AfterDune
Retired PR Developer
Posts: 17094
Joined: 2007-02-08 07:19

Post by AfterDune »

I hope you're modding in a copy of the PR directory? Otherwise you won't be able to play online and updating may go wrong as well.

Anyway, in the weapon's tweak file, there's a line that says "ObjectTemplate.itemIndex". The number following that is the index of your weapon.

When you change that, make sure you don't cause index conflicts: each weapon MUST have a unique index -per kit-, you cannot have duplicate indices.
Image
rPoXoTauJIo
PR:BF2 Developer
Posts: 1979
Joined: 2011-07-20 10:02

Re: How to change the itemindex ?

Post by rPoXoTauJIo »

It's because you have other weapon in kit with same itemindex.
Image

assetruler69: I've seen things you smurfs wouldn't believe. Apaches on the Kashan. I watched burned down tank hulls after the launch of the single TOW. All those moments will be lost in time, like tears in rain.

Time to give up and respawn.
rPoXoTauJIo
PR:BF2 Developer
Posts: 1979
Joined: 2011-07-20 10:02

Re: How to change the itemindex ?

Post by rPoXoTauJIo »

Well, other kits have your changed weapon ;)
Run PR in windowed mode to get errorz.
Image

assetruler69: I've seen things you smurfs wouldn't believe. Apaches on the Kashan. I watched burned down tank hulls after the launch of the single TOW. All those moments will be lost in time, like tears in rain.

Time to give up and respawn.
rPoXoTauJIo
PR:BF2 Developer
Posts: 1979
Joined: 2011-07-20 10:02

Re: How to change the itemindex ?

Post by rPoXoTauJIo »

Now you see the reason why there's copies of other weapons with suffixes like _idx5 :)
Also, use '

Code: Select all

' tags for long blocks of copypasta ;)
Image

assetruler69: I've seen things you smurfs wouldn't believe. Apaches on the Kashan. I watched burned down tank hulls after the launch of the single TOW. All those moments will be lost in time, like tears in rain.

Time to give up and respawn.
Post Reply

Return to “PR:BF2 Community Modding”