Skip to content

[ALL] Make trigger_hurt double w/ forgiveness actually forgive #1407

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

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

horiuchii
Copy link

@horiuchii horiuchii commented Jul 9, 2025

Description

This PR fixes an issue with trigger_hurt's Doubling w/forgiveness damage model.

Currently, the trigger doesn't check for whether the curtime is past the forgiveness reset time before dealing damage and pushing forgiveness reset time into the future.

Now, curtime is instead checked to see if it has passed the forgiveness reset time at the start of the think, preventing this.

This does not change how current, existing triggers that use the damage model function, as it's been replaced with just a "Doubling" damage model, moving the forgiveness model down in the enum by one.

FGDs should probably be updated to reflect this.

damagemodel(choices) : "Damage Model" : 0 : "How damage is dealt. Normal always does the specified amount of damage each half second. Doubling starts with the specified amount and doubles it each time it hurts the toucher. Forgiveness means that if the toucher gets out of the trigger the damage will reset to the specified value. Good for making triggers that are deadly over time without having to cause massive damage on each touch." =
[
	0 : "Normal"
	1 : "Doubling"
	2 : "Doubling w/forgiveness"
]

Generalisk added a commit to Generalisk/GeneSource-SDK that referenced this pull request Jul 9, 2025
@ficool2
Copy link
Contributor

ficool2 commented Jul 9, 2025

This might cause issues with maps that depend on the broken behavior, should add a new keyvalue for this instead

@horiuchii
Copy link
Author

Replying to #1407 (comment)

Made the fix optional by moving DAMAGEMODEL_DOUBLE_FORGIVENESS down in the enum by 1 and having DAMAGEMODEL_DOUBLE take it's place.

FGDs probably should to be updated to reflect this so that's now in the PR description.

Generalisk added a commit to Generalisk/GeneSource-SDK that referenced this pull request Jul 9, 2025
Bitl added a commit to BitlDevelopmentStudios/source-sdk-2013-bds-base that referenced this pull request Jul 10, 2025
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.

2 participants