Difference between revisions of "0464"

From GTAMods Wiki
Jump to navigation Jump to search
m
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
 
{{OpCode
 
{{OpCode
| ini        = 0464=8, %1d%  %2d%  %3d% %4d% %5d% %6h%  %7d%  %8h%
+
| games      = {{Icon|VC}} {{Icon|SA}}
| description = Puts an actor in turret mode on a car.
+
| command    = ATTACH_<wbr>CHAR_<wbr>TO_<wbr>CAR
| p1          = Existing actor handle.
+
| description = Attaches the character to the vehicle
| p2          = Existing car handle.
+
| syntax1    = 0464: put_actor [''char handle''] into_turret_on_car [''car handle''] at_car_offset [''flt1''] [''flt2''] [''flt3''] position [''int1''] angle [''flt4''] with_weapon [''int2'']
| p3          = X Offset
+
| p1t        = [''char handle'']
| p4          = Y Offset
+
| p1d        = The handle of the character
| p5          = Z Offset
+
| p2t        = [''car handle'']
| p6          = Integer
+
| p2d        =  The handle of the vehicle
| p7          = Shooting angle limit
+
| p3t        = [''flt1'']
| p8          = [[Weapon#Lists_of_Weapons|Weapon number]]
+
| p3d        = X-offset relative to the center of the vehicle
| game        = [[Vice City]], [[San Andreas]]
+
| p4t        = [''flt2'']
 +
| p4d        = Y-offset relative to the center of the vehicle
 +
| p5t        = [''flt3'']
 +
| p5d        = Z-offset relative to the center of the vehicle
 +
| p6t        = [''int1'']
 +
| p6d        = Facing relative to vehicle (see below)
 +
| p7t        = [''flt4'']
 +
| p7d        = Range in degrees
 +
| p8t        = [''int2'']
 +
| p8d        = [[Weapon#Lists of weapons|Weapon type]]
 
}}
 
}}
  
This opcode puts an actor in turret mode on a car with a weapon.
+
This opcode attaches the character to the vehicle. The weapon with 30,000 ammo is given to the character. The weapon must be loaded, usually through opcode [[0247]], in order for the weapon to appear. If used on the player character, it will place the player into first-person view. The range denotes the horizontal axis that the character can shoot from the direction it faces. For example, a value of 90.0 means the character can shoot up to 90 degrees to the left and up to 90 degrees to the right of its facing direction, for a total of 180 degrees movement. A range of 180.0 allows full 360 degrees movement. The following is a table of values denoting the direction the character faces relative to the vehicle. Any values outside the range will always point the character forward.
  
==Sanny Builder Example==
+
{|class="wikitable center-col-1"
 +
!Facing ||[[SCM language III/VC definitions#FACING|Enum]]
 +
|-
 +
|0 ||FACING_FORWARD
 +
|-
 +
|1 ||FACING_LEFT
 +
|-
 +
|2 ||FACING_BACK
 +
|-
 +
|3 ||FACING_RIGHT
 +
|}
  
<source lang="scm">0464: put_actor 99@ into_turret_on_car 68@ at_car_offset 266@ 267@ 268@ position 0 shooting_angle_limit 0.0 with_weapon 0</source>
+
The character remains upright relative to the vehicle and will roll with the vehicle. If the character is killed, it will not drop any items and its collision remains unless the body touches the ground. Bullets fired by the character do not damage the vehicle but they do not go through it. For the player, weapons that do not fire single bullets behave oddly. Shotguns and the Flamethrower cannot be aimed along the vertical axis. The Rocket Launcher and sniper rifles do not work at all. Projectiles like grenades and Molotov Cocktail can be thrown at a very fast rate.{{ref|1}} This opcode is no operation in GTA III.
  
==Keywords==
+
== Keywords ==
Turret, car, actor
+
attach, put, actor, character, car, vehicle, turret, mode
 +
 
 +
== Reference ==
 +
* {{note|1}} [https://www.youtube.com/watch?v=RCIfXTj_IPU Video showing 0464 used with grenades]

Latest revision as of 18:18, 8 July 2017

Vice City San Andreas ATTACH_CHAR_TO_CAR


Description
Attaches the character to the vehicle
Syntax
0464: put_actor [char handle] into_turret_on_car [car handle] at_car_offset [flt1] [flt2] [flt3] position [int1] angle [flt4] with_weapon [int2]
Parameter
[char handle]
The handle of the character
[car handle]
The handle of the vehicle
[flt1]
X-offset relative to the center of the vehicle
[flt2]
Y-offset relative to the center of the vehicle
[flt3]
Z-offset relative to the center of the vehicle
[int1]
Facing relative to vehicle (see below)
[flt4]
Range in degrees
[int2]
Weapon type

This opcode attaches the character to the vehicle. The weapon with 30,000 ammo is given to the character. The weapon must be loaded, usually through opcode 0247, in order for the weapon to appear. If used on the player character, it will place the player into first-person view. The range denotes the horizontal axis that the character can shoot from the direction it faces. For example, a value of 90.0 means the character can shoot up to 90 degrees to the left and up to 90 degrees to the right of its facing direction, for a total of 180 degrees movement. A range of 180.0 allows full 360 degrees movement. The following is a table of values denoting the direction the character faces relative to the vehicle. Any values outside the range will always point the character forward.

Facing Enum
0 FACING_FORWARD
1 FACING_LEFT
2 FACING_BACK
3 FACING_RIGHT

The character remains upright relative to the vehicle and will roll with the vehicle. If the character is killed, it will not drop any items and its collision remains unless the body touches the ground. Bullets fired by the character do not damage the vehicle but they do not go through it. For the player, weapons that do not fire single bullets behave oddly. Shotguns and the Flamethrower cannot be aimed along the vertical axis. The Rocket Launcher and sniper rifles do not work at all. Projectiles like grenades and Molotov Cocktail can be thrown at a very fast rate.[1] This opcode is no operation in GTA III.

Keywords

attach, put, actor, character, car, vehicle, turret, mode

Reference