/// <summary> /// Initializes a new instance of the <see cref="ArrayAccessNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="result">The result.</param> /// <param name="arrayNode">The field node.</param> /// <param name="indexNode">The index node.</param> public ArrayAccessNode(int instructionOffset, PapyrusStringTableIndex result, BaseNode arrayNode, BaseNode indexNode) : base(2, instructionOffset, 0, result) { array = new NodePair(this, arrayNode); index = new NodePair(this, indexNode); }
/// <summary> /// Initializes a new instance of the <see cref="AssignNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="destination">The destination.</param> /// <param name="op">Operator</param> /// <param name="expr">The expression.</param> public AssignOperatorNode(int instructionOffset, BaseNode destination, string op, BaseNode expr) : base(2, instructionOffset, 10) { this.op = op; value = new NodePair(this, expr); this.destination = new NodePair(this, destination); }
/// <summary> /// Initializes a new instance of the <see cref="PropertyAccessNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="result">The result.</param> /// <param name="objectNode">The object node.</param> /// <param name="property">The property.</param> public PropertyAccessNode(int instructionOffset, PapyrusStringTableIndex result, BaseNode objectNode, PapyrusStringTableIndex property) : base(1, instructionOffset, 0, result) { this.property = property; this.objectNode = new NodePair(this, objectNode); }
/// <summary> /// Initializes a new instance of the <see cref="ArrayCreateNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="result">The result.</param> /// <param name="type">The type.</param> /// <param name="size">The size.</param> public ArrayCreateNode(int instructionOffset, PapyrusStringTableIndex result, PapyrusStringTableIndex type, BaseNode size) : base(1, instructionOffset, 0, result) { this.type = type; this.size = new NodePair(this, size); }
/// <summary> /// Initializes a new instance of the <see cref="UnaryOperatorNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="precedence">The precedence.</param> /// <param name="result">The result.</param> /// <param name="op">The unary operator</param> /// <param name="value">The value.</param> public UnaryOperatorNode(int instructionOffset, int precedence, PapyrusStringTableIndex result, string op, BaseNode value) : base(1, instructionOffset, precedence, result) { this.op = op; this.value = new NodePair(this, value); }
/// <summary> /// Initializes a new instance of the <see cref="CastNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="result">The result.</param> /// <param name="value">The value.</param> /// <param name="type">The type.</param> public CastNode(int instructionOffset, PapyrusStringTableIndex result, BaseNode value, PapyrusStringTableIndex type) : base(1, instructionOffset, 1, result) { this.type = type; this.value = new NodePair(this, value); }
/// <summary> /// Initializes a new instance of the <see cref="IfElseNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="condition">The condition.</param> /// <param name="body">The body.</param> /// <param name="elseBody">The else body.</param> public IfElseNode(int instructionOffset, BaseNode condition, BaseNode body, BaseNode elseBody) : base(4, instructionOffset, 10) { this.condition = new NodePair(this, condition); this.body = new NodePair(this, body); this.elseBody = new NodePair(this, elseBody ?? new ScopeNode()); elseIfBody = new NodePair(this, new ScopeNode()); }
/// <summary> /// Initializes a new instance of the <see cref="CallMethodNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="result">The result.</param> /// <param name="objectNode">The object node.</param> /// <param name="method">The method.</param> public CallMethodNode(int instructionOffset, PapyrusStringTableIndex result, BaseNode objectNode, PapyrusStringTableIndex method) : base(2, instructionOffset, 0, result) { this.objectNode = new NodePair(this, objectNode); paramsNode = new NodePair(this, new ParamsNode()); this.method = method; }
/// <summary> /// Initializes a new instance of the <see cref="BinaryOperatorNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="precedence">The precedence.</param> /// <param name="result">The result.</param> /// <param name="left">The left.</param> /// <param name="op">The op.</param> /// <param name="right">The right.</param> public BinaryOperatorNode(int instructionOffset, int precedence, PapyrusStringTableIndex result, BaseNode left, string op, BaseNode right) : base(2, instructionOffset, precedence, result) { this.left = new NodePair(this, left); this.right = new NodePair(this, right); this.op = op; }
/// <summary> /// Initializes a new instance of the <see cref="ReturnNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="expr">The expr.</param> public ReturnNode(int instructionOffset, BaseNode expr) : base(1, instructionOffset, 10) { this.expr = new NodePair(this, expr); }
/// <summary> /// Initializes a new instance of the <see cref="CopyNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="result">The result.</param> /// <param name="value">The value.</param> public CopyNode(int instructionOffset, PapyrusStringTableIndex result, BaseNode value) : base(1, instructionOffset, 10, result) { this.value = new NodePair(this, value); }
/// <summary> /// Initializes a new instance of the <see cref="DeclareNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="identifier">The identifier.</param> /// <param name="type">The type.</param> public DeclareNode(int instructionOffset, BaseNode identifier, PapyrusStringTableIndex type) : base(1, instructionOffset, 0) { objectNode = new NodePair(this, identifier); this.type = type; }
/// <summary> /// Initializes a new instance of the <see cref="ArrayLengthNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="result">The result.</param> /// <param name="arrayNode">The object node.</param> public ArrayLengthNode(int instructionOffset, PapyrusStringTableIndex result, BaseNode arrayNode) : base(1, instructionOffset, 0, result) { array = new NodePair(this, arrayNode); }
/// <summary> /// Initializes a new instance of the <see cref="WhileNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="condition">The condition.</param> /// <param name="body">The body.</param> public WhileNode(int instructionOffset, BaseNode condition, BaseNode body) : base(2, instructionOffset, 10) { this.condition = new NodePair(this, condition); this.body = new NodePair(this, body); }
/// <summary> /// Initializes a new instance of the <see cref="AssignNode" /> class. /// </summary> /// <param name="instructionOffset">The instruction offset.</param> /// <param name="destination">The destination.</param> /// <param name="value">The value.</param> public AssignNode(int instructionOffset, BaseNode destination, BaseNode value) : base(2, instructionOffset, 10) { this.value = new NodePair(this, value); this.destination = new NodePair(this, destination); }