dod_get_user_weapon added. Compile options for old/new forwards system

This commit is contained in:
Lukasz Wlasinksi
2004-07-30 12:49:11 +00:00
parent 77c887d514
commit 8e23ca757a
8 changed files with 96 additions and 4 deletions

View File

@ -97,7 +97,6 @@ void Client_CurWeapon(void* mValue){
case 1:
if (!iState) break;
iId = *(int*)mValue;
mPlayer->current = iId;
break;
case 2:
if ( !iState || !isModuleActive() )
@ -106,6 +105,7 @@ void Client_CurWeapon(void* mValue){
if ( weaponData[iId].needcheck ){
iId = get_weaponid(mPlayer);
mPlayer->current = iId;
}
if (iClip > -1) {
if ( mPlayer->current == 17 ){
@ -167,11 +167,22 @@ void Client_Health_End(void* mValue){
TA = 1;
}
#ifdef FORWARD_OLD_SYSTEM
g_damage_info.exec( pAttacker->index, mPlayer->index, damage, weapon, aim, TA );
#else
MF_ExecuteForward( iFDamage,pAttacker->index, mPlayer->index, damage, weapon, aim, TA );
#endif
if ( !mPlayer->IsAlive() ){
pAttacker->saveKill(mPlayer,weapon,( aim == 1 ) ? 1:0 ,TA);
#ifdef FORWARD_OLD_SYSTEM
g_death_info.exec( pAttacker->index, mPlayer->index, weapon, aim, TA );
#else
MF_ExecuteForward( iFDeath,pAttacker->index, mPlayer->index, weapon, aim, TA );
#endif
}
}