04-20-2011, 07:12 AM
LCD Wrote:The syntax above is not right. The right one is:Code:while (a band 16)=0
h=a band 5
v=a band 10
if oldh=4 then
if h=5 then newx=x+1
elseif h=0 then newx=x-1
end If
else if oldh=5 then
if h=1 then newx=x+1
elseif h=4 then newx=x-1
end If
else if oldh=1 then
if h=0 then newx=x+1
elseif h=5 then newx=x-1
end If
else if oldh=0 then
if h=4 then newx=x+1
elseif h=1 then newx=x-1
end If
end If
wend
Code:
while (a band 16)=0
h=a band 5
v=a band 10
if oldh=4 then
if h=5 then newx=x+1
elseif h=0 then newx=x-1
end If
=>> elseif oldh=5 then
if h=1 then newx=x+1
elseif h=4 then newx=x-1
end If
=>> elseif oldh=1 then
if h=0 then newx=x+1
elseif h=5 then newx=x-1
end If
=>> elseif oldh=0 then
if h=4 then newx=x+1
elseif h=1 then newx=x-1
end If
end If
wend
Try this and tell me.
LCD Wrote:And I also noticed that one of my games crahes the Spectrum if ZX Spin is started with enabled +D emulation. Boriel, could you check all your compiler tests with ZX Spin and enabled +D? The game preview of QFJ I sent to you some time ago: If I try to play, the gems cannot be swaped. Without +D Emulation anything works okay.What does +D do? At this 1st stage the compiler is supposed to be used only in 48K Speccy. I was astounded to hear the BG music in your chess game :!: