Hi again guys and gals, I have been working on what I believe to be the widows wine perk from black ops 3 the features so far: 1) every zombie that hits you behind a window instantly dies 2) when hit by a zombie behind the window you get (depending on your health) 25 - 250 points - the more hits you take in a row the higher the awarded score is. - a visual example: - 100% health = +25 points - 80% health = +50 points - 60% health = +100 points - 40% health = +150 points - 20% health = +250 points
a few hours ago the achievements for bo3 zombies where released and 1 of them talks about getting zombies stuck when hit by a grenade explosion which leads to my question:
I am pretty sure I could freeze zombies in place by setting there move speed to 0 but I need a way to get an array of the zombies I hit by a grenade so I was wondering if any scripters know of a way to get an array of zombies and/or players hit by a grenade explosion
I often wondered how this was done myself. I didn't think you could adjust time scale for just one zombie but I don't know. zombie_move_speed is only an integer while it sets up the zombie speed, then becomes a string, I am pretty sure, of walk, run, or sprint. Which is used for getting the correct anim to play. Perhaps the freeze is another set of anims? You could make an array of these new anims (you or someone would make and precache) and select from them?
If you find something like that to be true, and you can make these anims, then you could use in script:
Code Snippet
Plaintext
//this would be done in script somewhere only once I think //level._freeze_anims = []; //level._freeze_anims[level._freeze_anims.size] = %freeze1; //level._freeze_anims[level._freeze_anims.size] = %freeze2;//and so on
//This would be done in your script zombies = getaiarray("axis"); radius = spawn("trigger_radius", grenade.origin);
for(i = 0; i < zombies.size; i++) { if(zombies[i] isTouching(radius)) { //zombies[i].zombie_move_speed = 0; // I want to freeze the zombies here zombies[i] animscripted("freeze", zombies[i].origin, zombies[i].angles, level._freeze_anims[randomint(level._freeze_anims.size)]); playfx(level._effect["spider_web"], zombies[i].origin); } }
Of course I am just guessing, maybe there is a much simpler way?
Last Edit: October 06, 2015, 12:34:08 pm by MakeCents
bluntstuffy made a powerup that does something similar but slows them down rather than stop them. you could use the portion that slows them down for this and slow them down to a point where it looks like they are standing still
bluntstuffy made a powerup that does something similar but slows them down rather than stop them. you could use the portion that slows them down for this and slow them down to a point where it looks like they are standing still
Nice, that would be much easier. I had heard before someone say you couldn't stop them, only slow them down. This must have been what they were talking about.
While doing my map I found something that stops them (but they will continue trying to attack) and it's really simple. Don't know if it is going to have the effect you want but here's my idea: Just link the zombies to anything and unlink them again. Like this:
Code Snippet
Plaintext
linker = getEnt( blah,blah ); // you can use anything scriptable
// grenade stuff
for( i = 0; i < zombies.size; i++ ) { zombies[i] enableLinkTo(); zombies[i] linkTo( linker ); } wait(blah); // the time to wait until they move again for( i = 0; i < zombies.size; i++ ) { zombies[i] unlink(); }
Thanks @Soy-Yo that worked like a charm all thats left to do is make the effect, thanks again
You're welcome. What is a bug for me, is the solution for you. Also I forgot to say that you need to link zombies to something that is never going to be moved (with script I mean). Because there could be some idiot like me who decides to make a map where all rooms move. And if the entity you linked zombies to moves, zombies will move with it.
You're welcome. What is a bug for me, is the solution for you. Also I forgot to say that you need to link zombies to something that is never going to be moved (with script I mean). Because there could be some idiot like me who decides to make a map where all rooms move. And if the entity you linked zombies to moves, zombies will move with it.
thanks for the heads up but I actually found this out the hard way, my zombies where bouncing up and down on my map. anyways I finished the widows fine perk it features what I said above and also when a zombie survives your grenade explosion it(crawlers as well) will get stuck in a web.
If you want scripts / features made for you, then contact me by PM or email / skype etc it will cost you tho so if you have no intention of reciprocating don't even waste my time
While doing my map I found something that stops them (but they will continue trying to attack) and it's really simple. Don't know if it is going to have the effect you want but here's my idea: Just link the zombies to anything and unlink them again. Like this:
Code Snippet
Plaintext
linker = getEnt( blah,blah ); // you can use anything scriptable
// grenade stuff
for( i = 0; i < zombies.size; i++ ) { zombies[i] enableLinkTo(); zombies[i] linkTo( linker ); } wait(blah); // the time to wait until they move again for( i = 0; i < zombies.size; i++ ) { zombies[i] unlink(); }
zombie.ignoreall = true;
and put a check in find_flesh() in zombiemode spawner to freeze the loop till they should be able to move again
Freeze - to become hardened into ice or into a solid body;
Not stop chasing player and still sit there and derp out, lol.
Anyway, you could also spawn points of interest if you just want them to stay at a certain spot. You could also continuously teleport the zombie to the same place. Looping one of the board/window reach or frustration animation, randomly, would be better for this imo, because it would look like they were stuck in something. Many ways to derp zombies.
Last Edit: October 09, 2015, 01:53:36 pm by MakeCents
Freeze - to become hardened into ice or into a solid body; change from the liquid to the solid state by loss of heat.
Not stop chasing player and still sit there and derp out, lol.
Anyway, you could also spawn points of interest if you just want them to stay at a certain spot. You could also continuously teleport the zombie to the same place. Looping one of the board/window reach our frustration animations would be better for this imo, because it would look like they were stuck in something. Many ways to derp zombies.
you could also set each zombies goal position to their origin that way they dont move and then play the window taunt anim. thats how they make the zombies stand in their final location during the after game intermission
you could also set each zombies goal position to their origin that way they dont move and then play the window taunt anim. thats how they make the zombies stand in their final location during the after game intermission
I did this in zombie_gib_on_damage under the watitill damage line and it looked pretty cool.
Code Snippet
Plaintext
self waittill( "damage", amount, attacker, direction_vec, point, type ); //don't use recon, I used it for testing cause it always returns true if(isDefined(attacker) && attacker hasperk("specialty_recon") && (type == "MOD_GRENADE" || type == "MOD_GRENADE_SPLASH")) self thread WidowsWine();
and this above the function:
Code Snippet
Plaintext
WidowWineTimer(){ self endon("spiderweb"); wait(5);//the length of the effect self.spiderweb unlink(); self.spiderweb delete(); self.spiderweb = undefined; } WidowsWine(){ self notify("spiderweb"); self thread WidowWineTimer(); if(!isdefined(self.spiderweb)){ self.spiderweb = spawn("script_model", self.origin ); self.spiderweb setmodel("tag_origin"); self.spiderweb linkto(self); playfxontag(level._effect["switch_sparks"],self.spiderweb,"tag_origin");//i don't have spider fx so picked another looping fx while(isDefined(self) && IsAlive(self) && isDefined(self.spiderweb) && self.has_legs){ self animscripted("spiderstall", self.origin, self.angles, level._zombie_board_taunt["zombie"][randomint(6)]); self waittill("spiderstall"); } self zombie_think(); }
}
One issue I saw, with the other scripts posted here, is with the fx, they will keep playing even if the zombie is dead or gibbed. You may want to spawn something and link it, like above, to the zombie or keep moving it to the zombies origin or something to play the fx on to delete or move when the zombie is gibbed or dies.
Last Edit: October 10, 2015, 02:56:16 am by MakeCents