FadeToBlack()/FadeFromBlack()
Zephirius
Member Posts: 419
I'm trying my hand at a limited cutscene starting out with FadeFromBlack(). I'm uncertain how you have those dramatic fades in and out - lengthy ones at that. I've got it on the slowest setting but the fade hppens fast no matter what.
Thanks in advance for any help.
if ((GetLevelByClass(CLASS_TYPE_DRUID, oPC)>0))
if (GetIsSkillSuccessful(oPC, SKILL_ANIMAL_EMPATHY, 16))
{
effect eParalyze = EffectCutsceneParalyze();
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eParalyze, oPC, 15.0f);
AssignCommand(oPC, ClearAllActions());
ActionDoCommand(FadeFromBlack(oPC, FADE_SPEED_SLOWEST));
//Do cutscene stuff here...
}
}
Thanks in advance for any help.
0
Comments
#include "x3_inc_string" void main() { int DoOnce = GetLocalInt(OBJECT_SELF, GetTag(OBJECT_SELF)); // Set it so that the script only fires once if (DoOnce==TRUE) { return; } SetLocalInt(OBJECT_SELF, GetTag(OBJECT_SELF), TRUE); // End DoOnce check object oPC = GetNearestCreature(CREATURE_TYPE_PLAYER_CHAR, PLAYER_CHAR_IS_PC, OBJECT_SELF); effect eParalyze = EffectParalyze(); DelayCommand(3.0, ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eParalyze, oPC, 8.5)); BlackScreen(oPC); DelayCommand(3.0, FadeFromBlack(oPC, FADE_SPEED_SLOWEST)); oPC = GetEnteringObject(); if (!GetIsPC(oPC)) return; AssignCommand(oPC, ActionPlayAnimation(ANIMATION_LOOPING_SIT_CROSS, 1.0, 7.0)); SetCommandable(TRUE, oPC); string sSound = "gui_learnspell"; DelayCommand(9.0, AssignCommand(oPC, PlaySound(sSound))); string sWarning = StringToRGBString ("You find yourself washed ashore a desert insland with no memory of how you got there...", "770"); DelayCommand(9.0, FloatingTextStringOnCreature(sWarning, oPC)); }It's just an opening "scene" depicting a castaway "washed" up on shore...
Suggestions?
I'm racking my brain (what's left of it) on how to do this?
Any help to nudge me in the right direction would be greatly appreciated.
Saves countless hours of debugging for this and many other cutscene actions, so the learning curve is highly worthwhile.