Modme Forums
Menu:

Multiple Pap Variants

Game Modding | Call of Duty: Black Ops 3 | Scripting


ModmeBot:

Thread By: Psh

The concept is to have a standard base weapon such as the AK47 be Pack-A-Punched into 1 of any number of Pap variants of the AK. The WAW map Dead Ship did this exact thing. The Pap variants would all be different weapons files with different stats/name/shit. If that's possible than that's great, if it's possible to go even further and to double pap a variant into a different variant instead of the retarded BO3 double pap effect system, that would be even more dope.


ModmeBot:

Reply By: natesmithzombies

You are trying to remove the double PaP effects correct? I read through the scripts and I dont want to use the word "impossible" but it is going to be a real pain in the ass. If we could edit stock scripts this would be possible, but because we cannot you cant do much about it.

All functions are private in the PaP script meaning that they can only be referenced internally from the PaP script. The functions are also locally defined so you cant change the checks through redefining a level.func.


ModmeBot:

Reply By: Psh

natesmithzombies

You are trying to remove the double PaP effects correct? I read through the scripts and I dont want to use the word "impossible" but it is going to be a real pain in the ass. If we could edit stock scripts this would be possible, but because we cannot you cant do much about it.

All functions are private in the PaP script meaning that they can only be referenced internally from the PaP script. The functions are also locally defined so you cant change the checks through redefining a level.func.

Removing the double pap effects wasn't secondary to what I wanted. What I was really hoping was possible was that 1 weapon could be randomly pap'd into 1 of many variants of that weapon.


ModmeBot:

Reply By: DTZxPorter

Psh
natesmithzombies

You are trying to remove the double PaP effects correct? I read through the scripts and I dont want to use the word "impossible" but it is going to be a real pain in the ass. If we could edit stock scripts this would be possible, but because we cannot you cant do much about it.

All functions are private in the PaP script meaning that they can only be referenced internally from the PaP script. The functions are also locally defined so you cant change the checks through redefining a level.func.

Removing the double pap effects wasn't secondary to what I wanted. What I was really hoping was possible was that 1 weapon could be randomly pap'd into 1 of many variants of that weapon.

You'd merely be hooking the pap script, from

vending_weapon_upgrade()



Which, you'd then check current_weapon for the weapon name you'd like to have alts for, here there is also a check for AAT, which you can bypass for this specific gun. The script then calls

upgrade_weapon = zm_weapons::get_upgrade_weapon( current_weapon, b_weapon_supports_aat );



Again, which you'd be bypassing for this specific weapon, and have it return at random one of the instances of the weapon you've made. This is a simple break down, all frrom _zm_pack_a_punch.gsc while I'm too busy to help, this should help anyone and or yourself get started. (As nate said, this is going to have to be mod based since map level zones don't override stock scripts)


ModmeBot:

Reply By: HitmanVere

natesmithzombies

You are trying to remove the double PaP effects correct? I read through the scripts and I dont want to use the word "impossible" but it is going to be a real pain in the ass. If we could edit stock scripts this would be possible, but because we cannot you cant do much about it.

All functions are private in the PaP script meaning that they can only be referenced internally from the PaP script. The functions are also locally defined so you cant change the checks through redefining a level.func.

For removing Double PaP effects, you can just go into zm_levelcommon_weapons.csv and set is_aat_exempt to true on all guns

Probs haxiest way to do different variants would be just to check what weapon you are holding (for example ak47_upgraded_zm) and swap it in script to random one (ak47_electric_zm), but really inefficient and you would see gun being swapped for like 0.1 seconds


ModmeBot:

Reply By: natesmithzombies

Psh
natesmithzombies

You are trying to remove the double PaP effects correct? I read through the scripts and I dont want to use the word "impossible" but it is going to be a real pain in the ass. If we could edit stock scripts this would be possible, but because we cannot you cant do much about it.

All functions are private in the PaP script meaning that they can only be referenced internally from the PaP script. The functions are also locally defined so you cant change the checks through redefining a level.func.

Removing the double pap effects wasn't secondary to what I wanted. What I was really hoping was possible was that 1 weapon could be randomly pap'd into 1 of many variants of that weapon.

I thought you were trying to go back to the old WaW pack system where adding _upgraded to the end of the weaponfile allowed for continuous PaPing.


ModmeBot:

Reply By: Psh

natesmithzombies
Psh
natesmithzombies

You are trying to remove the double PaP effects correct? I read through the scripts and I dont want to use the word "impossible" but it is going to be a real pain in the ass. If we could edit stock scripts this would be possible, but because we cannot you cant do much about it.

All functions are private in the PaP script meaning that they can only be referenced internally from the PaP script. The functions are also locally defined so you cant change the checks through redefining a level.func.

Removing the double pap effects wasn't secondary to what I wanted. What I was really hoping was possible was that 1 weapon could be randomly pap'd into 1 of many variants of that weapon.

I thought you were trying to go back to the old WaW pack system where adding _upgraded to the end of the weaponfile allowed for continuous PaPing.

no :(. I feel like I can't explain it good enough.

| Base Weapon | -------> | Pap it | --------> | Script generates a random number say 1-5 | -----> | Pap gives back a weapon with a number of 3 | ----> | Profit $$$ |

These random numbers would simply be the amount of variantions of that base weapon there are when pack-a-punched. It's not getting an MP5 from paping an AK47, it's getting a pap'd AK47 with different name/stats/etc. The whole idea here is to give more replay and RNG to paping a weapon. Instead of getting the same weapon over and over the idea is to possible to get something new every time, or until you've played the map enough. Also the each variantion of has it's own weapon file, that's the problem. Regular paping is simple, non-upgraded to upgraded, but this is like non-upgraded to upgraded(1-5). I feel like I just wrote an essay


ModmeBot:

Reply By: natesmithzombies

Psh
natesmithzombies
Psh
natesmithzombies

You are trying to remove the double PaP effects correct? I read through the scripts and I dont want to use the word "impossible" but it is going to be a real pain in the ass. If we could edit stock scripts this would be possible, but because we cannot you cant do much about it.

All functions are private in the PaP script meaning that they can only be referenced internally from the PaP script. The functions are also locally defined so you cant change the checks through redefining a level.func.

Removing the double pap effects wasn't secondary to what I wanted. What I was really hoping was possible was that 1 weapon could be randomly pap'd into 1 of many variants of that weapon.

I thought you were trying to go back to the old WaW pack system where adding _upgraded to the end of the weaponfile allowed for continuous PaPing.

no :(. I feel like I can't explain it good enough.

| Base Weapon | -------> | Pap it | --------> | Script generates a random number say 1-5 | -----> | Pap gives back a weapon with a number of 3 | ----> | Profit $$$ |

These random numbers would simply be the amount of variantions of that base weapon there are when pack-a-punched. It's not getting an MP5 from paping an AK47, it's getting a pap'd AK47 with different name/stats/etc. The whole idea here is to give more replay and RNG to paping a weapon. Instead of getting the same weapon over and over the idea is to possible to get something new every time, or until you've played the map enough. Also the each variantion of has it's own weapon file, that's the problem. Regular paping is simple, non-upgraded to upgraded, but this is like non-upgraded to upgraded(1-5). I feel like I just wrote an essay

lol it was a good essay . there is not going to be any proper way to do this but what Hitman said is prob your best option. I would make a bunch of different weapon files for each variant and a PaP version of that variant. Then always run a check on the player to see if they have the PaP variant. If they do you would randomly give them another variant that is "unPaPed" (would not have _upgraded appended to the weaponfile but would have PaP stats).

I hope that makes sense but there are limitations to this:

1) Inconsistent Switch times (like Hitman mentioned you will likely see the weapon before it is taken and switched out)

2) It will take 12 weapon files for a single weapon if you wanted 5 variants to it. That is pretty bad lol

What Porter said is also a viable option too, I just dont think people will actually be smart enough on Workshop to install 2 mods to play. 3/4 of the people cant even get a normal map to play haha


ModmeBot:

Reply By: HitmanVere

Hmmm, small idea:

Switching is inconsistant, but we could make it look like delay rather than switching to another weapon. Lets say we have while-loop that threads on all players. We look for specific weapon and we swap it, simple as that. Now comes the main point.

We have ak47_zm, regular weaponfile. We then make sure when you PaP it, it gives you ak47_upgraded_zm. We check for that in while loop and just do switch/randomInt for other variants like ak47_electric_zm etc. Now, how do we make this better? We make ak47_upgraded_zm into "empty" weapon. This would mean no name, no ammo showing and no anims. This would make it look like you get weapon after for example 0.5 seconds. Would nullify people seeing that you are just using another weaponfile and just make it look like small delay. Then maybe possibly just connect all upgraded variants, so when you upgrade ak47_electric_zm, you get ak47_acid_zm, upgrading that gives ak47_ice_zm and then goes back to ak47_electric_zm. We then have ak47_zm, ak47_upgraded_zm and five upgraded variants, so seven weaponfiles. A lot of work per gun, but oh well


ModmeBot:

Reply By: natesmithzombies

HitmanVere

Hmmm, small idea:

Switching is inconsistant, but we could make it look like delay rather than switching to another weapon. Lets say we have while-loop that threads on all players. We look for specific weapon and we swap it, simple as that. Now comes the main point.

We have ak47_zm, regular weaponfile. We then make sure when you PaP it, it gives you ak47_upgraded_zm. We check for that in while loop and just do switch/randomInt for other variants like ak47_electric_zm etc. Now, how do we make this better? We make ak47_upgraded_zm into "empty" weapon. This would mean no name, no ammo showing and no anims. This would make it look like you get weapon after for example 0.5 seconds. Would nullify people seeing that you are just using another weaponfile and just make it look like small delay. Then maybe possibly just connect all upgraded variants, so when you upgrade ak47_electric_zm, you get ak47_acid_zm, upgrading that gives ak47_ice_zm and then goes back to ak47_electric_zm. We then have ak47_zm, ak47_upgraded_zm and five upgraded variants, so seven weaponfiles. A lot of work per gun, but oh well

I havent worked with weaponfiles enough to think of this idea. It is a good one! It eliminates the delay issue but you are still looking at a bunch of weapon files lol. Although I believe the limit is huge so its really only a matter of putting in the time


ModmeBot:

Reply By: Psh

HitmanVere

Hmmm, small idea:

Switching is inconsistant, but we could make it look like delay rather than switching to another weapon. Lets say we have while-loop that threads on all players. We look for specific weapon and we swap it, simple as that. Now comes the main point.

We have ak47_zm, regular weaponfile. We then make sure when you PaP it, it gives you ak47_upgraded_zm. We check for that in while loop and just do switch/randomInt for other variants like ak47_electric_zm etc. Now, how do we make this better? We make ak47_upgraded_zm into "empty" weapon. This would mean no name, no ammo showing and no anims. This would make it look like you get weapon after for example 0.5 seconds. Would nullify people seeing that you are just using another weaponfile and just make it look like small delay. Then maybe possibly just connect all upgraded variants, so when you upgrade ak47_electric_zm, you get ak47_acid_zm, upgrading that gives ak47_ice_zm and then goes back to ak47_electric_zm. We then have ak47_zm, ak47_upgraded_zm and five upgraded variants, so seven weaponfiles. A lot of work per gun, but oh well

DankManVere and natesdankzombies are there when a Psh needs them [IMG]http://aviacreations.com/modme/emoticons/megusta.png[/IMG]/

P.S I'm not a robot


ModmeBot:

Reply By: HitmanVere

Can mark as solved now. Did while-loop that checks current weapon, then threads on player new function, which contained switch, containing all variants for each gun. Then just swap and done