void RiseDeadSpell::End()
{
	if(ValidIONum(m_entity)) {
		Entity *entity = entities[m_entity];
		
		ARX_SOUND_PlaySFX(SND_SPELL_ELECTRIC, &entity->pos);
		
		if(entity->scriptload && (entity->ioflags & IO_NOSAVE)) {
			AddRandomSmoke(entity,100);
			Vec3f posi = entity->pos;
			posi.y-=100.f;
			MakeCoolFx(posi);
			
			LightHandle nn = GetFreeDynLight();

			if(lightHandleIsValid(nn)) {
				EERIE_LIGHT * light = lightHandleGet(nn);
				
				light->intensity = Random::getf(0.7f, 2.7f);
				light->fallend = 600.f;
				light->fallstart = 400.f;
				light->rgb = Color3f(1.0f, 0.8f, 0.f);
				light->pos = posi;
				light->duration = 600;
			}

			entity->destroyOne();
		}
	}
	
	endLightDelayed(m_light, 500);
}
Beispiel #2
0
void RepelUndeadSpell::End() {
	
	ARX_SOUND_Stop(m_snd_loop);
	m_snd_loop = audio::SourcedSample();
	
	endLightDelayed(m_light, GameDurationMs(500));
}
void CreateFieldSpell::End() {
	
	endLightDelayed(m_field.lLightId, 800);
	
	if(ValidIONum(m_entity)) {
		delete entities[m_entity];
	}
}
Beispiel #4
0
void PoisonProjectileSpell::End() {
	
	for(size_t i = 0; i < m_projectiles.size(); i++) {
		CPoisonProjectile * projectile = m_projectiles[i];
		
		endLightDelayed(projectile->lLightId, 2000);
		
		delete projectile;
	}
	m_projectiles.clear();
}
Beispiel #5
0
PoisonProjectileSpell::~PoisonProjectileSpell() {
	
	for(size_t i = 0; i < m_projectiles.size(); i++) {
		CPoisonProjectile * projectile = m_projectiles[i];
		
		endLightDelayed(projectile->lLightId, GameDurationMs(2000));
		
		delete projectile;
	}
	m_projectiles.clear();
}
void MassLightningStrikeSpell::End() {
	
	endLightDelayed(m_light, 200);
	
	ARX_SOUND_Stop(m_snd_loop);
	ARX_SOUND_PlaySFX(SND_SPELL_LIGHTNING_END);
	
	for(std::vector<CLightning *>::iterator it = pTab.begin(); it != pTab.end(); ++it) {
		delete *it;
	}
	pTab.clear();
}
void ConfuseSpell::End() {
	
	m_targets.clear();
	endLightDelayed(m_light, 500);
}
void ConfuseSpell::End() {
	
	m_targets.clear();
	endLightDelayed(m_light, ArxDurationMs(500));
}
Beispiel #9
0
void RuneOfGuardingSpell::End() {
	
	endLightDelayed(m_light, 500);
}
Beispiel #10
0
void RepelUndeadSpell::End() {
	ARX_SOUND_Stop(m_snd_loop);
	
	endLightDelayed(m_light, 500);
}
Beispiel #11
0
void RuneOfGuardingSpell::End() {
	
	endLightDelayed(m_light, GameDurationMs(500));
}
Beispiel #12
0
void RepelUndeadSpell::End() {
	ARX_SOUND_Stop(m_snd_loop);
	
	endLightDelayed(m_light, GameDurationMs(500));
}