Difference between revisions of "01C2"

From GTAMods Wiki
Jump to navigation Jump to search
Line 1: Line 1:
{{OpCode
+
{{Icon|trilogy}}
| ini        = 01C2=1,%1d%
+
<hr />
| description = Removes references to an actor
+
'''Description'''
| p1          = Actor handle
+
: Marks the character as no longer needed
| game        = GTA3, Vice City, San Andreas
+
'''Syntax'''
| native      = [[MARK_CHAR_AS_NO_LONGER_NEEDED]]
+
: 01C2: remove_references_to_actor [''char handle'']
}}
+
'''Parameter'''
 +
: [''char handle'']
 +
:: The handle of the character
 +
'''Native analog'''
 +
: [[MARK_CHAR_AS_NO_LONGER_NEEDED]]
  
This opcode will mark the character as no longer needed and turn it into a random ped. The character will no longer be recognized as part of the code. If you want your character to disappear after it dies or after you are finished with it, use this opcode to make it into a random ped so it will disappear like a random ped. This opcode is only needed when the character is spawned ([[009A]], etc.) or grabbed from the streets ([[02DD]], etc.). This opcode is not needed for any other cases. Using this with disregard will cause problems with other scripts trying to recognize the same character.
+
This opcode marks the character as no longer needed and turns it into a random ped. If the character is spawned ([[009A]], etc.) or grabbed from the streets ([[02DD]], etc.), the character will remain saved in the game if this opcode isn't used on that character. When the character is marked no longer needed, the character will walk off like a regular pedestrian and will disappear off-screen, but the script will continue to recognize the character until the character disappears.
  
==Sanny Builder Example==
+
== Keywords ==
<source lang="scm">01C2: remove_references_to_actor 2@ // Like turning an actor into a random pedestrian</source>
+
remove, reference, references, actor, character
  
==Keywords==
+
== See also ==
remove, reference, references, actor, character
+
*[[01C3]], for vehicles
 +
*[[01C4]], for objects
 +
 
 +
[[Category:OpCodes]]

Revision as of 22:58, 20 December 2011

GTA III Vice City San Andreas


Description

Marks the character as no longer needed

Syntax

01C2: remove_references_to_actor [char handle]

Parameter

[char handle]
The handle of the character

Native analog

MARK_CHAR_AS_NO_LONGER_NEEDED

This opcode marks the character as no longer needed and turns it into a random ped. If the character is spawned (009A, etc.) or grabbed from the streets (02DD, etc.), the character will remain saved in the game if this opcode isn't used on that character. When the character is marked no longer needed, the character will walk off like a regular pedestrian and will disappear off-screen, but the script will continue to recognize the character until the character disappears.

Keywords

remove, reference, references, actor, character

See also