Modme Forums

Utilizing Hero Weapons in the Mystery box?

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


ModmeBot:

Thread By: iEagles36
So I've been picking up the scripting for the Mod tools and I've got a pretty good handle on most things but I'm an embedded systems developer not a games developer so I'm not sure, I think but I'm clearly missing some kind of initialization for the hero weapons that isn't explicitly defined in the code. I've messed with a few scripts and my changes have taken affect but for some reason I can get the rocketshield (Wish I could turn it 90 degrees as it currently comes out sideways but...) to spawn in the box but not the DG4 or the Annihilator.



The weapons will cycle through in the box and you can see them but it refuses to return them as a final result. I've removed every other gun from the box, commented out some of the checks in the mystery box code, tried manually calling their init() functions (errors out since the clients are already registered when the RegisterSystem() is called in the using declarations), and tried including their assets in the zone delcaration but nothing I can see code in the code offers a solution. The only thing I can think of is that either A) there needs to be spawner prefab for each which would seem strange to me since it's a weapon not a map object or B) something needs to be declared in the .zone or map.gsc that isn't explicitly defined.



I can force the weapon give to give DG4s to the player but they are stuck at 0% and infinitely working until they are put back away at which point they become unavailable. That leads me to believe that the init() executes properly but there is some other function which needs to be called but isn't and also that those two Hero Weapons are available in the mod tools.



TL;DR: How can I force hero weapons to actually return from the box and not just cycle through?



Thanks in advance and sorry for any dumb questions that I asked here.


ModmeBot:

Reply By: LoGy
i managed to get the dg-4s in the box i followed this http://aviacreations.com/modme/wiki/Game%20Support/Call%20of%20Duty%20-%20Black%20Ops%203/Setting%20up%20mystery%20box%20weapons and then in "gamedata/weapons/zm/zm_levelcommon_weapons.csv" and then changed the dg-4 part to this "hero_gravityspikes_melee,hero_gravityspikes_melee,,10000,,,,,,TRUE,TRUE,FALSE,,,FALSE,TRUE,special,TRUE,TRUE,"


ModmeBot:

Reply By: iEagles36

LoGyi managed to get the dg-4s in the box i followed this http://aviacreations.com/modme/wiki/Game%20Support/Call%20of%20Duty%20-%20Black%20Ops%203/Setting%20up%20mystery%20box%20weapons and then in "gamedata/weapons/zm/zm_levelcommon_weapons.csv" and then changed the dg-4 part to this "hero_gravityspikes_melee,hero_gravityspikes_melee,,10000,,,,,,TRUE,TRUE,FALSE,,,FALSE,TRUE,special,TRUE,TRUE,"


Yep, just tried it and that worked beautifully. I guess the box logic didn't like the same weapon being both the normal and paped version but both not in the box. And both the Annihilator and DG-4 worked on the same map but it looks like they use the same progress bar for both and there were a few display glitches. I'll probably post what fixes I make to resolve that conflict in case others come looking.

Thanks for your help.