Welcome to the new platform of Programmers Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use it's exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.
Detecting SHIFT in Virtual Pascal Win32?
I'm currently porting a DOS textmode game to Win32 using Virtual Pascal. I've used the below code to detect whether or not SHIFT is pressed, but it doesn't work when I try to compile in Virtual Pascal. I get "Error 3: Unknown identifier 'registers'".
function SHIFTDOWN : boolean;
var regs : registers;
FillChar (regs, SizeOf(regs), 0);
regs.ah := $02;
Intr ($16, regs);
shiftdown := (regs.al and $02) = $02;
Any advice on how to detect SHIFT in Virtual Pascal Win32?