Ejemplo n.º 1
0
int AvHMine::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_FIFTH_SLOT;
	p->iPosition = 1;

	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = "MineAmmo";
	p->iMaxAmmo1 = 0;//BALANCE_VAR(kMineMaxAmmo);
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = BALANCE_VAR(kMineDamage);
	p->iMaxClip = BALANCE_VAR(kMineMaxAmmo);
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY;//ITEM_FLAG_LIMITINWORLD | ITEM_FLAG_EXHAUSTIBLE;
	p->iId = AVH_WEAPON_MINE;
	p->iWeight = kDefaultTertiaryWeaponWeight;

//	p->pszName = STRING(pev->classname);
//	p->pszAmmo1 = "MineAmmo";
//	p->iMaxAmmo1 = kMineMaxAmmo;
//	p->pszAmmo2 = NULL;
//	p->iMaxAmmo2 = -1;
//	p->iMaxClip = WEAPON_NOCLIP;
//	p->iFlags = ITEM_FLAG_LIMITINWORLD | ITEM_FLAG_EXHAUSTIBLE;
//	p->iId = m_iId = AVH_WEAPON_MINE;
//	p->iWeight = 5;
	
	return 1;
}
Ejemplo n.º 2
0
void AvHMUUpdateAlienEnergy(float inTimePassed, int inUser3, int inUser4, float& ioFuser)
{
	if(	(inUser3 == AVH_USER3_ALIEN_PLAYER1) ||
		(inUser3 == AVH_USER3_ALIEN_PLAYER2) ||
		(inUser3 == AVH_USER3_ALIEN_PLAYER3) ||
		(inUser3 == AVH_USER3_ALIEN_PLAYER4) ||
		(inUser3 == AVH_USER3_ALIEN_PLAYER5) ||
		(inUser3 == AVH_USER3_ALIEN_PLAYER6))
	{
		if(!GetHasUpgrade(inUser4, MASK_PLAYER_STUNNED))
		{
			// Percentage (0-1) per second
			float theAlienEnergyRate = (float)BALANCE_VAR(kAlienEnergyRate);
			//float kFadeChargingDeplectionRate = -2.8f*kAlienEnergyRate;
			float kChargingDepletionRate = -BALANCE_VAR(kChargingEnergyScalar)*theAlienEnergyRate;

			const float kMultiplier = GetHasUpgrade(inUser4, MASK_BUFFED) ? (1.0f + BALANCE_VAR(kPrimalScreamEnergyFactor)) : 1.0f;
			float theEnergyRate = theAlienEnergyRate*kMultiplier;

			float theUpgradeFactor = 1.0f;
			int theNumLevels = AvHGetAlienUpgradeLevel(inUser4, MASK_UPGRADE_5);
			if(theNumLevels > 0)
			{

				theUpgradeFactor += theNumLevels*BALANCE_VAR(kAdrenalineEnergyPercentPerLevel);
			}

			float theCurrentEnergy = ioFuser/kNormalizationNetworkFactor;
			
			float theNewEnergy = theCurrentEnergy + inTimePassed*theAlienEnergyRate*theUpgradeFactor;

//			// If we're charging, reduce energy
//			// Removed: Charge only reduces energy when active
//			if(GetHasUpgrade(inUser4, MASK_ALIEN_MOVEMENT))
//			{
//				if(inUser3 == AVH_USER3_ALIEN_PLAYER4)
//				{
//					theNewEnergy += inTimePassed*kFadeChargingDeplectionRate;
//				}
//				else
//				{
//					theNewEnergy += inTimePassed*kChargingDepletionRate;
//				}
//			}
			
			theNewEnergy = min(max(theNewEnergy, 0.0f), 1.0f);
			
			ioFuser = theNewEnergy*kNormalizationNetworkFactor;
		}
	}
}
Ejemplo n.º 3
0
void AvHMovementChamber::EnergyAliensThink()
{
	// Don't teleport until it's "warmed up"
	SetUse(&AvHMovementChamber::TeleportUse);

	// Loop through all players
	CBaseEntity* theBaseEntity = NULL;
	int theNumEntsProcessed = 0;
	
	while(((theBaseEntity = UTIL_FindEntityInSphere(theBaseEntity, this->pev->origin, BALANCE_VAR(kMovementChamberEnergyRange))) != NULL) && (theNumEntsProcessed < BALANCE_VAR(kAlienChamberMaxPlayers)))
	{
		if(theBaseEntity->pev->team == this->pev->team)
		{
			float theEnergizeAmount = BALANCE_VAR(kMovementChamberEnergyAmount);
			AvHBaseBuildable* theBuildable = dynamic_cast<AvHBaseBuildable*>(theBaseEntity);
			AvHPlayer* thePlayer = dynamic_cast<AvHPlayer*>(theBaseEntity);
			if(thePlayer && thePlayer->IsAlive())
			{
				if(thePlayer->Energize(theEnergizeAmount))
				{
					theNumEntsProcessed++;
				}
			}
			// Energize alien buildables
//			else if(theBuildable)
//			{
//				if(theBuildable->Energize(theEnergizeAmount))
//				{
//					theNumEntsProcessed++;
//				}
//			}
		}
	}

	// Play an animation (spin the arms if energizing)
	int theIdle = this->GetIdle2Animation();

	// Play sound
	if(theNumEntsProcessed > 0)
	{
		EMIT_SOUND(this->edict(), CHAN_AUTO, kAlienEnergySound, 1.0f, ATTN_NORM);

		theIdle = this->GetIdle1Animation();
	}

	this->PlayAnimationAtIndex(theIdle);
	
	// Set next think
	this->pev->nextthink = gpGlobals->time + BALANCE_VAR(kMovementChamberThinkInterval);
}
Ejemplo n.º 4
0
void AvHDefenseChamber::SetHasBeenBuilt()
{
	AvHAlienUpgradeBuilding::SetHasBeenBuilt();
	
	SetThink(&AvHDefenseChamber::RegenAliensThink);
	this->pev->nextthink = gpGlobals->time + BALANCE_VAR(kDefenseChamberThinkInterval);
}
Ejemplo n.º 5
0
void AvHPistol::Spawn()
{
    AvHMarineWeapon::Spawn();

	Precache();

	this->m_iId = AVH_WEAPON_PISTOL;
	this->m_iDefaultAmmo = BALANCE_VAR(kHGMaxClip)*(BALANCE_VAR(kMarineSpawnClips) + 1);

    // Set our class name
	this->pev->classname = MAKE_STRING(kwsPistol);

	SET_MODEL(ENT(this->pev), kHGWModel);

	FallInit();// get ready to fall down.
}
Ejemplo n.º 6
0
void AvHBaseBuildable::RecycleComplete()
{
	// Look at whether it has been built and health to determine how many points to give back
	float thePercentage = BALANCE_VAR(kRecycleResourcePercentage);

	if(!this->GetIsBuilt())
	{
		thePercentage = .8f;
	}

	// Make sure the building is still alive, can't get points back if it's dead
	if(this->pev->health <= 0)
	{
		thePercentage = 0.0f;
	}

	// Look up team
	AvHTeam* theTeam = GetGameRules()->GetTeam((AvHTeamNumber)this->pev->team);
	if(theTeam)
	{
		bool theIsEnergyTech = AvHSHUGetDoesTechCostEnergy(this->mMessageID);
		ASSERT(!theIsEnergyTech);

		float thePointsBack = GetGameRules()->GetCostForMessageID(this->mMessageID)*thePercentage;
		theTeam->SetTeamResources(theTeam->GetTeamResources() + thePointsBack);

        // Play "+ resources" event
        AvHSUPlayNumericEventAboveStructure(thePointsBack, this);

		// puzl: 980
		// Less smoke and more sparks  for recycled buildings
		this->Killed(this->pev, GIB_RECYCLED);
		// :puzl
	}
}
Ejemplo n.º 7
0
bool AvHBaseBuildable::Regenerate(float inRegenerationAmount, bool inPlaySound, bool dcHealing)
{
	bool theDidHeal = false;
	if ( gpGlobals->time > this->mTimeOfLastDCRegeneration + BALANCE_VAR(kDefenseChamberThinkInterval) - 0.05f || (dcHealing == false)) {
		if ( dcHealing )
			this->mTimeOfLastDCRegeneration = gpGlobals->time;
		float theMaxHealth = this->mBaseHealth;

		if(!this->GetIsBuilt())
		{
			float theNormalizedBuildPercentage = this->GetNormalizedBuildPercentage();

			theMaxHealth = (kBaseHealthPercentage + theNormalizedBuildPercentage*(1.0f - kBaseHealthPercentage))*this->mBaseHealth;
		}

		// If we aren't at full health, heal health
		if(this->pev->health < theMaxHealth)
		{
			this->pev->health = min(theMaxHealth, this->pev->health + inRegenerationAmount);
			this->HealthChanged();
			theDidHeal = true;
		}
		
		// Play regen event
		if(theDidHeal)
		{
			if(inPlaySound)
			{
				// Play regeneration event
				PLAYBACK_EVENT_FULL(0, this->edict(), gRegenerationEventID, 0, this->pev->origin, (float *)&g_vecZero, 1.0f, 0.0, /*theWeaponIndex*/ 0, 0, 0, 0 );
			}
		}
	}
	return theDidHeal;
}
Ejemplo n.º 8
0
int	AvHGrenade::GetItemInfo(ItemInfo *p) const
{
    p->iSlot = AVH_FIFTH_SLOT;
    p->iPosition = 0;

    p->pszName = STRING(pev->classname);
    p->pszAmmo1 = "HandGrenadeAmmo";
    p->iMaxAmmo1 = BALANCE_VAR(kHandGrenadeMaxAmmo);
    p->pszAmmo2 = NULL;
    p->iMaxAmmo2 = BALANCE_VAR(kHandGrenadeDamage);
    p->iMaxClip = BALANCE_VAR(kHandGrenadeMaxAmmo);;
    p->iFlags = ITEM_FLAG_EXHAUSTIBLE;
    p->iId = AVH_WEAPON_GRENADE;
    p->iWeight = kGrenadeWeaponWeight;
    
    return 1;
}
Ejemplo n.º 9
0
int AvHGrenadeGun::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_FIRST_SLOT;
	p->iPosition = 8;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = "GrenadeAmmo";
	p->iMaxAmmo1 = BALANCE_VAR(kGGMaxAmmo);
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = BALANCE_VAR(kGrenadeDamage);
 	p->iMaxClip = BALANCE_VAR(kGGMaxClip);
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | PRIMARY_WEAPON;
	p->iId = AVH_WEAPON_GRENADE_GUN;
	p->iWeight = kSpecialPrimaryWeaponWeight;
	
	return 1;
}
Ejemplo n.º 10
0
int AvHHeavyMachineGun::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_FIRST_SLOT;
	p->iPosition = 3;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = "HMGAmmo";
	p->iMaxAmmo1 = BALANCE_VAR(kHMGMaxAmmo);
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = BALANCE_VAR(kHMGDamage);
	p->iMaxClip = BALANCE_VAR(kHMGMaxClip);
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | PRIMARY_WEAPON;
	p->iId = AVH_WEAPON_HMG;
	p->iWeight = kSpecialPrimaryWeaponWeight;
	
	return 1;
}
Ejemplo n.º 11
0
int AvHPistol::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_SECOND_SLOT;
	p->iPosition = 0;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = "HGAmmo";
	p->iMaxAmmo1 = BALANCE_VAR(kHGMaxAmmo);
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = BALANCE_VAR(kHGDamage);
	p->iMaxClip = BALANCE_VAR(kHGMaxClip);
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | SECONDARY_WEAPON;
	p->iId = AVH_WEAPON_PISTOL;
	p->iWeight = kDefaultSecondaryWeaponWeight;
	
	return 1;
}
Ejemplo n.º 12
0
int	AvHSpore::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_SECOND_SLOT;
	p->iPosition = 6;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = NULL;
	p->iMaxAmmo1 = -1;
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = (int)(BALANCE_VAR(kSporeDamage)/BALANCE_VAR(kSporeCloudThinkInterval));
	p->iMaxClip = WEAPON_NOCLIP;
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | ITEM_FLAG_NOAUTORELOAD | ITEM_FLAG_SELECTONEMPTY | ONE_HIVE_REQUIRED;
	p->iId = AVH_WEAPON_SPORES;
	p->iWeight = kDefaultPrimaryWeaponWeight;
	
	return 1;
}
Ejemplo n.º 13
0
void AvHDefenseChamber::RegenAliensThink()
{
	// Loop through all players
	CBaseEntity* theBaseEntity = NULL;
	int theNumEntsHealed = 0;
	
	while(((theBaseEntity = UTIL_FindEntityInSphere(theBaseEntity, this->pev->origin, BALANCE_VAR(kDefensiveChamberHealRange))) != NULL) && (theNumEntsHealed < BALANCE_VAR(kAlienChamberMaxPlayers)))
	{
		if(theBaseEntity->pev->team == this->pev->team)
		{
			AvHBaseBuildable* theBuildable = dynamic_cast<AvHBaseBuildable*>(theBaseEntity);
			AvHPlayer* thePlayer = dynamic_cast<AvHPlayer*>(theBaseEntity);
			float thePercent=BALANCE_VAR(kDefensiveChamberRegenPercent)/100.0f;
			float amount=BALANCE_VAR(kDefensiveChamberRegenAmount) + (theBaseEntity->pev->max_health*thePercent);
			if(thePlayer && thePlayer->IsAlive())
			{
				if(thePlayer->Heal(amount, true, true))
				{
					theNumEntsHealed++;
				}
			}
			else if(theBuildable && theBuildable->GetIsBuilt() && (theBuildable != this))
			{
				if(theBuildable->Regenerate(amount, true, true))
				{
					theNumEntsHealed++;
				}
			}
		}
	}
	
	// Set next think
	this->pev->nextthink = gpGlobals->time + BALANCE_VAR(kDefenseChamberThinkInterval);
	
	// Play a random idle animation
	int theIdle = this->GetIdle1Animation();
	
	if(RANDOM_LONG(0, 1))
	{
		theIdle = this->GetIdle2Animation();
	}
	
	this->PlayAnimationAtIndex(theIdle);
}
Ejemplo n.º 14
0
void AvHMovementChamber::SetHasBeenBuilt()
{
	AvHAlienUpgradeBuilding::SetHasBeenBuilt();
	
	// TODO: Include a "warm-up" time so movement chambers don't teleport the builder immediately
	//SetThink(&AvHMovementChamber::TeleportUseThink);

	SetThink(&AvHMovementChamber::EnergyAliensThink);
	this->pev->nextthink = gpGlobals->time + BALANCE_VAR(kMovementChamberThinkInterval);
}
Ejemplo n.º 15
0
void AvHHive::ProcessHealing()
{
	// Regenerate nearby friendly aliens
	CBaseEntity* theEntity = NULL;
	const int theHiveHealRadius = BALANCE_VAR(kHiveHealRadius);

	while((theEntity = UTIL_FindEntityInSphere(theEntity, this->pev->origin, theHiveHealRadius)) != NULL)
	{
		AvHPlayer* thePlayer = dynamic_cast<AvHPlayer*>(theEntity);
		if(thePlayer)
		{
			if(thePlayer->GetIsRelevant() && (thePlayer->GetTeam() == this->GetTeamNumber()) && !thePlayer->GetIsBeingDigested())
			{
                // Hive heals percentage of player health
                float theRegenPercentage = BALANCE_VAR(kHiveRegenerationPercentage);
                int theMaxHealth = AvHPlayerUpgrade::GetMaxHealth(thePlayer->pev->iuser4, (AvHUser3)thePlayer->pev->iuser3, thePlayer->GetExperienceLevel());
                float theRegenAmount = (theRegenPercentage*theMaxHealth);
                thePlayer->Heal(theRegenAmount, true);
			}
		}
	}
	
	// Regenerate self
	bool theDidHeal = false;
	
	// If we aren't at full health, heal health
	if(this->pev->health < this->mMaxHitPoints)
	{
        float theHiveRegenAmount = BALANCE_VAR(kHiveRegenerationAmount);
        float theCombatModeScalar = /*GetGameRules()->GetIsCombatMode() ? (1.0f/BALANCE_VAR(kCombatModeTimeScalar)) :*/ 1.0f;

		this->pev->health = min((float)this->mMaxHitPoints, this->pev->health + theHiveRegenAmount*theCombatModeScalar);
		theDidHeal = true;
	}
	
	// Play regen event
	if(theDidHeal)
	{
		// Play regeneration event
		PLAYBACK_EVENT_FULL(0, this->edict(), gRegenerationEventID, 0, this->pev->origin, (float *)&g_vecZero, 1.0f, 0.0, /*theWeaponIndex*/ 0, 0, 0, 0 );
	}
}
Ejemplo n.º 16
0
float AvHHive::GetReinforceTime() const
{
	const float kMaxRespawnTime = BALANCE_VAR(kAlienRespawnTime);

	float theRespawnTime = (kMaxRespawnTime - kMaxRespawnTime*this->mEnergy);

	// puzl 0000854 
	//  Decrease respawn wait time for aliens (NS: Classic)
	//	With one hive, for every player above six on the alien team, 
	//  reduce the per-player respawn wait time by two-thirds of a second. 
	//  With two hives, make the reduction one-third of a second. 
	//  With three (or more, in the case of weird custom maps) hives, do not apply it.

	AvHTeam* theTeam = GetGameRules()->GetTeam(GetTeamNumber());
	ASSERT(theTeam);

	int thePlayerModifier = theTeam->GetPlayerCount() - BALANCE_VAR(kAlienRespawnPlayerModifier);
	int theHiveCount = GetGameRules()->GetNumActiveHives(GetTeamNumber());
	
	if ( thePlayerModifier > 0 && theHiveCount < 3 ) 
	{
		float theTimeModifier = BALANCE_VAR(kAlienRespawnTimeModifier);

		// For one hive double the modifier
		if ( theHiveCount == 1 ) 
		{
			theTimeModifier *= 2.0f;
		}

		theRespawnTime -= theTimeModifier * (float)thePlayerModifier;
	}

	theRespawnTime = min(max(theRespawnTime, 0.0f), kMaxRespawnTime);

	return theRespawnTime;
}
Ejemplo n.º 17
0
float AvHMarineWeapon::ComputeAttackInterval() const
{
    float theROF = this->GetRateOfFire();

    int theUser4 = this->m_pPlayer->pev->iuser4;

    // Speed attack if in range of primal scream
    if(GetHasUpgrade(theUser4, MASK_BUFFED))
    {
        float theCatalystROFFactor = 1.0f + BALANCE_VAR(kCatalystROFFactor);
        theROF /= theCatalystROFFactor;
    }

    return theROF;

}
Ejemplo n.º 18
0
void AvHSonicGun::FireProjectiles(void)
{
	Vector vecSrc	 = m_pPlayer->GetGunPosition( );
	Vector vecAiming = m_pPlayer->GetAutoaimVector( AUTOAIM_5DEGREES );
	
	ASSERT(this->m_iPrimaryAmmoType >= 0);
	//int theNumBullets = min(kSGBulletsPerShot, this->m_iClientClip);

	float theDamageMultiplier;
	AvHPlayerUpgrade::GetWeaponUpgrade(this->m_pPlayer->pev->iuser3, this->m_pPlayer->pev->iuser4, &theDamageMultiplier);
	float theDamage = this->mDamage*theDamageMultiplier;
	
    // Fire the bullets and apply damage
	//this->m_pPlayer->FireBullets(kSGBulletsPerShot, vecSrc, vecAiming, this->GetProjectileSpread(), this->mRange, 0, 0, theDamage);
	this->m_pPlayer->FireBulletsPlayer(BALANCE_VAR(kSGBulletsPerShot), vecSrc, vecAiming, this->GetProjectileSpread(), this->mRange, BULLET_PLAYER_BUCKSHOT, 0, theDamage, 0, this->m_pPlayer->random_seed);
}
Ejemplo n.º 19
0
void AvHHeavyMachineGun::Spawn()
{
    AvHMarineWeapon::Spawn();

    Precache();

    this->m_iId = AVH_WEAPON_HMG;
    this->m_iDefaultAmmo = BALANCE_VAR(kHMGMaxClip);

    // Set our class name
    this->pev->classname = MAKE_STRING(kwsHeavyMachineGun);

    SET_MODEL(ENT(this->pev), kHMGWModel);

    FallInit();// get ready to fall down.
}
Ejemplo n.º 20
0
int AvHSpitGun::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_FIRST_SLOT;
	p->iPosition = 7;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = NULL;
	p->iMaxAmmo1 = -1;
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = BALANCE_VAR(kSpitGDamage);
	p->iMaxClip = WEAPON_NOCLIP;
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | ITEM_FLAG_NOAUTORELOAD | ITEM_FLAG_SELECTONEMPTY;
	p->iId = AVH_WEAPON_SPIT;
	p->iWeight = kDefaultPrimaryWeaponWeight;
	
	return 1;
}
Ejemplo n.º 21
0
int AvHDevour::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_SECOND_SLOT;
	p->iPosition = 5;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = NULL;
	p->iMaxAmmo1 = -1;
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = BALANCE_VAR(kDevourDamage);
	p->iMaxClip = WEAPON_NOCLIP;
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | ITEM_FLAG_NOAUTORELOAD | ONE_HIVE_REQUIRED;
	p->iId = AVH_WEAPON_DEVOUR;
	p->iWeight = kDefaultPrimaryWeaponWeight;
	
	return 1;
}
Ejemplo n.º 22
0
int AvHStomp::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_THIRD_SLOT;
	p->iPosition = 4;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = NULL;
	p->iMaxAmmo1 = -1;
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = (int)BALANCE_VAR(kStompTime);
	p->iMaxClip = WEAPON_NOCLIP;
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | ITEM_FLAG_NOAUTORELOAD | ONE_HIVE_REQUIRED | TWO_HIVES_REQUIRED;
	p->iId = AVH_WEAPON_STOMP;
	p->iWeight = kDefaultPrimaryWeaponWeight;
	
	return 1;
}
Ejemplo n.º 23
0
int AvHCharge::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_FOURTH_SLOT;
	p->iPosition = 6;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = NULL;
	p->iMaxAmmo1 = -1;
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = BALANCE_VAR(kChargeDamage);
	p->iMaxClip = WEAPON_NOCLIP;
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | ITEM_FLAG_NOAUTORELOAD | ONE_HIVE_REQUIRED | TWO_HIVES_REQUIRED | THREE_HIVES_REQUIRED;
	p->iId = AVH_ABILITY_CHARGE;
	p->iWeight = kDefaultPrimaryWeaponWeight;
	
	return 1;
}
Ejemplo n.º 24
0
int	AvHDivineWind::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_FOURTH_SLOT;
	p->iPosition = 5;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = NULL;
	p->iMaxAmmo1 = -1;
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = BALANCE_VAR(kDivineWindDamage);
	p->iMaxClip = WEAPON_NOCLIP;
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | ITEM_FLAG_NOAUTORELOAD | ITEM_FLAG_SELECTONEMPTY | ONE_HIVE_REQUIRED | TWO_HIVES_REQUIRED | THREE_HIVES_REQUIRED;
	p->iId = AVH_WEAPON_DIVINEWIND;
	p->iWeight = kDefaultPrimaryWeaponWeight;
	
	return 1;
}
Ejemplo n.º 25
0
int AvHPrimalScream::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_FOURTH_SLOT;
	p->iPosition = 4;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = "";
	p->iMaxAmmo1 = -1;
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = BALANCE_VAR(kPrimalScreamRange);
	p->iMaxClip = WEAPON_NOCLIP;
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | ITEM_FLAG_NOAUTORELOAD | ONE_HIVE_REQUIRED | TWO_HIVES_REQUIRED | THREE_HIVES_REQUIRED;
	p->iId = AVH_WEAPON_PRIMALSCREAM;
	p->iWeight = kDefaultPrimaryWeaponWeight;
	
	return 1;
}
Ejemplo n.º 26
0
int AvHHealingSpray::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_SECOND_SLOT;
	p->iPosition = 1;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = NULL;
	p->iMaxAmmo1 = -1;
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = BALANCE_VAR(kHealingSprayDamage);
	p->iMaxClip = WEAPON_NOCLIP;
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | ITEM_FLAG_NOAUTORELOAD | ITEM_FLAG_SELECTONEMPTY | ONE_HIVE_REQUIRED;
	p->iId = AVH_WEAPON_HEALINGSPRAY;
	p->iWeight = kDefaultPrimaryWeaponWeight;
	
	return 1;
}
Ejemplo n.º 27
0
int AvHBileBombGun::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_THIRD_SLOT;
	p->iPosition = 3;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = NULL;
	p->iMaxAmmo1 = -1;//kSpikeMaxClip;
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = BALANCE_VAR(kBileBombDamage);
	p->iMaxClip = WEAPON_NOCLIP;
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | ITEM_FLAG_NOAUTORELOAD | ONE_HIVE_REQUIRED | TWO_HIVES_REQUIRED;
	p->iId = AVH_WEAPON_BILEBOMB;
	p->iWeight = kDefaultPrimaryWeaponWeight;
	
	return 1;
}
Ejemplo n.º 28
0
int AvHKnife::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_THIRD_SLOT;
	p->iPosition = 1;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = NULL;
	p->iMaxAmmo1 = -1;
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = BALANCE_VAR(kKNDamage);
	p->iMaxClip = WEAPON_NOCLIP;
	//p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | ITEM_FLAG_NOAUTORELOAD | ITEM_FLAG_SELECTONEMPTY;
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | ITEM_FLAG_NOAUTORELOAD;
	p->iId = AVH_WEAPON_KNIFE;
	p->iWeight = kMeleeWeaponWeight;
	
	return 1;
}
Ejemplo n.º 29
0
int AvHWelder::GetItemInfo(ItemInfo *p) const
{
	p->iSlot = AVH_FOURTH_SLOT;
	p->iPosition = 8;
	
	p->pszName = STRING(pev->classname);
	p->pszAmmo1 = NULL;
	p->iMaxAmmo1 = -1;
	p->pszAmmo2 = NULL;
	p->iMaxAmmo2 = BALANCE_VAR(kWelderDamage);
	p->iMaxClip = WEAPON_NOCLIP;
	//p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | ITEM_FLAG_NOAUTORELOAD | ITEM_FLAG_SELECTONEMPTY;
	p->iFlags = ITEM_FLAG_NOAUTOSWITCHEMPTY | ITEM_FLAG_NOAUTORELOAD;
	p->iId = AVH_WEAPON_WELDER;
	p->iWeight = kDefaultTertiaryWeaponWeight;
	
	return 1;
}
Ejemplo n.º 30
0
char* AvHAlienResourceTower::GetActiveSoundList() const
{
	char* theActiveSoundList = NULL;

	// Don't play active sounds until kAlienResourceTowerSoundDelayTime seconds have passed, to prevent marines from knowing where aliens start
	int theTimeToWaitBeforeSounds = BALANCE_VAR(kAlienResourceTowerSoundDelayTime);
	int theGameTime = GetGameRules()->GetGameTime();
	if((theGameTime > 0) && (theGameTime >= theTimeToWaitBeforeSounds))
	{
		theActiveSoundList = kAlienResourceTowerSoundList;
	}
	else
	{
		int a = 0;
	}

	return theActiveSoundList;
}