| 159 | } |
| 160 | |
| 161 | static void AddCheatEntry(const char *name, uint32 addr, uint8 val, int compare, int status, int type) |
| 162 | { |
| 163 | CHEATF *temp = new CHEATF(); |
| 164 | |
| 165 | temp->name = name; |
| 166 | temp->addr = addr; |
| 167 | temp->val = val; |
| 168 | temp->status = status; |
| 169 | temp->compare = compare; |
| 170 | temp->type = type; |
| 171 | temp->next = nullptr; |
| 172 | |
| 173 | if(cheats) |
| 174 | { |
| 175 | cheatsl->next = temp; |
| 176 | cheatsl = temp; |
| 177 | } |
| 178 | else |
| 179 | cheats = cheatsl = temp; |
| 180 | } |
| 181 | |
| 182 | /* The "override_existing" parameter is used only in cheat dialog import. |
| 183 | Since the default behaviour will reset numsubcheats to 0 everytime, |
no outgoing calls
no test coverage detected