Hi everyone!!
I need a help with Sentry Gun.
First, i would like to inform that we have the following 2 Commands for the Sentry,
client command: sentry_menu
- Build/detonate/upgrade sentry guns with this one-for-all menu. You can also spy through your sentries using this menu.
client command: sentry_build
- Quickie to build a sentry without going through menu. Since version 0.2 you can now also point at a sentry and upgrade it with this command, if the sentry is close enough.
I would like to request, if someone can implement the following 4 Features?
1.) To plant a sentry long press R (reload):
What i mean is, if we could bind sentry_build command to the reload button, then the user could build the sentry using Reload button (i.e. R). Long pressing R should build the Sentry.
(NOT the local binding i.e. "bind r sentry_build")
2.) A buy command for purchasing Sentry from the base:
For e.g.
register_clcmd("say /buysentry", "BuySentry")
// Whatever the format would be...
AND / OR
register_concmd("buysentry", "BuySentry")
// Whatever the format would be...
Then, the user should also get a message printed on screen stating, "You have successfully bought a Sentry, long press R to build it anywhere."
3.) Destroy our own Sentry:
The user can destroy his own Sentry using a say command
/destroysentry
register_clcmd("say /destroysentry", "sentry_detonate")
// Whatever the format would be...
AND / OR
register_concmd("destroysentry", "sentry_detonate")
// Whatever the format would be...
4.) Sentry Guns should not be destroyed if the Player died:
The sentry guns are automatically destroyed when the player who build it has died, this shouldn't happen. The sentry gun should be destroyed only if the player changes the Team (from CT to T or vice-versa).
If a player died, then his sentry should stay there only.
However, when that player respawn, if he tries to build a sentry again, then he should get the default message "You have already build a Sentry".
(If the Number of Allowed Sentry Build exceeds, it's 1 in my case)
Then, the player can execute the say command
/destroysentry to Destroy his sentry & create a new one.
Link for Plugin:
Code:
https://forums.alliedmods.net/showthread.php?t=78632
Any good programmers can help me out.
Thank you.