Jump to content

Interruptible cutscenes?


Ieldra

Recommended Posts

I'm wondering if it is possible to make a cutscene interruptible. In particular, the cutscene I'm thinking of is structured like this:

 

There is a introductory sequence, followed by a sequence of actions that can be repeated N times. The maximum number of iterations is set in advance, but the result is so long that most players will want to watch the whole thing only once even if they play the mod more often (never mind the reason, it would be a spoiler - but think of the annoying early cutscenes of Region of Terror). Then, at the end, there is another sequence of actions ending in a dialogue.

 

I've been thinking of some code like the following:

IF 
Global("IxCutscenePart","GLOBAL",0)
THEN
RESPONSE #100
SetGlobal("IxSequenceCounter","GLOBAL",50)
SetGlobal("IxCutscenePart","GLOBAL",1)	
StartCutSceneMode()
StartCutScene("ixIntro")
Continue()
END

IF 
!Global("IxSequenceCounter","GLOBAL",0)
!HotKey(32)
THEN	
RESPONSE #100
StartCutSceneMode()
StartCutScene("ixLoop1")
IncrementGlobal("IxSequenceCounter","GLOBAL",-1)
END

IF
Global("IxCutscenePart","GLOBAL",1)
THEN
RESPONSE #100
SetGlobal("IxSequenceCounter","GLOBAL",0)
SetGlobal("IxCutscenePart","GLOBAL",2)
StartCutSceneMode()
StartCutScene("ixEndSeq")
END

...only there are some problems with it:

 

First, if I repeat my loop once a script round, or once N script rounds, to ensure that it plays seamlessly it must be exactly as long as a script round (or N script rounds). That would be hard to do if a script round is of variable length...is it?

 

Second, I don't want the interface enabled between iterations - in fact, I don't want anything to happen between iterations, I only want to check a HotKey.

 

I guess what I'm looking for is a way to do this within a Continue() sequence, so that I can control the time when the script does its checking down to a tenth of a second instead of only down to the length of a script round, ensuring that there is no pause between iterations. But then, a Continue() sequence counts as one script round with regard to the HotKey() trigger, does it not? Which means every HotKey() check made during the sequence will not respond to keys pressed after the script round has started. Right?

 

I would appreciate any insights, corrections of false assumptions and alternative solutions!

Link to comment
There is a semi-cutscene mode, which seems safer than a real cutscene.

I think Max used it frequently in DLTC.

CutsceneLite is the keyword, IIRC.

I've looked it up. Very useful, thanks. Only one question remains: which kind of script reacts to the HotKey() trigger if no object is selected?

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...