RPG cutscene

From Platinum Arts Sandbox Free 3D Game Maker
Jump to: navigation, search

This doucmentation is outdated and does not apply to the current version of sandbox!!!


Intro

Cutscenes are defined much like everything else, and generally also during the configuration phase. Cutscenes consist of multiple directives which may or may not be nested. All the directives can create additional ones. Note that the cutscenes only allow control of the camera, entities and creates are to be moved via script. See the scripting page.

The following command is used to create a new one...
r_new_cutscene ACTIONS POST
the POST argument is generally used to set variables (ie, don't play this cutscene again), and prepare the map should the player choose to skip it.

an example of a simple cutscene is as follows

 r_new_cutscene [
   r_cutscene_viewspin 180 0 0 5000
 ] [
   echo "cutscene done playing"
 ]

To start a cutscene, you must invoke: r_start_cutscene INDEX; To start the above, you'd use

 r_start_cutscene 0

General Directives

Action/Delay

Introduce a delay in a cutscene before performing an action:

 r_cutscene_delay DELAY ACTION

  • DELAY: delay in milliseconds before to perform action
  • ACTION: action block

Many cutscenes command have DELAY and ACTION as their two last parameters, which allows to chain to the next action after the delay has expired.

Cond

Iterate/Loop

Signal

Subtitle

Displays a subtitle with the given color.

 r_cutscene_subtitle TEXT R G B DELAY ACTION

  • TEXT: text to display
  • R, G, B: red, green and blue values for the text color
  • DELAY: delay during which the text remains displayed
  • ACTION: action to perform after the delay

Camera movement

Move camera

Move the camera to the position of a given camera tag:

 r_cutscene_movecamera TAG DELAY ACTION

or

 r_cutscene_moveaccelcamera TAG DELAY ACTION

  • TAG: camera tag
  • DELAY: delay during which the camera will move to the target (use 0 for immediate)
  • ACTION: action to perform after the delay

The first command will move the camera in a linear way to reach the target camera tag. The second one will do the same in an accelerated way.

Move camera to a specific position

Move the camera to a specific position:

 r_cutscene_movespecific X Y Z DELAY ACTION

or

 r_cutscene_moveaccelspecific X Y Z DELAY ACTION

  • X, Y, Z: absolute coordinates to where the camera must move
  • DELAY: delay during which the camera will move to the target (use 0 for immediate)
  • ACTION: action to perform after the delay

The first command will move the camera in a linear way to reach the given position. The second will do the same in an accelerated way.

Change Camera View Angle

Change the camera's view angle to match a camera tag's view angle.

 r_cutscene_viewcamera TAG DELAY ACTION

or

 r_cutscene_viewaccelcamera TAG DELAY ACTION

  • TAG: camera tag from which to use the view angle
  • DELAY: delay during which the camera's angle will be modified
  • ACTION: action to perform after the delay

The first command will change the camera's view angle in a linear way to reach the target angle. The second command will do the same in an accelerated way.

Change Camera View Angle using specific values

Change the camera's view angle to match the given angle values.

 r_cutscene_viewspecific YAW PITCH ROLL DELAY ACTION

or

 r_cutscene_viewaccelspecific YAW PITCH ROLL DELAY ACTION

  • YAW, PITCH, ROLL: target angle
  • DELAY: delay during which the camera's angle will be modified
  • ACTION: action to perform after the delay

The first command will change the camera's view angle in a linear way to reach the target angle. The second command will do the same in an accelerated way.

Viewspin

Spins the current view using the given relative angle movements.

  r_cutscene_viewspin YAW PITCH ROLL DELAY ACTION

  • YAW, PITCH, ROLL: relative angle direction in which to spin the current view's angle
  • DELAY: duration of the movement
  • ACTION: action to perform after the delay

Other directives

Sound

Soundfile

Overlay

Solid

Viewport

Focus