Difference between revisions of "0615"

From GTAMods Wiki
Jump to navigation Jump to search
(New page: {{OpCode | ini = 0615=1,%1d% | description = Defines the beginning of a sequence pack | p1 = Sequence pack handle | game = San Andreas | native = [[OPEN_SEQUEN...)
 
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
 
{{OpCode
 
{{OpCode
| ini        = 0615=1,%1d%
+
| games      = {{Icon|SA}}
| description = Defines the beginning of a sequence pack
+
| command    = OPEN_SEQUENCE_TASK
| p1          = Sequence pack handle
+
| description = Opens a sequence task
| game        = San Andreas
+
| syntax1    = 0615: define_AS_pack_begin [''var'']
 +
| p1t        = [''var'']
 +
| p1d        = Variable to store the handle of the sequence task
 
| native      = [[OPEN_SEQUENCE_TASK]]
 
| native      = [[OPEN_SEQUENCE_TASK]]
 
}}
 
}}
This defines the beginning of a sequence pack. A sequence pack is a group of commands, usually tasks, between opcodes 0615 and [[0616]] that can be assigned to a character or multiple characters. The actor handle for tasks within the pack should be -1 if you want to your character to perform the task assigned ith the pack.
 
  
==Example==
+
This opcode opens the beginning of a sequence task. A sequence task is a group of commands, usually tasks, between opcodes 0615 and [[0616]] that can be assigned to a character or multiple characters. The character handle for tasks within the sequence should be ''-1'' if you want your assigned character to perform the tasks in the sequence.
This example shows how a task can be assigned to a character through the sequence pack.
 
  0615: define_AS_pack_begin 0@
 
  [[05BA]]: AS_actor -1 move_mouth 1 ms
 
  [[05B9]]: AS_actor -1 stay_idle 1 ms lockY 1 lockF 0 time -1
 
  [[0616]]: define_AS_pack_end 0@
 
  [[0618]]: assign_actor 1@ to_AS_pack 0@
 
  [[061B]]: remove_references_to_AS_pack 0@
 
  
==Keywords==
+
== Example ==
action, sequence, task
+
This example shows how tasks can be assigned to a character through the sequence task. After [[009A#Example|spawning a ped]], add the following code afterwards.
 +
<syntaxhighlight lang="scm">
 +
0615: define_AS_pack_begin 1@
 +
05D3: AS_actor -1 goto_point 0.0 0.0 0.0 mode 6 -1 ms
 +
04EB: AS_actor -1 crouch 1
 +
0638: AS_actor -1 stay_put 1
 +
0616: define_AS_pack_end 1@
 +
0618: assign_actor 0@ to_AS_pack 1@
 +
061B: remove_references_to_AS_pack 1@
 +
</syntaxhighlight>
 +
 
 +
== Keywords ==
 +
open, begin, define, action, sequence, task, pack

Latest revision as of 19:51, 19 June 2016

San Andreas OPEN_SEQUENCE_TASK


Description
Opens a sequence task
Syntax
0615: define_AS_pack_begin [var]
Parameter
[var]
Variable to store the handle of the sequence task
Native analog
OPEN_SEQUENCE_TASK

This opcode opens the beginning of a sequence task. A sequence task is a group of commands, usually tasks, between opcodes 0615 and 0616 that can be assigned to a character or multiple characters. The character handle for tasks within the sequence should be -1 if you want your assigned character to perform the tasks in the sequence.

Example

This example shows how tasks can be assigned to a character through the sequence task. After spawning a ped, add the following code afterwards.

0615: define_AS_pack_begin 1@
05D3: AS_actor -1 goto_point 0.0 0.0 0.0 mode 6 -1 ms
04EB: AS_actor -1 crouch 1 
0638: AS_actor -1 stay_put 1
0616: define_AS_pack_end 1@
0618: assign_actor 0@ to_AS_pack 1@
061B: remove_references_to_AS_pack 1@

Keywords

open, begin, define, action, sequence, task, pack