UGX-Mods Login

or login with an authentication provider below
Sign In with Google
Sign In with Twitter
Sign In with Discord
Sign In with Steam
Sign In with Facebook
Sign In with Twitch

Deactivate risers

HOT
broken avatar :(
Created 6 years ago
by Doodles_Inc
0 Members and 1 Guest are viewing this topic.
3,631 views
broken avatar :(
×
broken avatar :(
Location: br
Date Registered: 20 April 2016
Last active: 2 years ago
Posts
145
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Member
My Contact & Social Links
More
Personal Quote
if I surprised you, you had underestimated me
Signature
if I surprised you, it was because you underestimated me
×
Doodles_Inc's Groups
Doodles_Inc's Contact & Social LinksdoodlescriminoserDoodles_IncDoodlesInc
Is there any way I can deactivate a riser/spawner? Or any way to make zombies spawn only in the zone players are? Im making a map that has a moving wall wich will start closing the map, so I need zombies to stop spawning on the closed areas.
Thanks.
Last Edit: July 08, 2018, 07:54:16 pm by Doodles_Inc
This topic contains a post which is marked as the Best Answer. Click here to view it.
broken avatar :(
×
broken avatar :(
Location: gb
Date Registered: 24 September 2016
Last active: 3 years ago
Posts
144
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
ZombieSlayerr115
Signature
Please. Save me.
×
isaacscott935's Groups
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
isaacscott935's Contact & Social LinksZombieSlayerr115isaac935
To deactivate a riser, all you need to do is delete the script_struct that the zombies are spawning from and remove the:

Code Snippet
Plaintext
script_string     riser

from your zombies' KVPs.

For deleting zombies which are in closed areas, I'm pretty sure you can use:

Code Snippet
Plaintext
zombie_spawn = getEntArray("zone_name_spawners","targetname");
zone = getEnt("zone_name","targetname");

if ( zombie_spawn istouching( zone ) )
{
      zombie_spawn Delete();
}

I'm pretty sure that will work. I haven't actually tested it though.
broken avatar :(
×
broken avatar :(
Location: gbMilton Keynes
Date Registered: 17 January 2014
Last active: 4 years ago
Posts
6,877
Respect
1,004Add +1
Forum Rank
Immortal
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Signature
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 ;)
×
Harry Bo21's Groups
Donator ♥ Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
Harry Bo21's Contact & Social Links[email protected]HarryBo21HarryBo000
Can’t use getentarray on structs...
broken avatar :(
×
broken avatar :(
Location: gb
Date Registered: 24 September 2016
Last active: 3 years ago
Posts
144
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
ZombieSlayerr115
×
isaacscott935's Groups
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
isaacscott935's Contact & Social LinksZombieSlayerr115isaac935
Can’t use getentarray on structs...

Scheiße

Double Post Merge: July 08, 2018, 12:54:45 pm
Can’t use getentarray on structs...

I wasn't using getEntArray on a struct, I was using it on the zombie spawner entities.

Last Edit: July 08, 2018, 12:54:45 pm by isaacscott935
broken avatar :(
×
broken avatar :(
Location: br
Date Registered: 20 April 2016
Last active: 2 years ago
Posts
145
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Member
My Contact & Social Links
More
Personal Quote
if I surprised you, you had underestimated me
×
Doodles_Inc's Groups
Doodles_Inc's Contact & Social LinksdoodlescriminoserDoodles_IncDoodlesInc
Ok I will test this now.

Double Post Merge: July 08, 2018, 07:18:34 pm
Scheiße

Double Post Merge: July 08, 2018, 12:54:45 pm
I wasn't using getEntArray on a struct, I was using it on the zombie spawner entities.
Hey, so are we deleting the spawners or the risers? I just have one spawner in my map wich is the The Giant one.
Last Edit: July 08, 2018, 07:18:34 pm by Doodles_Inc
broken avatar :(
×
broken avatar :(
Location: gb
Date Registered: 24 September 2016
Last active: 3 years ago
Posts
144
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
ZombieSlayerr115
×
isaacscott935's Groups
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
isaacscott935's Contact & Social LinksZombieSlayerr115isaac935
Delete the struct which the zombies are spawning from.

And then remove the script_string from the zombie spawner.

Also, why don’t you want risers? Without them, they will just appear in the map without an animation.
broken avatar :(
×
broken avatar :(
Location: br
Date Registered: 20 April 2016
Last active: 2 years ago
Posts
145
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Member
My Contact & Social Links
More
Personal Quote
if I surprised you, you had underestimated me
×
Doodles_Inc's Groups
Doodles_Inc's Contact & Social LinksdoodlescriminoserDoodles_IncDoodlesInc
Delete the struct which the zombies are spawning from.

And then remove the script_string from the zombie spawner.

Also, why don’t you want risers? Without them, they will just appear in the map without an animation.
Okay so I think I am mixing things, for me the riser is where the zombies spawn and the spawner in what set's wich model of zombie will spawn.

I didn't understand wich one of these the code should delete, as HarryBo said I can't get the a array of structs, but, I just have one spawner, so how could I set a spawner per zone?

Double Post Merge: July 08, 2018, 07:41:00 pm
Delete the struct which the zombies are spawning from.

And then remove the script_string from the zombie spawner.

Also, why don’t you want risers? Without them, they will just appear in the map without an animation.
Also, how would I remove the script_string from the spawner?
Last Edit: July 08, 2018, 08:03:05 pm by Doodles_Inc
broken avatar :(
×
broken avatar :(
Location: gb
Date Registered: 24 September 2016
Last active: 3 years ago
Posts
144
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
ZombieSlayerr115
×
isaacscott935's Groups
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
isaacscott935's Contact & Social LinksZombieSlayerr115isaac935
Okay so I think I am mixing things, for me the riser is where the zombies spawn and the spawner in what set's wich model of zombie will spawn.
(Image removed from quote.)(Image removed from quote.)
I didn't understand wich one of these the code should delete, as HarryBo said I can't get the a array of structs, but, I just have one spawner, so how could I set a spawner per zone?

Double Post Merge: July 08, 2018, 07:41:00 pm
Also, how would I remove the script_string from the spawner?

Just delete the script_struct (the red box). I realised there’s no need to remove any KVPs.

Now in the script, add:

Code Snippet
Plaintext
zombie_spawn = getEnt("zone_name_spawners","targetname");
zone = getEnt("zone_name","targetname");

if ( zombie_spawn istouching( zone ) )
{
      zombie_spawn Delete();
}




Double Post Merge: July 08, 2018, 08:16:00 pm
To get one spawner per zone just duplicate the zombie spawner but with each duplicate, change the name of the zone in the targetname.
Last Edit: July 08, 2018, 08:16:00 pm by isaacscott935
broken avatar :(
×
broken avatar :(
Location: br
Date Registered: 20 April 2016
Last active: 2 years ago
Posts
145
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Member
My Contact & Social Links
More
Personal Quote
if I surprised you, you had underestimated me
×
Doodles_Inc's Groups
Doodles_Inc's Contact & Social LinksdoodlescriminoserDoodles_IncDoodlesInc
Just delete the script_struct (the red box). I realised there’s no need to remove any KVPs.

Now in the script, add:

Code Snippet
Plaintext
zombie_spawn = getEnt("zone_name_spawners","targetname");
zone = getEnt("zone_name","targetname");

if ( zombie_spawn istouching( zone ) )
{
      zombie_spawn Delete();
}




Double Post Merge: July 08, 2018, 08:16:00 pm
To get one spawner per zone just duplicate the zombie spawner but with each duplicate, change the name of the zone in the targetname.
Okay, so the code works, but the zombies don't really stop spawning.
- As you can see the round passes but zombies continue spawning on the risers that should have been deleted, OBS: My character changes because I had to restart the level to get both screenshots.

Double Post Merge: July 08, 2018, 08:55:08 pm
I also tested trying to get the EntArray for the structs but no success also.
Last Edit: July 08, 2018, 08:55:08 pm by Doodles_Inc
Marked as best answer by Doodles_Inc 6 years ago
broken avatar :(
×
broken avatar :(
Location: gbMilton Keynes
Date Registered: 17 January 2014
Last active: 4 years ago
Posts
6,877
Respect
1,004Add +1
Forum Rank
Immortal
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
×
Harry Bo21's Groups
Donator ♥ Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
Harry Bo21's Contact & Social Links[email protected]HarryBo21HarryBo000
He doesn’t know what he’s doing...

This is bo3 not waw - there is only one spawner and the structs / spawners wouldn’t necessarily be touching the zone volume anyway - PLUS a zone can be multiple volumes your only checking one...

Check zm_zonemgr.gsc - there’s “actual code” to disable riser points... struct.is_enabled or something if I recall
broken avatar :(
×
broken avatar :(
Location: gb
Date Registered: 24 September 2016
Last active: 3 years ago
Posts
144
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
ZombieSlayerr115
×
isaacscott935's Groups
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
isaacscott935's Contact & Social LinksZombieSlayerr115isaac935
He doesn’t know what he’s doing...

This is bo3 not waw - there is only one spawner and the structs / spawners wouldn’t necessarily be touching the zone volume anyway - PLUS a zone can be multiple volumes your only checking one...

Check zm_zonemgr.gsc - there’s “actual code” to disable riser points... struct.is_enabled or something if I recall

I don’t use BO3. There’s no need to be so contemptuous just because I got something wrong lol.
broken avatar :(
×
broken avatar :(
Location: br
Date Registered: 20 April 2016
Last active: 2 years ago
Posts
145
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Member
My Contact & Social Links
More
Personal Quote
if I surprised you, you had underestimated me
×
Doodles_Inc's Groups
Doodles_Inc's Contact & Social LinksdoodlescriminoserDoodles_IncDoodlesInc
He doesn’t know what he’s doing...

This is bo3 not waw - there is only one spawner and the structs / spawners wouldn’t necessarily be touching the zone volume anyway - PLUS a zone can be multiple volumes your only checking one...

Check zm_zonemgr.gsc - there’s “actual code” to disable riser points... struct.is_enabled or something if I recall
Ok thans I will search on that and try something.

Double Post Merge: July 09, 2018, 11:31:32 pm
Ok, so I didn't find that specific function BUT I found a function named enable_zone wich controls the variable for the zone "spawning_allowed", maybe I can make a disable_zone function wich set's spawning allowed for false. Gonna try it now.

Double Post Merge: July 09, 2018, 11:38:45 pm
This is the original function.
This is the disable one I just made.
Calling it from the .gsc like this.
No errors, gonna test it now.


Double Post Merge: July 09, 2018, 11:41:09 pm


Ok, so I got a error, someone knows what I'm doing wrong?

Double Post Merge: July 09, 2018, 11:43:25 pm


Gonna try doing it directly from the GSC.

Double Post Merge: July 09, 2018, 11:51:12 pm
It fucking worked, thanks for all of you that helped, respect+.
Last Edit: July 09, 2018, 11:51:13 pm by Doodles_Inc
broken avatar :(
×
broken avatar :(
Location: gbMilton Keynes
Date Registered: 17 January 2014
Last active: 4 years ago
Posts
6,877
Respect
1,004Add +1
Forum Rank
Immortal
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
×
Harry Bo21's Groups
Donator ♥ Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
Harry Bo21's Contact & Social Links[email protected]HarryBo21HarryBo000
I don’t use BO3. There’s no need to be so contemptuous just because I got something wrong lol.
then dont try to answer questions in the BLACK OPS 3 helpdesk
broken avatar :(
×
broken avatar :(
Location: gb
Date Registered: 24 September 2016
Last active: 3 years ago
Posts
144
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
ZombieSlayerr115
×
isaacscott935's Groups
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
isaacscott935's Contact & Social LinksZombieSlayerr115isaac935
I was just trying to help. You don’t need to just bring others down.
broken avatar :(
×
broken avatar :(
Location: br
Date Registered: 20 April 2016
Last active: 2 years ago
Posts
145
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Member
My Contact & Social Links
More
Personal Quote
if I surprised you, you had underestimated me
×
Doodles_Inc's Groups
Doodles_Inc's Contact & Social LinksdoodlescriminoserDoodles_IncDoodlesInc
Lol stop fighting we are a community.

Just a cool thing that I discovered, it is actually possible to get a array of strucs, you just need to use the struct namespace, like this:
Code Snippet
Plaintext
#using scripts\codescripts\struct;
structs = struct::get_array("something", "targetname");
Could've used it for my script.
Last Edit: July 10, 2018, 06:08:57 pm by Doodles_Inc

 
Loading ...