Ejemplo n.º 1
0
bool DoomsDayDevice::Fire( CPlayerObj& playerObj )
{
	// Make sure it's from someone on our team.
	if( playerObj.GetTeamID( ) != m_nOwningTeamID )
		return false;

	// Send a message letting the players know the device has been activated.
	CAutoMessage cMsg;
	cMsg.Writeuint8( MID_DOOMSDAY_MESSAGE );
	cMsg.Writeuint8( MID_DOOMSDAY_DEVICE_COMPLETED );
	cMsg.Writeuint8( m_nOwningTeamID );
	g_pLTServer->SendToClient( cMsg.Read(), LTNULL, MESSAGE_GUARANTEED );

	// Give the activating player a bunch of points.
	ServerGameOptions& sgo = g_pGameServerShell->GetServerGameOptions( );
	uint32 nBonus = sgo.GetDoomsday( ).m_nDeviceCompletedScore;
	playerObj.GetPlayerScore()->AddBonus( nBonus );

	if( !BeginFire( ))
		return false;

	return true;
}
Ejemplo n.º 2
0
void AGWWeaponRanged::InputPressed()
{
	BeginFire();
}
Ejemplo n.º 3
0
void AGWWeaponRanged::ServerBeginFire_Implementation()
{
	BeginFire();
}