RE: Shadow
What do you mean exactly? Do you want the screen to go black? Want the slime-net to fade in as an activation?
if you want the slime to fade in, then make it 'inactive' in the editor, and then use the function:
SetPropActiveAndFade(string& asName, bool abActive, float afFadeTime);
if you want to fade out black, and then fade in again, then you should use:
FadeOut(0);
AddTimer("FadeIn_1", 2, "FadeIn_1");
then add another timer
void FadeIn_1(string &in asTimer)
{
FadeIn(2);
}
Playing sound effects are pretty easy... You should have tried it before, but here is the script:
PlaySoundAtEntity(string& asSoundName, string& asSoundFile, string& asEntity, float afFadeTime, bool abSaveSound);
Creates a sound on an entity.
asSoundName - internal name
asSoundFile - the sound to use + extension .snt
asEntity - the entity to create the sound at, can be “Player”
afFadeTime - time in seconds the sound needs to fade. Avoids enemies hearing the sound if afFadeTime is at least 0.1f
abSaveSound - determines whether a sound should “remember” its state. If true, the sound is never attached to the entity! Also note that saving should on be used on looping sounds!
Also: The shadow sound is called: guardian_activated, guardian_distant, guardian_distant1, guardian_distant2, guardian_distant3,
Trying is the first step to success.
|