mirror of
https://github.com/HarbourMasters/Starship.git
synced 2025-04-28 12:27:59 +03:00
Add a shooting delay after firing a Charged Shot
This commit is contained in:
parent
0169c08350
commit
6d9b263fc1
1 changed files with 8 additions and 0 deletions
|
@ -305,6 +305,13 @@ void OnLivesCounterDraw(IEvent* ev){
|
|||
HUD_LivesCount2_Draw(258.0f, SCREEN_HEIGHT - 20, gLifeCount[gPlayerNum]);
|
||||
}
|
||||
|
||||
void OnPlayerShootChargedPre(PlayerActionPreShootChargedEvent* ev){
|
||||
if (CVarGetInteger("gRapidFire", 0) == 1) {
|
||||
ev->player->shotTimer = 4;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void PortEnhancements_Init() {
|
||||
PortEnhancements_Register();
|
||||
|
||||
|
@ -323,6 +330,7 @@ void PortEnhancements_Init() {
|
|||
REGISTER_LISTENER(PlayerActionBoostEvent, OnPlayerBoost, EVENT_PRIORITY_NORMAL);
|
||||
REGISTER_LISTENER(PlayerActionBrakeEvent, OnPlayerBrake, EVENT_PRIORITY_NORMAL);
|
||||
REGISTER_LISTENER(PlayerActionPostShootEvent, OnPlayerShootPost, EVENT_PRIORITY_NORMAL);
|
||||
REGISTER_LISTENER(PlayerActionPreShootChargedEvent, OnPlayerShootChargedPre, EVENT_PRIORITY_NORMAL);
|
||||
}
|
||||
|
||||
void PortEnhancements_Register() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue