odd_create_instruction

Syntax

odd_create_instruction(opcode, operand1, operand2)

Parameters

Name Description
opcode The odd_opcode the Instruction is meant to do.
operand1 The first operand, if any, for the specified opcode.
operand2 The second operand, if any, for the specified opcode.

Returns

Instruction: The reference to the new Instruction. There is no need to free or delete it, because of how it is handled internally.

Description

Creates a new Instruction with the specified parameters, returning its reference

Example

var inst = odd_create_instruction(odd_opcode.DebugLine, 20, undefined);

// . . .

This would create a new Instruction with the DebugLine opcode, with the first operand being 20.