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

[tutorial] Teleportation Zombie Mini Boss

broken avatar :(
Created 7 years ago
by death_reaper0
0 Members and 1 Guest are viewing this topic.
6,611 views
broken avatar :(
×
broken avatar :(
Location: aupotato
Date Registered: 27 September 2013
Last active: 3 years ago
Posts
588
Respect
Forum Rank
Zombie Enslaver
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Signature
respect the dead

donates greatly appreciated :) paypal.me/F3ARxReaper666
discord server:
https://discord.gg/tsGHW99
×
death_reaper0's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
this is a script i made for a zombie that would randomly spawn in place of a normal zombie and teleport after every few seconds a few meters away from where it was. nothing too spectacular but it can throw people off guard if one spawns in the middle of a horde.

for this tutorial i will be using the model called "c_54i_cqb_fullbody" for the zombie, if you want a different one change this at any point in the tutorial to your own model.

first go into your maps zone file and add

Code Snippet
Plaintext
xmodel,c_54i_cqb_fullbody

then go into your mapname.gsc and add
Code Snippet
Plaintext
#precache("xmodel", "c_54i_cqb_fullbody");
above main

then place this

Code Snippet
Plaintext
	level.teleport_zombie_reap_dist = 190;				//teleporting distance
level.teleport_zombie_reap_time_min = 3; //minimum time to teleport
level.teleport_zombie_reap_time_max = 3; //max time to teleport (time to teleport random between min and min + max)
level.teleport_zombie_reap_health_multiplier = 3; //health modifier, this many times more health than a normal zombie
level.teleport_zombie_reap_percent = 15; //spawn rate percent, this many out of 100 will become teleporters
level thread reap_special_zombies();


under

Code Snippet
Plaintext
	level.pathdist_type = PATHDIST_ORIGINAL;


then place this at the bottom of mapname.gsc

Code Snippet
Plaintext
function reap_special_zombies()
{
while(1)
{
zombies = getaispeciesarray( "axis", "all" );
for( i = 0; i < zombies.size; i++ )
{
if( !isDefined( zombies[i].reap_special_zombies ) )
{
zombies[i].reap_special_zombies = true;
if(randomint(100) < level.teleport_zombie_reap_percent)
zombies[i] thread reap_special_zombie_teleporter();
}
}
wait 0.1;
}
}

function reap_special_zombie_teleporter()
{
self endon( "death" );
self.is_teleport_zombie = true;
self.force_gib = false;
self.gibbed = true;
self.maxhealth = self.maxhealth*level.teleport_zombie_reap_health_multiplier;
self.health = self.health*level.teleport_zombie_reap_health_multiplier;
self.is_on_fire = true;
self.no_gib = 1;
self.head_gibbed = true;
self.needs_run_update = true;
self.allowpain = false;
self.ignore_nuke = true;
self.is_boss = true;
self detach( self.headModel, "" );
self detach( self.hatModel, "" );
self setmodel( "c_54i_cqb_fullbody" );
while(1)
{
wait randomint(level.teleport_zombie_reap_time_min)+level.teleport_zombie_reap_time_max;
front = AnglesToForward(self.angles);
dist_pos = self.origin + VectorScale( front, level.teleport_zombie_reap_dist );
if( bullettracepassed( self.origin + (0, 0, 10), dist_pos + (0, 0, 10), false, undefined ) &&
(IsDefined(self.in_the_ground) && self.in_the_ground == false || !IsDefined(self.in_the_ground)))
{
if( IsVehicle( self ) )
self clientfield::set( "tesla_shock_eyes_fx_veh", 1 );
else
self clientfield::set( "tesla_shock_eyes_fx", 1 );
self PlaySound( "zmb_elec_jib_zombie" );
wait .2;
self hide();
wait .2;
self forceteleport(dist_pos);
wait .2;
self show();
wait .2;
if( IsVehicle( self ) )
self clientfield::set( "tesla_shock_eyes_fx_veh", 0 );
else
self clientfield::set( "tesla_shock_eyes_fx", 0 );
}
}
}

that should be it, if you have any questions or issues let me know
broken avatar :(
×
broken avatar :(
Location: usNew Jersey
Date Registered: 30 July 2013
Last active: 1 month ago
Posts
271
Respect
Forum Rank
Mr. Elemental
Primary Group
Community Mapper
My Groups
More
My Contact & Social Links
More
Personal Quote
fk
Signature
iPlay - Facts                               
Hex Tower - Facts
Andromeda - Facts
Octagonal Ascension - Facts
iPlay v2 - Facts
Eclipse - Facts
MW2 Rust - Facts
Gulag - Facts
Decagon - Facts
---------------------------------------------- BO3
Scrapyard - Facts
Rust 2.0 - Facts
Rust MP - Facts
Gulag Again ffs - Facts
Hex Tower - Facts
Octagon - Facts
Decagon - Facts
Cataclysm - Facts
Dome - Bland
×
Psh's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Psh's Contact & Social LinksihaZzRaBieZAskI_haZzZ_RaBieZzPshZombies
Anything to add variety, sounds to me like that blue zombie from the ZCT mod :gusta:
broken avatar :(
×
broken avatar :(
Location: scotland
Date Registered: 2 September 2013
Last active: 2 weeks ago
Posts
379
Respect
Forum Rank
Perk Hacker
Primary Group
Community Mapper
My Groups
More
My Contact & Social Links
More
Personal Quote
Ping998
Signature
"My maps might not be the best looking, or the most hyped, but I still release them in hopes that they can make others somewhat happy"

- Ping
×
Ping998's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Ping998's Contact & Social LinksZPing998Ping998Ping998CreepersAreAwesome
Anything to add variety, sounds to me like that blue zombie from the ZCT mod :gusta:

Exactly what I was thinking. They've returned... :alone:
broken avatar :(
×
broken avatar :(
Location: cavancouver island
Date Registered: 25 January 2014
Last active: 2 years ago
Posts
49
Respect
Forum Rank
Legless Crawler
Primary Group
Member
Personal Quote
noVADex*
Signature
A bird gripped in your hand.. is better than a #2 in the bush. ..$h|+ ....piss on that zombie!
×
novadex's Groups
novadex's Contact & Social Links
 This is really cool, but in testing i found it messes up Dog rounds. Some dogs become zombies walking backwards on all fours. lol
broken avatar :(
×
broken avatar :(
Location: aupotato
Date Registered: 27 September 2013
Last active: 3 years ago
Posts
588
Respect
Forum Rank
Zombie Enslaver
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
×
death_reaper0's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
This is really cool, but in testing i found it messes up Dog rounds. Some dogs become zombies walking backwards on all fours. lol
i dont use dog rounds in my mod so i didnt know, should of thought of it though, i'll fix this tomorrow
broken avatar :(
×
broken avatar :(
Location: cavancouver island
Date Registered: 25 January 2014
Last active: 2 years ago
Posts
49
Respect
Forum Rank
Legless Crawler
Primary Group
Member
Personal Quote
noVADex*
×
novadex's Groups
novadex's Contact & Social Links
 Another thing ive noticed after playing with these guys further is their teleportation function is not limted to a player volume ( teleporting outside zones and even though monster clipping ). stairs and floors/levels they can even temporally teleport  in the air, skipping past traversals and nodes.

 I really think these guys are valuable, this is a really good idea, nice work, and thanks for looking into fixing them up. 

broken avatar :(
×
broken avatar :(
Location: scotland
Date Registered: 2 September 2013
Last active: 2 weeks ago
Posts
379
Respect
Forum Rank
Perk Hacker
Primary Group
Community Mapper
My Groups
More
My Contact & Social Links
More
Personal Quote
Ping998
×
Ping998's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Ping998's Contact & Social LinksZPing998Ping998Ping998CreepersAreAwesome
Hey for some reason the fx and sounds don't work for me?

Any suggestions for a fix? :)

 
Loading ...