Call of Duty: Black Ops 3 => Help Desk => Scripting => Topic started by: Warheez on December 04, 2016, 07:05:35 pm
Title: Make door open after a certain amount of kills.
Post by: Warheez on December 04, 2016, 07:05:35 pm
I am currently working on a challenge map, and i want a door to open, after the player gets 200 kills. I'm really not onto scripting, and didn't find any script for this for BO3, so please help.
Title: Re: Make door open after a certain amount of kills.
Post by: MakeCents on December 05, 2016, 06:28:19 pm
For this I would make a custom door script. Lets keep it simple at first. Have a trigger_use and a script_brushmodel. Select the trigger, then the brush, and press w. Make the trigger targetname totalkills.
In script you would get each trigger and thread a function on them. In this function you would get the triggers target, as an ent or as an array depending on your door. From here it depends how you want to open the door. Up, side, split? I find a friendly way to change you mind is to set a script_struct as the target of the door/brush, rather than using a script_vector kvp, and make it so the door will move to that structs origin from its origin.
I'm not sure how to check total kills, but I would guess checking each players kills would work, and there is stuff in _zm_stats.gsc for that.
Something like this might work, idk. I just wrote it up quick, could be fool of errors too, lol. Name script kill_doors.gsc
Title: Re: Make door open after a certain amount of kills.
Post by: Cxwh on December 10, 2016, 02:48:30 pm
I know this may sound stupid, but can't I do this when the amount of kills is reached