‪Black Ops 3 Source Code Explorer  0.1
‪An script explorer for Black Ops 3 by ZeRoY
utility.gsh
Go to the documentation of this file.
1 // node spawnflag macros
2 #define ISNODEDONTRIGHT(__node) ( SPAWNFLAG( __node, SPAWNFLAG_PATH_DONT_RIGHT ))
3 #define ISNODEDONTLEFT(__node) ( SPAWNFLAG( __node, SPAWNFLAG_PATH_DONT_LEFT ))
4 
5 // node type macros
6 #define NODE_COVER_LEFT(_node) (_node.type == "Cover Left")
7 #define NODE_COVER_RIGHT(_node) (_node.type == "Cover Right")
8 #define NODE_COVER_PILLAR(_node) (_node.type == "Cover Pillar")
9 #define NODE_COVER_STAND(_node) (_node.type == "Cover Stand" || _node.type == "Conceal Stand")
10 #define NODE_COVER_CROUCH(_node) (_node.type == "Cover Crouch" || _node.type == "Cover Crouch Window" || _node.type == "Conceal Crouch" )
11 #define NODE_EXPOSED(_node) (_node.type == "Exposed")
12 #define NODE_GUARD(_node) (_node.type == "Guard")
13 #define NODE_PATH(_node) (_node.type == "Path")
14 
15 #define NODE_CONCEALED(_node) (_node.type == "Conceal Crouch" || _node.type == "Conceal Stand")
16 
17 #define NODE_TYPE_COVER(_node) ( NODE_COVER_LEFT(_node) || NODE_COVER_RIGHT(_node) || NODE_COVER_PILLAR(_node) || NODE_COVER_STAND(_node) || NODE_COVER_CROUCH(_node) )
18 
19 // node stances macros
20 #define NODE_SUPPORTS_STANCE_STAND(__node) ( SPAWNFLAG( __node, SPAWNFLAG_PATH_STANCE_STAND ))
21 #define NODE_SUPPORTS_STANCE_CROUCH(__node) ( SPAWNFLAG( __node, SPAWNFLAG_PATH_STANCE_CROUCH ))
22 #define NODE_SUPPORTS_STANCE_PRONE(__node) ( SPAWNFLAG( __node, SPAWNFLAG_PATH_STANCE_PRONE ))
23 
24 
25 // Yaw and Pitch utility macros
26 #define GET_YAW(__self,__org) (VectorToAngles(__org-__self.origin)[1])
27 #define GET_YAW_TO_ORIGIN180(__self,__org) (AngleClamp180(__self.angles[1] - VectorToAngles(__org-__self.origin)[1]))
28 #define GET_PITCH(__self,__org) (VectorToAngles(__org-__self.origin)[0])
29 #define GET_YAW2D(__self,__org) (VectorToAngles((__org[0], __org[1], 0)-(__self.origin[0], __self.origin[1], 0))[1])