UGX-Mods

Call of Duty 5: World at War => Tutorial Desk => Scripting => Topic started by: jei9363 on October 30, 2014, 03:44:17 pm

Title: [Tutorial] Zombie tracker for spawning debugging
Post by: jei9363 on October 30, 2014, 03:44:17 pm
(https://www.ugx-mods.com/forum/proxy.php?request=http%3A%2F%2Fi58.tinypic.com%2F15s0qz5.jpg&hash=ceed3b2e8eb56ebc193ad3b838466bbaa4e8ef09)

I use this to see where zombies derp or take crazy long routes

in main()

Code Snippet
Plaintext
PrecacheShader( "specialty_armorvest" );
thread track_zombies();


Code Snippet
Plaintext
track_zombies()
{
zombie_shader =  "specialty_armorvest";
while(1)
{
zombies = getaiarray( "axis" );
players = get_players();

hud = [];

for (i = 0; i < zombies.size; i++)
{

if(!isDefined(zombies[i].waypoint))
{
zombies[i].waypoint = NewClientHudElem(players[0]);
zombies[i].waypoint setShader(zombie_shader,64,64);
zombies[i].waypoint setWaypoint( true, zombie_shader);
zombies[i].waypoint SetTargetEnt(zombies[i]);
zombies[i].waypoint.alpha = .8;
}


}
wait 1;
}
}

in zombiemode_spawner.gsc

Code Snippet
Plaintext
zombie_death_event( zombie )
{
zombie waittill( "death" );
zombie thread zombie_eye_glow_stop();

zombie.waypoint Destroy(); //ADD THIS
Title: Re: [Tutorial] Zombie tracker for spawning debugging
Post by: HitmanVere on October 30, 2014, 03:48:50 pm
Might want to add something else than Cherry shader, since not everyone has that, lol
Title: Re: [Tutorial] Zombie tracker for spawning debugging
Post by: jei9363 on October 30, 2014, 03:51:20 pm
good call. but yeah just pick anything specialty_ in raw/materials