diff options
author | Mikko Tiusanen <ams@daug.net> | 2014-05-15 19:42:24 +0300 |
---|---|---|
committer | Mikko Tiusanen <ams@daug.net> | 2014-05-15 19:42:24 +0300 |
commit | de7bd9bbba26589b9deb1e7c9eda80a75ff0184f (patch) | |
tree | ea07e7f50c80c4fba406b9cbbec86a005a123427 | |
parent | 454a1a21c4d0be8e542160ff60f897594762501b (diff) |
More hummel air pounce fixes. Changed hummel stats.
-rw-r--r-- | src/game/bg_pmove.c | 35 | ||||
-rw-r--r-- | src/game/g_active.c | 8 | ||||
-rw-r--r-- | src/game/g_weapon.c | 14 | ||||
-rw-r--r-- | src/game/tremulous.h | 18 |
4 files changed, 42 insertions, 33 deletions
diff --git a/src/game/bg_pmove.c b/src/game/bg_pmove.c index cd6cb21..603f569 100644 --- a/src/game/bg_pmove.c +++ b/src/game/bg_pmove.c @@ -579,6 +579,13 @@ PM_CheckCharge */ static void PM_CheckCharge( void ) { + // Reset hummel pounce payload when walking + if (pm->ps->weapon == WP_ALEVEL5) + { + pm->ps->stats[ STAT_STATE ] &= ~SS_CHARGING; + pm->pmext->pouncePayload = 0; + } + if( pm->ps->weapon != WP_ALEVEL4 ) return; @@ -707,12 +714,11 @@ static qboolean PM_CheckAirPounce( void ) return qfalse; // We were pouncing, but we've landed - if( /*pm->ps->groundEntityNum != ENTITYNUM_NONE &&*/ + if( /* pm->ps->groundEntityNum != ENTITYNUM_NONE && */ ( pm->ps->pm_flags & PMF_CHARGE ) ) { pm->ps->pm_flags &= ~PMF_CHARGE; pm->ps->weaponTime += LEVEL5_POUNCE_REPEAT; - pm->pmext->pouncePayload = 0; return qfalse; } @@ -3058,6 +3064,7 @@ static void PM_Weapon( void ) qboolean attack1 = pm->cmd.buttons & BUTTON_ATTACK; qboolean attack2 = pm->cmd.buttons & BUTTON_ATTACK2; qboolean attack3 = pm->cmd.buttons & BUTTON_USE_HOLDABLE; + qboolean walk = pm->cmd.buttons & BUTTON_WALKING; // Ignore weapons in some cases if( pm->ps->persistant[ PERS_SPECSTATE ] != SPECTATOR_NOT ) @@ -3071,7 +3078,7 @@ static void PM_Weapon( void ) } // Charging for or canceling a pounce/drill attack - if( pm->ps->weapon == WP_ALEVEL3 || pm->ps->weapon == WP_ALEVEL3_UPG || + if( pm->ps->weapon == WP_ALEVEL3 || pm->ps->weapon == WP_ALEVEL3_UPG || pm->ps->weapon == WP_ALEVEL5 || pm->ps->weapon == WP_ALEVEL0_UPG ) { int max; @@ -3090,19 +3097,21 @@ static void PM_Weapon( void ) max = LEVEL0_DRILL_TIME; break; } - if( pm->cmd.buttons & BUTTON_ATTACK2 ) + + if( attack2 && (pm->ps->weapon != WP_ALEVEL5 || walk) ) pm->ps->stats[ STAT_MISC ] += pml.msec; else pm->ps->stats[ STAT_MISC ] -= pml.msec; if( pm->ps->stats[ STAT_MISC ] > max ) pm->ps->stats[ STAT_MISC ] = max; - else if( pm->ps->stats[ STAT_MISC ] < 0 ) + else if( pm->ps->stats[ STAT_MISC ] <= 0 ) { pm->ps->stats[ STAT_MISC ] = 0; + } } // Trample charge mechanics - if( pm->ps->weapon == WP_ALEVEL4 ) + else if( pm->ps->weapon == WP_ALEVEL4 ) { // Charging up if( !( pm->ps->stats[ STAT_STATE ] & SS_CHARGING ) ) @@ -3223,7 +3232,7 @@ static void PM_Weapon( void ) return; // no bite during pounce - if( ( pm->ps->weapon == WP_ALEVEL3 || pm->ps->weapon == WP_ALEVEL3_UPG ) + if( ( pm->ps->weapon == WP_ALEVEL3 || pm->ps->weapon == WP_ALEVEL3_UPG || pm->ps->weapon == WP_ALEVEL5) && ( pm->cmd.buttons & BUTTON_ATTACK ) && ( pm->ps->pm_flags & PMF_CHARGE ) ) return; @@ -3521,12 +3530,12 @@ static void PM_Weapon( void ) { if( BG_Weapon( pm->ps->weapon )->hasThirdMode ) { - if( pm->ps->weapon == WP_MASS_DRIVER ) - { + if( pm->ps->weapon == WP_MASS_DRIVER ) + { attack3 = qtrue; - } + } - if( pm->ps->weapon == WP_ALEVEL5 && !pm->ps->ammo ) + if( pm->ps->weapon == WP_ALEVEL5 && !pm->ps->ammo ) { pm->ps->weaponTime += 400; return; @@ -3608,10 +3617,10 @@ static void PM_Weapon( void ) PM_AddEvent( EV_FIRE_WEAPON ); addTime = BG_Weapon( pm->ps->weapon )->repeatRate1; break; - + case WP_ALEVEL5: pm->ps->generic1 = WPM_SECONDARY; - PM_AddEvent( EV_FIRE_WEAPON ); + PM_AddEvent( EV_FIRE_WEAPON2 ); addTime = BG_Weapon( pm->ps->weapon )->repeatRate2; break; diff --git a/src/game/g_active.c b/src/game/g_active.c index 9046a79..04ae3ec 100644 --- a/src/game/g_active.c +++ b/src/game/g_active.c @@ -1197,9 +1197,9 @@ void ClientEvents( gentity_t *ent, int oldEventSequence ) FireWeapon2( ent ); break; - case EV_FIRE_WEAPON3: - FireWeapon3( ent ); - break; + case EV_FIRE_WEAPON3: + FireWeapon3( ent ); + break; case EV_NOAMMO: break; @@ -2000,7 +2000,7 @@ client->ps.pm_type = PM_HUMMEL; } break; - case WP_ALEVEL5: + case WP_ALEVEL5: if( !CheckPounceAttack( ent ) ) { client->ps.weaponstate = WEAPON_READY; diff --git a/src/game/g_weapon.c b/src/game/g_weapon.c index f7c68c9..fd24482 100644 --- a/src/game/g_weapon.c +++ b/src/game/g_weapon.c @@ -1789,23 +1789,23 @@ void FireWeapon2( gentity_t *ent ) areaZapFire( ent ); break; - case WP_PAIN_SAW: + case WP_PAIN_SAW: painSawFire2( ent ); break; - case WP_LUCIFER_CANNON: - LCChargeFire( ent, qtrue ); + case WP_LUCIFER_CANNON: + LCChargeFire( ent, qtrue ); break; - case WP_CHAINGUN: - bulletFire( ent, CHAINGUN_SPREAD2, CHAINGUN_DMG2, MOD_CHAINGUN ); + case WP_CHAINGUN: + bulletFire( ent, CHAINGUN_SPREAD2, CHAINGUN_DMG2, MOD_CHAINGUN ); break; - case WP_FLAMER: + case WP_FLAMER: FlamerNormal( ent ); break; - case WP_PULSE_RIFLE: + case WP_PULSE_RIFLE: prifleStasisFire( ent ); break; diff --git a/src/game/tremulous.h b/src/game/tremulous.h index d0c4dd1..82a2c7e 100644 --- a/src/game/tremulous.h +++ b/src/game/tremulous.h @@ -291,14 +291,14 @@ TREMULOUS EDGE MOD SRC FILE //Hummel #define LEVEL5_UPG_SPEED 1.1f #define LEVEL5_UPG_VALUE AVM(400) -#define LEVEL5_UPG_HEALTH AHM(200) +#define LEVEL5_UPG_HEALTH AHM(180) #define LEVEL5_UPG_REGEN (0.03f * LEVEL5_UPG_HEALTH) #define LEVEL5_UPG_COST 2 -#define LEVEL5_CLAW_U_REPEAT 500 +#define LEVEL5_CLAW_U_REPEAT 333 #define LEVEL5_CLAW_U_K_SCALE 1.0f #define LEVEL5_CLAW_U_RANGE 70.0f #define LEVEL5_CLAW_WIDTH 12.0f -#define LEVEL5_CLAW_DMG ADM(40) +#define LEVEL5_CLAW_DMG ADM(30) #define LEVEL5_PRICKLES_REPEAT 200 #define LEVEL5_PRICKLES_NEXTTHINK 6000 #define LEVEL5_PRICKLES_RADIUS 50 @@ -307,14 +307,14 @@ TREMULOUS EDGE MOD SRC FILE #define LEVEL5_PRICKLES_DMG 6 #define LEVEL5_PRICKLES_RELOADTIME 2300 #define LEVEL5_PRICKLES_AMMO 10 -#define LEVEL5_POUNCE_JUMP_MAG 500 -#define LEVEL5_POUNCE_REPEAT 1000 -#define LEVEL5_POUNCE_TIME 600 +#define LEVEL5_POUNCE_JUMP_MAG 800 +#define LEVEL5_POUNCE_REPEAT 300 +#define LEVEL5_POUNCE_TIME 800 #define LEVEL5_POUNCE_TIME_MIN 200 #define LEVEL5_POUNCE_DMG 40 -#define LEVEL5_POUNCE_RANGE 48.0f -#define LEVEL5_POUNCE_WIDTH 14.0f -#define LEVEL5_POUNCE_SPEED_MOD 0.75f +#define LEVEL5_POUNCE_RANGE 40.0f +#define LEVEL5_POUNCE_WIDTH 12.0f +#define LEVEL5_POUNCE_SPEED_MOD 0.8f /* * HUMAN */ |