Difference between revisions of "0004"

From GTAMods Wiki
Jump to navigation Jump to search
(what a mess)
Line 1: Line 1:
'''Number of parameters(P):''' 2
+
{{OpCode
 
+
| ini        = 0004=2,%1d% %2d%
'''Works in:''' <br>III, VC, SA
+
| description = Sets the value of a global variable a specified integer.
 
+
| p1          = global variable
'''Barton's Mission Builder Syntax:'''<br>
+
| p2          = integer value
0004: $MyVar = 1
+
| game        = [[GTA 3]], [[Vice City]], [[San Andreas]]
 
+
}}
'''Sanny Builder Syntax:'''<br>
+
This opcode sets a global variable to a specified integer.
$MyVar = 1
+
[[Category:Math_OpCodes]]
 
 
'''ini variations:'''<br>
 
''original:'' 0004=2,%1d% = %2d% <br>
 
''PLPynton:'' 0004=2,%1d% = %2d%  <br>
 
 
 
'''C++ Hook Syntax:'''
 
 
 
''Spookie's Vice City C++ Hook:'' const SCRIPT_COMMAND setgi = { 0x0004, "i" };<br>
 
''op9080's San Andreas C++ Hook:'' DEFINE_OPCODE(setgi, 0x0004, "ii");<br>
 
 
 
'''Description:'''
 
 
 
This opcode sets a global variable (P1) to a specified integer (P2).
 
 
 
'''Parameters:'''
 
 
 
P1 = Global Varible Name (ex, $MyVar)<br>
 
P2 = Integer Value (ex, 500)
 
 
 
[[Category:OpCodes]] [[Category:Math_OpCodes]]
 

Revision as of 16:23, 6 February 2009

{{{games}}}


Description
Sets the value of a global variable a specified integer.
Syntax
{{{syntax1}}}
Parameter

This opcode sets a global variable to a specified integer.