Aller au contenu

Photo

Triggering a cutscene


  • Veuillez vous connecter pour répondre
4 réponses à ce sujet

#1
SupercellTornado

SupercellTornado
  • Members
  • 15 messages
How do I trigger a cutscene after the player walks over an a certain spot?

#2
FergusM

FergusM
  • Members
  • 460 messages
Basically you have to create a 'trigger' resource (green diamond in the palette) and a script resource that it uses. There should be an example script you can get on the wiki by searching the forums. Basically the idea is that you make the trigger, change its script to the one you made in the trigger editor, then place the trigger in your area.



The script should be something like



#include "wrappers_h"



void main()

{

event ev = GetCurrentEvent();

int type = GetEventType(ev);

object creator = GetEventCreator(ev);

switch (type)

{

case EVENT_TYPE_ENTER:

{

if (isPartyMember(creator)

{

CS_LoadCutscene(R"YOURCUTSCENE.cut");

DestroyObject(OBJECT_SELF);

}

break;

}

}

HandleEvent(ev,RESOURCE_SCRIPT_TRIGGER_CORE);

}



But I'm writing this on a netbook so I may have messed something up. :) You'll notice in there the trigger also destroys itself so it only fires once.

#3
SupercellTornado

SupercellTornado
  • Members
  • 15 messages
Thanks.

#4
aidanodr

aidanodr
  • Members
  • 42 messages
Hey ST,

If you look in the recent thread I started about MACHINIMA called "Where to start ... Machinima with Dragons Age!":

social.bioware.com/forum/1/topic/76/index/4547885 

You should find a comprehensive answer for your very question further down.

Aidan

Modifié par aidanodr, 26 août 2010 - 04:15 .


#5
BloodsongVengeance

BloodsongVengeance
  • Members
  • 590 messages
ive organized pertinent cutscene scripts into one post here:

http://social.biowar...58/#post_817758



(just to one-up aidan ;) nah, just kidding!)



but check out aidan's thread for good startup advice!