Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Airshot changes #60

Merged
merged 1 commit into from
Mar 21, 2022
Merged

Airshot changes #60

merged 1 commit into from
Mar 21, 2022

Conversation

TheBv
Copy link
Contributor

@TheBv TheBv commented Jan 30, 2022

This PR changes a couple of things related to airshots.
It mostly includes a bunch of changes which I'd like to see get added/changed partially to allow for better custom log parsing.

Crossbow bolt hits now count as airshots (only on damage)

Pretty self explanatory in general a "fun feature" to have.

Airshots use a "RayHull" to check for the distance to the ground

This prevents some edge cases where the center of the players isn't above solid ground but the other 40% of the hitbox are.
I think there's a debate to be had if this should be implemented...

Added a direct property to indicate rockets/pipes directly hitting an opponent

Would allow for better identifying direct hit airshots and other things. Sadly a workaround for pipes needed to be added since the event "projectile_direct_hit" gets triggered after the damage event in tf2s source code (see: this)

Added a height property to indicate the distance from the player to the ground when they got airshot

Would allow for some kind of filtering between "good" and "bad" airshots. I was considering adding this to the airshot property but logs.tf doesn't seem to parse this properly.

Like I mentioned these are mostly suggestions and I'm most of it is up to debate if it should even be implemented.
I'd of course be willing to update/change things if needed :)

@sapphonie
Copy link
Contributor

is this compatible with logstf's parser?

@TheBv
Copy link
Contributor Author

TheBv commented Feb 2, 2022

is this compatible with logstf's parser?

All of these changes are compatible with logstf's parser.
In general adding a new property to a line e.g X triggered "damage" against Y (property "Value") should never break logs.tf's parser. In general one could add anything at the end of the line from a logged event and the parser should be fine with it.

I must admit that I do not know this for certain since I do not know the code that's currently being used to parse log files but given the amount of time I've spent developing a log parser based on the original one zoob published some time ago I feel very confident.

So yeah the properties ((direct "1"),(height "X")) should not interfere with it at all. And the other changes only adjust if certain properties get logged or not.

logs.h Outdated Show resolved Hide resolved
logs.cpp Outdated Show resolved Hide resolved
of projectiles that count as an airshot
Added a hull, the size of the standard tf2 player,
to the raytrace to rule out some false positives

Added a height property to log the distance
of the victim who got airshot
Added a `direct` property to indicate direct hits
from projectiles
@TheBv TheBv force-pushed the airshot-changes branch from 5b6c845 to e34e749 Compare March 21, 2022 13:58
@AnAkkk AnAkkk merged commit 4852313 into AnAkkk:public Mar 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants