I think I am running into a few issues. One of the largest is interpreting my timeing, as relates to action queues and when I need to start counting; from the beginning of the cutscene, or from the previous action.
The other is getting my creature (spawned in during the cutscene) to perform her movement and actions I wish her to do. Also, I need to destroy her at the end, but she is being sutubborn.
'>
I thought, after reading, that I may need to use the GestaltTagActionMove function (and the related GestaltTag* functions), but it had no effect on my creature.
Needless to say, this script is only partly functioning. Can anyone give me some pointers? It would be much appreciated.
'> If it looks a little messy right now, well...it's because it is.
'> I'm flailing around, trying to identify the issue. I'll clean it up later.
'>
/*
The following script is the first cutscene taking place in the "Ruins of Shadhet - Catacombs"
dungeon run. This is in the Weaving Room, and shows the ghost Leila. On the loom, the PC
will see a battle scene, depicting Jassad warring against a desert rival.
Leila appears, sitting at the loom, and the PC sees her weaving the half-finished tapestry.
She does not see/react to the PC’s. She stops in her weaving, and lays a hand on the
cheek of Jassad…then does the same for the rival. A single tear tracks down her cheek,
then she fades.
*/
#include "in_g_cutscene"
void main()
{
//Define the Actors in the cutscene.
object oPC = GetLocalObject(GetModule(),"cutsceneviewer");
string sActor = ("nh_Leila");
object oLoom = GetObjectByTag("leila_loom");
object oActor = GetObjectByTag("nh_Leila");
object oWP = GetWaypointByTag("WP_LeilaSpawn");
//Retrieve the facing of the PC.
float fFace = GetFacing(oPC);
//Start the cutscene, and fade in.
GestaltStartCutscene (oPC, "cs_gld_shdleila1",TRUE,TRUE,TRUE,TRUE,2);
GestaltCameraFade (0.0, oPC, FADE_IN, FADE_SPEED_MEDIUM);
//The cutscene has started, and we deliver first line of text.
GestaltSpeak (3.0, oPC,
"Before you is a loom, a tapestry half-finished upon it. You can make out a" +
" battle scene, depicting Jassad warring against another man.");
//It is here that Leila appears. We will use an spawn-in animation, and also have her spawn in
//in cutscene mode, which allows her to pass through PC's as she moves about the room.
GestaltCreate (6.0, oWP, OBJECT_TYPE_CREATURE, "nh_Leila", "");
//She moves to the loom, and play the GET_MID animation while the rest of the scene plays out
GestaltTagActionMove (0.0, sActor, oLoom, FALSE, 1.0, 0.0, "", TRUE);
GestaltTagActionAnimate (0.0, sActor, ANIMATION_LOOPING_GET_MID, 11.0);
//Here is the next bit of information the PC's will see.
GestaltSpeak (9.0, oPC,
"A ghost appears...a ghost of a beautiful woman. It troubles you not, nor does" +
" it appear to even notice you. It begins to weave the tapestry. You see" +
" threads, suddenly animate, weave in and out of the warp.");
//Here is the last bit of information the PC's will see.
GestaltSpeak (15.0, oPC,
"She stops in her weaving, and lays a hand on the cheek of Jassad…then does the" +
" same for the rival. A single tear tracks down her cheek.");
// Fade to black and remove the NPC
GestaltCameraFade (22.0, oPC, FADE_CROSS, FADE_SPEED_SLOW,2.0);
GestaltTagActionDestroy (23.0, sActor, oActor, sActor);
//Camera movements//
//The camera starts and ends directly behind the PC
//The camera starts 10 meters away and ends 5 meters away
//The camera starts at 50 degrees from the vertical, and ends angled almost
//90 degrees from the vertical pole
//The result is to have the camera start behind the PC, facing the loom, and slowly zooming in
//The camera movement will take 20 seconds, with 30 frames per second
GestaltCameraMove (0.0,
fFace + 0.0,20.0,50.0,
fFace + 360.0, 5.0,80.0,
20.0,60.0,oPC, 0, 0, 1);
// End cutscene
GestaltStopCutscene (30.0, oPC);
}
Modifié par WoC_Builder, 11 novembre 2012 - 05:27 .