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

Add crosshair target changed callback #893

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

NachosChipeados
Copy link
Contributor

Adds a callback that triggers whenever you hover your crosshair over any entity. Adds 2 vanilla files.

Warning: loud
https://github.com/user-attachments/assets/6ff30761-63ed-47ed-a25b-586a29a76eee

Script used:
untyped

global function crosshaircallback_Init

void function crosshaircallback_Init()
{
	AddCallback_OnCrosshairCurrentTargetChanged ( wow )
}

void function wow ( entity player, entity newTarget )
{
	printt ( "guh" )

	EmitSoundOnEntity( player, "Pilot_Killed_Indicator" )
}

@github-actions github-actions bot added needs testing Changes from the PR still need to be tested needs code review Changes from PR still need to be reviewed in code labels Oct 13, 2024
@Zanieon Zanieon added the commits vanilla file For PRs that commit vanilla files from VPKs label Oct 13, 2024
Copy link
Contributor

@JMM889901 JMM889901 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@GeckoEidechse GeckoEidechse self-assigned this Nov 15, 2024
@github-actions github-actions bot added the merge conflicts Blocked by merge conflicts, waiting on the author to resolve label Nov 16, 2024
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From which VPK is that vanilla file from?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Its in all sp vpks

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Huh, so ig it's the same in all of them? I'll check ig and then add it from one of them ^^

@github-actions github-actions bot removed the merge conflicts Blocked by merge conflicts, waiting on the author to resolve label Nov 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
commits vanilla file For PRs that commit vanilla files from VPKs needs code review Changes from PR still need to be reviewed in code needs testing Changes from the PR still need to be tested
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

4 participants