GSC reference › Built-in
IsInScriptedState()
Built-in (engine)
Server
AI Called on: actor
Checks if actor is in a scripted state (animscripted, custom, negotiation)
Signature
<actor> IsInScriptedState()
Called on an entity: actor IsInScriptedState(...)
Example (from Treyarch's docs)
self isInScripteState()
Real uses in BO3's scripts
Called 15 times in the decompiled scripts. A few, zombies first:
- scripts/shared/ai/archetype_aivsaimelee.gsc, line 289
if(enemy isinscriptedstate()) - scripts/shared/ai/archetype_notetracks.gsc, line 228
if(isactor(entity) && entity isinscriptedstate()) - scripts/shared/ai/archetype_utility.gsc, line 2848
if(behaviortreeentity isinscriptedstate()) - scripts/cp/bonuszm/_bonuszm.gsc, line 871
if(self isinscriptedstate()) - scripts/cp/bonuszm/_bonuszm_sound.gsc, line 283
if(self isinscriptedstate())
Related built-ins
- AnimScripted()Runs an animscript on an entity.
- SetZBarrierPieceState()Set's the state of the piece indexed in the zbarrier ent.
- StopAnimScripted()Halts animscript on this entity.
- GetZBarrierPieceState()Returns the state of the piece indexed in the zbarrier ent.
- Objective_State()Set a state for the objective
- SetLoopState()Set pitch and volume per entity/alias
- IsPlayingAnimScripted()Returns true if the entity is playing in scripted animation.
- GetZBarrierPieceIndicesInState()Returns an array of integer indices of the zbarriers pieces that are in the specified state.
- GetHeliDamageState()Returns the damage state of the heli.
- EndExtraCamAnimScripted()Ends the extracam camera script on a player.
- SetCorpseGibState()Sets the gib state for the body rendering.
- SetLightingState()Changes lighting state for the map
New to GSC?
Start with the basics, or paste a compile error to get the fix.
Built-in descriptions, parameters and examples come from Treyarch's BO3 mod tools docs. Usage links point at shiversoftdev/t7-source (decompiled BO3 scripts).