IceDreamer wrote:Resin you really do need to check current files and test things ingame man...
As stated on the first post...
"Please keep in mind that this is still very much a work in progress so expect to see some strange things."
Beyond that I'm only proving the concept and allowing others to see what was done by releasing it. Your welcome to try and improve on this work but I doubt 99.999% of FAF subscribers will understand what was done, much less what needs to be to make it prefect.
To that end I'll state the three biggest challenges:
1) Projectiles can sometimes pass through a shield before being reflected. This is due to the projectile speed being faster than the impact can be detected. This is totally due to the way the game engine handles impact events. Now I've a few ideas on how to resolve this but as I said it's not a project for a casual scripter. However for those brave enough to give it a try here it is....
Make a dummy projectile, attach it to the original projectile and then offset the projectile ahead of the original by an amount based off of the originals muzzle velocity. What this will do it enable the dummy projectile to trigger the reflection event in advance of the original arriving at the shield. While this will not 100% prevent a projectile from penetrating, it should reduce it significantly.
2) Shield OnCollision event for some unknown reason can't be non-destructively hook'd and I've not been able to figure out why. In a nut-shell I'm unable to call "oldShield.OnCollisionCheck(self,other)" and run the old version of shield.lua to enable proper hooking. Even importing the "shield" class indirectly doesn't work.
3) Creating impact effects appears to be a major issue as the Vector data needed for the correct placement of the effects is incorrect in some way. Even using the native CreateImpactEffect within shield.lua didnt work.
Note: I don't use FAF to create or test mods, just vanilla with 3599 patches. Running FAF locally is pointless for the testing of betas as it's very cumbersome to load repeatedly via the lobby.
Resin