Difference between revisions of "01C8"

From GTAMods Wiki
Jump to navigation Jump to search
m
Line 5: Line 5:
 
| p2          = [[Ped type]]
 
| p2          = [[Ped type]]
 
| p3          = Valid ped [[DFF]] model name or ID number as defined in the [[IDE#PEDS|IDE]] file
 
| p3          = Valid ped [[DFF]] model name or ID number as defined in the [[IDE#PEDS|IDE]] file
| p4          = Flag
+
| p4          = Flag (seat)
 
| p5          = Actor handle
 
| p5          = Actor handle
| game        = GTA3, Vice City, San Andreas
+
| game        = [[GTA 3]], [[Vice City]], [[San Andreas]], [[Vice City Stories]] (0118)
 
| native      = [[CREATE_CHAR_AS_PASSENGER]]
 
| native      = [[CREATE_CHAR_AS_PASSENGER]]
 
}}
 
}}
Similar to opcode [[009A]], this creates a character in the passenger seat of a vehicle. Using this opcode requires an existing vehicle and opcode [[0247]] to load the model or else the game could crash. If you create a character in a non-existent seat, the character will still be created inside the vehicle but it will be invisible. Note that the parameters are mixed around.
+
Similar to opcode [[009A]], this creates a character in the passenger seat of a vehicle. Using this opcode requires an existing vehicle and opcode [[0247]] to load the model or else the game could crash. Characters can even be created in wrecked vehicles as long as the vehicle exists. If you create a character in a non-existent seat, the character will still be created inside the vehicle but it will be invisible. Certain actions that would normally make the character voluntarily exit the vehicle won't work but opcodes can force the character to exit the vehicle. Note that the parameters are mixed around.
[[Sanny Builder]] example:<source lang="scm">01C8: 1@ = create_actor_pedtype 5 model #BFORI in_car 0@ passenger_seat 0</source>
+
[[Sanny Builder]] example:<source lang="scm">01C8: 1@ = create_actor_pedtype 4 model #BFORI in_car 0@ passenger_seat 0</source>
  
 
==Flags==
 
==Flags==
The flag is the position of the seat that the character will be created in.<br>
+
The flag is the position of the seat that the character will be created in.
0 Front right seat<br>
+
{| {{prettytable}}
1 Rear left seat<br>
+
| -1 ||The next available seat
2 Rear right seat
+
|-
 +
|0 ||Front right seat
 +
|-
 +
|1 ||Rear left seat
 +
|-
 +
|2 ||Rear right seat
 +
|}
  
 
==Note==
 
==Note==

Revision as of 13:25, 8 April 2010

{{{games}}}


Description
Creates a character in the passenger seat of a vehicle
Syntax
{{{syntax1}}}
Parameter
Native analog
CREATE_CHAR_AS_PASSENGER

Similar to opcode 009A, this creates a character in the passenger seat of a vehicle. Using this opcode requires an existing vehicle and opcode 0247 to load the model or else the game could crash. Characters can even be created in wrecked vehicles as long as the vehicle exists. If you create a character in a non-existent seat, the character will still be created inside the vehicle but it will be invisible. Certain actions that would normally make the character voluntarily exit the vehicle won't work but opcodes can force the character to exit the vehicle. Note that the parameters are mixed around.

Sanny Builder example:

01C8: 1@ = create_actor_pedtype 4 model #BFORI in_car 0@ passenger_seat 0

Flags

The flag is the position of the seat that the character will be created in.

-1 The next available seat
0 Front right seat
1 Rear left seat
2 Rear right seat

Note

The above format is more commonly used. The actual format of this opcode is in order:
01C8=5,%1d% %2d% %3o% %4d% %5d%
The format to use depends on which INI file you use.

Keywords

create, actor, character, pedtype, model, vehicle, car, passenger