049F
- Description
- Sets the distance along the script path
- Syntax
- 049F: set_scripted_file [path handle] distance_along_path_to [flt]
- Parameter
- [path handle]
- The handle of the script path
- [flt]
- Distance along the path in units
This opcode sets the distance in units to put attached objects along the script path. 0.0 is the beginning of the path and the distance will never exceed the total length of the path.
Getting the distance
There is an unsupported opcode 04A0 with the command "GET_
:opcode_04A0 // 0@ - input param (path handle) 0@ *= 0x34 // size of script path struct 0@ += 0x9B69AC // base address for script paths 0@ += 0x10 // distance along path 05E0: 0@ = read_memory 0@ size 4 virtual_protect 0 // read value 05F6: ret 1 0@
Use this line as a recreation for opcode 04A0. This can be placed anywhere within the external script.
05F5: call_scm_func @opcode_04A0 inputs 1 path_handle [path handle] store_to [var]
Keywords
set, object, script, scripted, path, file, distance, position