‪Black Ops 3 Source Code Explorer  0.1
‪An script explorer for Black Ops 3 by ZeRoY
All Data Structures Files Functions Variables Macros
_zm_ai_dogs.csc
Go to the documentation of this file.
1 #using scripts\codescripts\struct;
2 
3 #using scripts\shared\clientfield_shared;
4 #using scripts\shared\system_shared;
5 
6 #using scripts\zm\_zm;
7 
8 #insert scripts\shared\shared.gsh;
9 #insert scripts\shared\version.gsh;
10 
11 #precache( "client_fx", "zombie/fx_dog_eyes_zmb" );
12 #precache( "client_fx", "zombie/fx_dog_fire_trail_zmb" );
13 
14 #namespace zm_ai_dogs;
15 
16 ‪REGISTER_SYSTEM( "zm_ai_dogs", &‪__init__, undefined )
17 
18 function ‪__init__()
19 {
21 
23 }
24 
25 function ‪init_dog_fx()
26 {
27  level._effect[ "dog_eye_glow" ] = "zombie/fx_dog_eyes_zmb";
28  level._effect[ "dog_trail_fire" ] = "zombie/fx_dog_fire_trail_zmb";
29 }
30 
31 function ‪dog_fx( localClientNum, oldVal, newVal, bNewEnt, bInitialSnap, fieldName, bWasTimeJump )//self = dog
32 {
33  if( newVal )
34  {
35  self._eyeglow_fx_override = level._effect[ "dog_eye_glow" ];
36  self ‪zm::createZombieEyes( localClientNum );
37  self mapshaderconstant( localClientNum, 0, "scriptVector2", 0, ‪zm::get_eyeball_on_luminance(), self ‪zm::get_eyeball_color() );
38  self.n_trails_fx_id = PlayFxOnTag( localClientNum, level._effect[ "dog_trail_fire" ], self, "j_spine2" );
39  }
40  else
41  {
42  self mapshaderconstant( localClientNum, 0, "scriptVector2", 0, ‪zm::get_eyeball_off_luminance(), self ‪zm::get_eyeball_color() );
43  self ‪zm::deleteZombieEyes(localClientNum);
44  if( isdefined( self.n_trails_fx_id ) )
45  {
46  DeleteFX( localClientNum, self.n_trails_fx_id );
47  }
48  }
49 }
‪dog_fx
‪function dog_fx(localClientNum, oldVal, newVal, bNewEnt, bInitialSnap, fieldName, bWasTimeJump)
Definition: _zm_ai_dogs.csc:31
‪CF_CALLBACK_ZERO_ON_NEW_ENT
‪#define CF_CALLBACK_ZERO_ON_NEW_ENT
Definition: version.gsh:103
‪VERSION_SHIP
‪#define VERSION_SHIP
Definition: version.gsh:36
‪createZombieEyes
‪function createZombieEyes(localClientNum)
Definition: _zm.csc:475
‪init_dog_fx
‪function init_dog_fx()
Definition: _zm_ai_dogs.csc:25
‪get_eyeball_color
‪function get_eyeball_color()
Definition: _zm.csc:681
‪CF_HOST_ONLY
‪#define CF_HOST_ONLY
Definition: version.gsh:102
‪get_eyeball_on_luminance
‪function get_eyeball_on_luminance()
Definition: _zm.csc:661
‪REGISTER_SYSTEM
‪#define REGISTER_SYSTEM(__sys, __func_init_preload, __reqs)
Definition: shared.gsh:204
‪get_eyeball_off_luminance
‪function get_eyeball_off_luminance()
Definition: _zm.csc:671
‪deleteZombieEyes
‪function deleteZombieEyes(localClientNum)
Definition: _zm.csc:481
‪__init__
‪function __init__()
Definition: _zm_ai_dogs.csc:18
‪register
‪function register()
Definition: _ai_tank.gsc:126