🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: alt.msdos.programmer
4 messages
4 total messages Started by Charlie Hutchins Fri, 07 Aug 1992 22:32
HELP! My TSR won't activate in many games!
#66
Author: Charlie Hutchins
Date: Fri, 07 Aug 1992 22:32
14 lines
1205 bytes
The subject line says it all...  Right now I'm writing a small TSR
program that hooks interrupt 9 for activation.  Whenever you press
a key, my program checks to see if it should activate...if so, it
does...or so I thought.  The program works fine in DOS and most
text mode programs but it won't work in all games. (It does work in
some, however)  I suppose the games it won't work with completely
take over INT 9 but does any one have an idea for a solution to
this??  There must be some way to allow it to activate in every (or
a least most) games...  And, No, my program does not write anything
to the screen or access files.  (it accesses the PC speaker)...
Any ideas, suggestions, tips, etc. would be great...Thanks (I
hope)...

...Charlie Hutchins
Re: HELP! My TSR won't activate in many games!
#68
Author: Ron Dippold
Date: Fri, 07 Aug 1992 23:29
36 lines
2598 bytes
Charlie_Hutchins@mindlink.bc.ca (Charlie Hutchins) writes:
>The subject line says it all...  Right now I'm writing a small TSR
>program that hooks interrupt 9 for activation.  Whenever you press
>a key, my program checks to see if it should activate...if so, it
>does...or so I thought.  The program works fine in DOS and most
>text mode programs but it won't work in all games. (It does work in
>some, however)  I suppose the games it won't work with completely
>take over INT 9 but does any one have an idea for a solution to
>this??  There must be some way to allow it to activate in every (or
>a least most) games...  And, No, my program does not write anything

Give it a delayed activation option.  Use one of the timing interrupts
to count how long it's been since you activated the program - say the
18.2 times a second interrupt - games usually chain that.  Then after
the given amount of time, _then_ have it substitute it's own interrupt
handler for interrupt 9 (chaining to the old one, of course).  If you
give it enough time, you have time to load the game and have the game
install its own interrupt first.  You might want to beep the speaker
when it actually installs.  If you _really_ want to get tricky, and
the game doesn't keep the timer interrupt, you could take over INT13h
and activate after x number of accesses there. 

The only problem with this is that when the game quits it will restore
the vector that it found, so your TSR will be stranded - just doing
nothing but taking up space.  This may not be a problem.  If it is,
you can do the following:  when your program first starts, save the
current int9 vector.  Wait x seconds.  Replace the new int9 vector
with your routine.  When the game quits, the interrupt vector will be
changed by the game back to the original int9 vector.  You can see
this and shut down your TSR.

I imagine there are still games that are so antisocial that they
resist almost all methods, but getting rid of the int9 replacement
should fix most of them.
-- 
Hospitality:  Making your guests feel at home, even though you wish they were.
Re: HELP! My TSR won't activate in many games!
#81
Author: Ross Ridge
Date: Tue, 11 Aug 1992 08:35
17 lines
1049 bytes
rdippold@cancun.qualcomm.com (Ron Dippold) writes:
>If it is, you can do the following:  when your program first starts, save
>the current int9 vector.  Wait x seconds.  Replace the new int9 vector with
>your routine.  When the game quits, the interrupt vector will be changed by
>the game back to the original int9 vector.  You can see this and shut down
>your TSR.

How can you see this?  After the game puts back the original int9 vector
you routine no long runs and so can't detect the change.

							Ross Ridge

-- 
Ross Ridge - The Great HTMU					     l/	 //
								    [OO][oo]
ross@zooid.guild.org						    /()\/()/
uunet.ca!zooid!ross						     db	 //
Re: HELP! My TSR won't activate in many games!
#83
Author: Ron Dippold
Date: Tue, 11 Aug 1992 16:16
16 lines
1385 bytes
ross@zooid.guild.org (Ross Ridge) writes:
>rdippold@cancun.qualcomm.com (Ron Dippold) writes:
>>If it is, you can do the following:  when your program first starts, save
>>the current int9 vector.  Wait x seconds.  Replace the new int9 vector with
>>your routine.  When the game quits, the interrupt vector will be changed by
>>the game back to the original int9 vector.  You can see this and shut down
>>your TSR.

>How can you see this?  After the game puts back the original int9 vector
>you routine no long runs and so can't detect the change.

Well, I was assuming that you were still using the timer interrupt
that you used to install it in the first place - then you can look at
that vector 18 times a second to see it has changed.
-- 
He is no lawyer who cannot take two sides.
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads