Difference between revisions of "039D"
(colors work!) |
m |
||
Line 9: | Line 9: | ||
|} | |} | ||
</div></div> | </div></div> | ||
− | {{Icon|3}} {{Icon|VC}} | + | {{OpCode |
− | + | | games = {{Icon|3}} {{Icon|VC}} | |
− | + | | command = ADD_<wbr>MOVING_<wbr>PARTICLE_<wbr>EFFECT | |
− | + | | description = Adds a moving particle effect | |
− | + | | syntax1 = 039D: scatter_particles [''int1''] [''flt1''] [''int2''] [''int3''] [''int4''] [''int5''] at [''flt2''] [''flt3''] [''flt4''] [''flt5''] [''flt6''] [''flt7''] | |
− | + | | p1t = [''int1''] | |
− | + | | p1d = Particle effect (see below) | |
− | + | | p2t = [''flt1''] | |
− | + | | p2d = Scale | |
− | + | | p3t = [''int2''] | |
− | + | | p3d = Red, between 0 and 255 | |
− | + | | p4t = [''int3''] | |
− | + | | p4d = Green, between 0 and 255 | |
− | + | | p5t = [''int4''] | |
− | + | | p5d = Blue, between 0 and 255 | |
− | + | | p6t = [''int5''] | |
− | + | | p6d = Duration in milliseconds | |
− | + | | p7t = [''flt2''] | |
− | + | | p7d = X-coordinate | |
− | + | | p8t = [''flt3''] | |
− | + | | p8d = Y-coordinate | |
− | + | | p9t = [''flt4''] | |
− | + | | p9d = Z-coordinate | |
− | + | | p10t = [''flt5''] | |
− | + | | p10d = X-strength | |
− | + | | p11t = [''flt6''] | |
− | + | | p11d = Y-strength | |
− | + | | p12t = [''flt7''] | |
− | + | | p12d = Z-strength | |
− | + | }} | |
− | |||
This opcode adds a moving particle effects at the specified location for a duration of time. Particle effects must be in range of the player (about 95 units) when adding them into the world; they will not appear when added outside the range. Particle effects that have been added will disappear when the player moves out of range regardless of duration. | This opcode adds a moving particle effects at the specified location for a duration of time. Particle effects must be in range of the player (about 95 units) when adding them into the world; they will not appear when added outside the range. Particle effects that have been added will disappear when the player moves out of range regardless of duration. | ||
− | Using a particle | + | Using a particle effect outside the range listed below produces unpredictable results and may crash the game. The colors red, green, and blue only affect particle 14 in GTA III and particle 16 in Vice City and has no effect on anything else. Some particles do not obey the duration and are noted below. If the duration is set to 0, particles that obey duration will loop forever; using opcode [[03AE]] or moving outside the range of the particle can remove a particle effect stuck in a loop. The strength represents the direction and length of movement of the particle. Some particles look meaningless or weird absence of the strength. Ones that are affected by gravity can be seen arcing towards the ground if an x- or y-strength is set. Some particles do not obey the strength and are noted below. Particle effects created with this opcode is saved in [[Saves (GTA 3)#Block 14: Particles|block 14 of the save file]] in GTA III and [[Saves (GTA VC)#Block 15: Particles|block 15]] in Vice City. |
The [[Main.scm|original script]] in GTA III uses particles 10, 11, 12, 13, 15, 18, and 19; and in Vice City uses 4 and 17. | The [[Main.scm|original script]] in GTA III uses particles 10, 11, 12, 13, 15, 18, and 19; and in Vice City uses 4 and 17. | ||
Line 51: | Line 50: | ||
=== GTA III === | === GTA III === | ||
{|class="wikitable" | {|class="wikitable" | ||
− | ! | + | !Particle<br>effect ||Image ||Enum ||Obey<br>duration? ||Obey<br>strength? ||Notes |
|- | |- | ||
|{{a|c}} |0 ||[[File:III 039D-0.jpg|150px]] ||POBJECT_<wbr>PAVEMENT_<wbr>STEAM ||{{a|c}} |✓ ||{{a|c}} |✓ ||thin white smoke | |{{a|c}} |0 ||[[File:III 039D-0.jpg|150px]] ||POBJECT_<wbr>PAVEMENT_<wbr>STEAM ||{{a|c}} |✓ ||{{a|c}} |✓ ||thin white smoke | ||
Line 96: | Line 95: | ||
=== Vice City === | === Vice City === | ||
{|class="wikitable" | {|class="wikitable" | ||
− | ! | + | !Particle<br>effect ||Image ||[[SCM language III/VC definitions#POBJECT|Enum]] ||Obey<br>duration? ||Obey<br>strength? ||Notes |
|- | |- | ||
|{{a|c}} |0 ||[[File:VC 039D-0.jpg|150px]] ||POBJECT_<wbr>PAVEMENT_<wbr>STEAM ||{{a|c}} |✓ ||{{a|c}} |✓ ||thin white smoke | |{{a|c}} |0 ||[[File:VC 039D-0.jpg|150px]] ||POBJECT_<wbr>PAVEMENT_<wbr>STEAM ||{{a|c}} |✓ ||{{a|c}} |✓ ||thin white smoke | ||
Line 143: | Line 142: | ||
== See also == | == See also == | ||
− | * [[02A2]], | + | * {{Icon|3}} [[02A2]], adds a particle effect |
− | |||
− |
Revision as of 05:41, 13 February 2016
- Description
- Adds a moving particle effect
- Syntax
- 039D: scatter_particles [int1] [flt1] [int2] [int3] [int4] [int5] at [flt2] [flt3] [flt4] [flt5] [flt6] [flt7]
- Parameter
- [int1]
- Particle effect (see below)
- [flt1]
- Scale
- [int2]
- Red, between 0 and 255
- [int3]
- Green, between 0 and 255
- [int4]
- Blue, between 0 and 255
- [int5]
- Duration in milliseconds
- [flt2]
- X-coordinate
- [flt3]
- Y-coordinate
- [flt4]
- Z-coordinate
- [flt5]
- X-strength
- [flt6]
- Y-strength
- [flt7]
- Z-strength
This opcode adds a moving particle effects at the specified location for a duration of time. Particle effects must be in range of the player (about 95 units) when adding them into the world; they will not appear when added outside the range. Particle effects that have been added will disappear when the player moves out of range regardless of duration.
Using a particle effect outside the range listed below produces unpredictable results and may crash the game. The colors red, green, and blue only affect particle 14 in GTA III and particle 16 in Vice City and has no effect on anything else. Some particles do not obey the duration and are noted below. If the duration is set to 0, particles that obey duration will loop forever; using opcode 03AE or moving outside the range of the particle can remove a particle effect stuck in a loop. The strength represents the direction and length of movement of the particle. Some particles look meaningless or weird absence of the strength. Ones that are affected by gravity can be seen arcing towards the ground if an x- or y-strength is set. Some particles do not obey the strength and are noted below. Particle effects created with this opcode is saved in block 14 of the save file in GTA III and block 15 in Vice City.
The original script in GTA III uses particles 10, 11, 12, 13, 15, 18, and 19; and in Vice City uses 4 and 17.
List of particle effects
All images below are taken with a size of 1.0 and a strength of 0.0.
GTA III
Vice City
Particle effect |
Image | Enum | Obey duration? |
Obey strength? |
Notes |
---|---|---|---|---|---|
0 | POBJECT_ |
✓ | ✓ | thin white smoke | |
1 | POBJECT_ |
✓ | ✓ | thick white smoke | |
2 | POBJECT_ |
✓ | ✓ | thin white smoke | |
3 | POBJECT_ |
✓ | ✓ | thick white smoke | |
4 | POBJECT_ |
✓ | ✓ | black smoke | |
5 | POBJECT_ |
✗ | ✗ | fire hydrant water | |
6 | POBJECT_ |
✓ | ✓ | large water splash | |
7 | POBJECT_ |
✓ | ✓ | medium water splash | |
8 | POBJECT_ |
✓ | ✗ | a square of raindrops on the ground; if scale is 1.0, size of square is 1x1 units | |
9 | POBJECT_ |
✓ | ✗ | ||
10 | POBJECT_ |
✓ | ✗ | ||
11 | POBJECT_ |
✓ | ✗ | ||
12 | POBJECT_ |
✓ | ✗ | ||
13 | POBJECT_ |
✓ | ✗ | vertical fountain water | |
14 | POBJECT_ |
✓ | ✓ | horizontal fountain water | |
15 | POBJECT_ |
✓ | ✓ | ||
16 | POBJECT_ |
✓ | ✓ | the only particle effect that colors can be applied | |
17 | POBJECT_ |
✓ | ✓ | initial explosion then smokes | |
18 | POBJECT_ |
✗ | ✓ | initial explosion then smokes; setting duration to 0 can bug out all particles in the game, making random particles produce this smoke | |
19 | POBJECT_ |
✗ | ✓ | single brief explosion |
Keywords
scatter, add, moving, particle, object, effect
See also
- 02A2, adds a particle effect