Home » MODDING HQ 1.13 » v1.13 Idea Incubation Lab  » Improved Interrupt System
Improved Interrupt System[message #290787] Sat, 17 September 2011 18:25 Go to previous message
Sandro is currently offline Sandro

 
Messages:420
Registered:November 2008
Location: Mars
This is an experimental project.
The interrupt topic was discussed like million times before, but no improvement was ever made if I recall correctly. Well, I am gonna try some things with it.
Where to start...

This project overthrows the current way the interrupts are handled. Instead of gaining interrupts only on the moment a guy spots another guy, we bring in a system which actually counts the amount of time we observe a guy and based on this time and our skills we are given the interrupts. I'll explain the exact mechanics:

-- CORE --

Interrupt Counter
This is the main wheel controlling the interrupt occurences.
The "Interrupt Counter" is a variable that tracks down the amount of APs an enemy (within our LOS) used (counted for each enemy separetely). When the Interrupt Counter hits certain value, we are given an interrupt. As APs represent time in JA2, this means that we have to see the enemy for a while to react and get interrupt, while the length of that while is determined by our skills.

However, for each AP an enemy used, the code rolls for a chance whether this AP would be counted or not.
This chance is based on the merc's abilities. For example if the chance is calculated to be 70% and enemy just used 10 APs for something, following happens:
For each of the 10 points, 70% chance is rolled - 10x 70% chance roll. If the roll is successful (under 70%) the point is counted towards mentioned Interrupt Counter, if the roll is not successful, the point is ignored. So statistically 7 points are counted for Interrupt Counter in this case.


The merc abilities influence both factors:
1) Interrupt Counter lenght is determined by:
  • Agility
  • APs we have at the moment
  • Injuries, shock, etc.
2) The chance each enemy AP used is counted or not is determined by:
  • Experience Level
  • Distance to target
  • Traits and whatever
  • (Camouflage of the enemy etc.)
Basically we could say, that the Counter length represents how FAST can our BODY react.
While the chance on each point represents how well we can percieve and realize what we percieve.

Hearing
Now. While this feature means we have to percieve the enemy for a certain amount of time to be able to react on him, it does not mean that we are never allowed to get the interrupt at the very moment we spot him. The thing is that IF we were able to hear him beforehand, the Interrupt Counter is involved too. For example our merc waits inside a building while an enemy guy runs around the building towards the entrance we aim at. We hear him the whole time as he runs, so we got aware of him well enough. The moment he opens the door and steps in, we get the interrupt and simply pull the trigger.

This feature alone means that:
  • We can interrupt an enemy we already see
  • We can get mmultiple interrupts for each enemy
  • The whole procedure of getting interrupts makes more sense

Collective Interrupts
A chance that if a soldier close to another soldier gets an interrupt, the second soldier can get an interrupt too. This means that one soldier can trigger an interrupt for many mercs around. Of course there are mercs' abilities involved.

Basically this feature represents mercs' communication and cooperation when close enough to each other. A perfect feature for Sniper+Spotter combo or Squadleader being center of a squad - capable Squadeader can stand in the middle of the squad watching the battlefield and yell orders triggering Collective Interrupts for others. As the Interrupt Counter length is influenced by current APs of merc (prolonging him the less APs remain), then it is wise teamfight strategy to not spend the Squadleader's APs keeping them on max to trigger collective interrupts more often.

The exact details on the workaround of this feature are not complete yet. But you can see the basis.

-- LUXURIES --

"No More Interrupts! button" - a button for each merc to turn off interrupts for the rest of the turn. Useful when he has too little APs to do something, or you just have some reasons to not trigger the interrupts (scouting with binoculars or whatever).

"Ignore Collective Interrupts! button" - similar to above, but making the soldier to ignore orders/yelling/warnings of others so does not respond to Collective Interrupts, but still getting his own interrupts.

Lock-On Feature Theory
for future



-- --

So, now when I am at the end of the rather plain explanation, I am not sure why exactly am I publishing this.... oh, right, I may use some suggestions, that's what. I was able to make the Interrupt Counter working. Experimentally. And it works. It's actually not so hard as one would think.

Must say it's some time I tried to explain something in english. My sentences are awkward like %@#$. :/
I hope you got the idea even though of that.


-- --

EDIT / UPDATE:
IIS was successfuly coded and added to development SVN branch. However I have too many other projects and haven't got so much time to perfectly debug it, so by now it's in a "testing phase" and turned off by defult in the SVN. If you want to play with it, either grab the code from development branch and compile it, or an SCI of revision 4903 or higher (however it may miss several bugfixes).
To enable IIS search for IMPROVED_INTERRUPT_SYSTEM in the JA2_Options.ini or in the ini editor choose it at the game start screen.

[Updated on: Mon, 19 November 2012 14:17] by Moderator

Report message to a moderator

Master Sergeant

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Tutorial for rendering and creating animations for LOBOT [OUTDATED]
Next Topic: Mike´s "Second Coming"
Goto Forum:
  


Current Time: Fri Jun 27 00:42:15 GMT+3 2025

Total time taken to generate the page: 0.02503 seconds