00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef LOOPSCRIPTNODES_H
00022 #define LOOPSCRIPTNODES_H
00023
00024 #include "GenericNodes.h"
00025
00026
00027 class LoopScriptNode : public Node
00028 {
00029 public:
00030 LoopScriptNode(const uint32 opcode, const uint32 offset, const uint32 newScriptTok)
00031 : Node(opcode, offset, Type(Type::T_INVALID)), scriptTok(newScriptTok)
00032 {
00033 assert(acceptOp(opcode, 0x74));
00034 };
00035 ~LoopScriptNode() {};
00036
00037 void print_unk(Console &o, const uint32 isize) const;
00038 void print_asm(Console &o) const;
00039 void print_bin(ODequeDataSource &o) const;
00040 bool fold(DCUnit *unit, std::deque<Node *> &nodes);
00041
00042 const uint32 lsTok() const { return scriptTok; };
00043
00044 protected:
00045
00046 private:
00047 uint32 scriptTok;
00048 };
00049
00050 class LoopNode : public ColNode
00051 {
00052 public:
00053 LoopNode() : ColNode() {};
00054 LoopNode(const uint32 opcode, const uint32 offset, const uint32 newCurrObj, const uint32 newStrSize, const uint32 newSearchType)
00055 : ColNode(opcode, offset, Type(Type::T_VOID)), currObj(newCurrObj), strSize(newStrSize), searchType(newSearchType)
00056 {
00057 assert(acceptOp(opcode, 0x70));
00058 };
00059 ~LoopNode() {};
00060
00061 void print_unk(Console &o, const uint32 isize) const;
00062 void print_asm(Console &o) const;
00063 void print_bin(ODequeDataSource &o) const;
00064
00065 bool fold(DCUnit *unit, std::deque<Node *> &nodes);
00066
00067 protected:
00068
00069 private:
00070 uint32 currObj;
00071 uint32 strSize;
00072 uint32 searchType;
00073 };
00074
00075 class LoopNextNode : public Node
00076 {
00077 public:
00078 LoopNextNode(const uint32 opcode, const uint32 offset)
00079 : Node(opcode, offset, Type(Type::T_INVALID))
00080 {
00081 assert(acceptOp(opcode, 0x73));
00082 };
00083 ~LoopNextNode() {};
00084
00085 void print_unk(Console &o, const uint32 isize) const;
00086 void print_asm(Console &o) const;
00087 void print_bin(ODequeDataSource &o) const;
00088 bool fold(DCUnit *unit, std::deque<Node *> &nodes);
00089
00090 protected:
00091
00092 private:
00093 };
00094
00095 #endif