‪Black Ops 3 Source Code Explorer  0.1
‪An script explorer for Black Ops 3 by ZeRoY
archetype_direwolf.gsc
Go to the documentation of this file.
1 #using scripts\shared\ai_shared;
2 #using scripts\shared\clientfield_shared;
3 #using scripts\shared\spawner_shared;
4 #using scripts\shared\ai\behavior_zombie_dog;
5 #using scripts\shared\ai\systems\ai_interface;
6 #using scripts\shared\util_shared;
7 #using scripts\shared\system_shared;
8 
9 #insert scripts\shared\shared.gsh;
10 #insert scripts\shared\archetype_shared\archetype_shared.gsh;
11 #insert scripts\shared\version.gsh;
12 #insert scripts\shared\ai\archetype_direwolf.gsh;
13 
14 #namespace ArchetypeDirewolf;
15 
16 ‪REGISTER_SYSTEM( "direwolf", &‪__init__, undefined )
17 
18 function ‪__init__()
19 {
20  // INIT BLACKBOARD
23 
24  // REGISTER AI INTERFACE ATTRIBUTES
25  ‪ai::RegisterMatchedInterface( ‪ARCHETYPE_DIREWOLF, "sprint", false, ‪array( true, false ) );
26  ‪ai::RegisterMatchedInterface( ‪ARCHETYPE_DIREWOLF, "howl_chance", 0.3 ); // 30% chance to howl when we spot our target
27  ‪ai::RegisterMatchedInterface( ‪ARCHETYPE_DIREWOLF, "can_initiateaivsaimelee", true, ‪array( true, false ) );
28  ‪ai::RegisterMatchedInterface( ‪ARCHETYPE_DIREWOLF, "spacing_near_dist", 120 );
29  ‪ai::RegisterMatchedInterface( ‪ARCHETYPE_DIREWOLF, "spacing_far_dist", 480 );
30  ‪ai::RegisterMatchedInterface( ‪ARCHETYPE_DIREWOLF, "spacing_horz_dist", 144 );
31  ‪ai::RegisterMatchedInterface( ‪ARCHETYPE_DIREWOLF, "spacing_value", 0 ); // between -1 and 1
32 
34  {
36  "actor",
41  }
42 }
43 
44 function private ‪direwolfSpawnSetup()
45 {
46  // init the entity
47  self SetTeam( "team3" );
48  self AllowPitchAngle( 1 );
49  self setPitchOrient();
50  self setAvoidanceMask( "avoid all" );
51  self PushActors( true );
52  self ‪ai::set_behavior_attribute( "spacing_value", RandomFloatRange( -1.0, 1.0 ) );
53 
54  // enable eye glow
56 }
57 
58 // end #namespace ArchetypeDirewolf;
‪RegisterMatchedInterface
‪function RegisterMatchedInterface(archetype, attribute, defaultValue, possibleValues, callbackFunction)
Definition: ai_interface.gsc:143
‪direwolfSpawnSetup
‪function private direwolfSpawnSetup()
Definition: archetype_direwolf.gsc:44
‪VERSION_SHIP
‪#define VERSION_SHIP
Definition: version.gsh:36
‪DIREWOLF_EYE_GLOW_FX_TYPE
‪#define DIREWOLF_EYE_GLOW_FX_TYPE
Definition: archetype_direwolf.gsh:9
‪ARCHETYPE_DIREWOLF
‪#define ARCHETYPE_DIREWOLF
Definition: archetype_shared.gsh:12
‪REGISTER_SYSTEM
‪#define REGISTER_SYSTEM(__sys, __func_init_preload, __reqs)
Definition: shared.gsh:204
‪array
‪function filter array
Definition: array_shared.csc:16
‪add_archetype_spawn_function
‪function add_archetype_spawn_function(archetype, spawn_func)
Definition: ai_shared.csc:23
‪set
‪function set(str_field_name, n_value)
Definition: clientfield_shared.gsc:34
‪set_behavior_attribute
‪function set_behavior_attribute(attribute, value)
Definition: ai_shared.gsc:159
‪shouldRegisterClientFieldForArchetype
‪function shouldRegisterClientFieldForArchetype(archetype)
Definition: ai_shared.csc:72
‪register
‪function register()
Definition: _ai_tank.gsc:126
‪__init__
‪function __init__()
Definition: archetype_direwolf.gsc:18
‪DIREWOLF_EYE_GLOW_FX_CLIENTFIELD
‪#define DIREWOLF_EYE_GLOW_FX_CLIENTFIELD
Definition: archetype_direwolf.gsh:7
‪DIREWOLF_EYE_GLOW_FX_BITS
‪#define DIREWOLF_EYE_GLOW_FX_BITS
Definition: archetype_direwolf.gsh:8
‪ArchetypeZombieDogBlackboardInit
‪function ArchetypeZombieDogBlackboardInit()
Definition: behavior_zombie_dog.gsc:47