| 713 | } |
| 714 | |
| 715 | void GDScriptByteCodeGenerator::write_end_and(const Address &p_target) { |
| 716 | // If here means both operands are true. |
| 717 | append_opcode(GDScriptFunction::OPCODE_ASSIGN_TRUE); |
| 718 | append(p_target); |
| 719 | // Jump away from the fail condition. |
| 720 | append_opcode(GDScriptFunction::OPCODE_JUMP); |
| 721 | append(opcodes.size() + 3); |
| 722 | // Here it means one of operands is false. |
| 723 | patch_jump(logic_op_jump_pos1.back()->get()); |
| 724 | patch_jump(logic_op_jump_pos2.back()->get()); |
| 725 | logic_op_jump_pos1.pop_back(); |
| 726 | logic_op_jump_pos2.pop_back(); |
| 727 | append_opcode(GDScriptFunction::OPCODE_ASSIGN_FALSE); |
| 728 | append(p_target); |
| 729 | } |
| 730 | |
| 731 | void GDScriptByteCodeGenerator::write_or_left_operand(const Address &p_left_operand) { |
| 732 | append_opcode(GDScriptFunction::OPCODE_JUMP_IF); |
no test coverage detected