-= handler problem
HI Mr Colin.
i think the is a problem in '-=' handler.
this code works well
#define getrandom(min, max) \
ebx=max; ebx++; sub ebx,min \
eax=rand(); div ebx; XCHG eax,edx; eax+=min;
but this is not.
#define getrandom(min, max) \
ebx=max; ebx++; ebx-=min \
eax=rand(); div ebx; XCHG eax,edx; eax+=min;
so the 'ebx-=min' translates as 'ebx -- $min' and it should be 'ebx -= $min' .
btw '+=' works fine here.
http://www.freewebs.com/ogremagic/index.htm