Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function int unusedTID(int start, int end)
- {
- int ret = start - 1;
- int tidNum;
- if (start > end) { start ^= end; end ^= start; start ^= end; } // good ol' XOR swap
- while (ret++ != end)
- {
- if (ThingCount(0, ret) == 0)
- {
- return ret;
- }
- }
- return -1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement