
#ifndef _TDRAWCALL_H_
#define _TDRAWCALL_H_
#include "common.h"
#include "log.h"

struct TDrawCall {
  int16 m_field_0;
  int16 m_field_2;
  int16 m_field_4;
  TDrawCall() {}
  TDrawCall(int16 a, int16 b, int16 c) {
    m_field_0 = a;
    m_field_2 = b;
    m_field_4 = c;
  }

  //-------------------------------------------------------------------------------------------------
  // 001A0F3C ^_^
  //单元测试等级: 游戏运行正常
  //单元测试内容: 启动游戏到第1关,会被多次调用
  //单元测试结果: 正常
  //编译无栈保护选项
  // IDA交叉引用未发现调用这个函数的代码，测试时需要专门写代码调用
  __attribute__((noinline)) TDrawCall& operator=(TDrawCall&& other) {
    int16 r3 = other.m_field_0;
    int16 r2 = this->m_field_0;
    this->m_field_0 = r3;
    r3 = other.m_field_2;
    other.m_field_0 = r2;
    r2 = this->m_field_2;
    this->m_field_2 = r3;
    r3 = other.m_field_4;
    other.m_field_2 = r2;
    this->m_field_4 = r3;
    return *this;
  }
};

#endif