Page 1 of 1

0.52.0 : Cutscenes

Posted: Sat Feb 14, 2009 10:33 am
by Mit
Hia,
Just thought i'd do a little post with an inital description of the new 'Cutscenes' feature that will be added in the next client.

You can trigger a cutscene from you ServerGameScript.mts. The cutscene is defined in a file on the server that the client will download. Cutscenes allow you to control the camera and player, add models and graphics, add UI text and (in time) do things like play music and control effects.

e.g. You might have a cutscene triggered when a new player joins, that might pan the camera around to show them their environment, while displaying text introducing the player to the world.

Or you might have a building (or item) that when accessed triggers a cutscene giving the user a storyline or clues that would lead to other gameplay on your world.

The reason you're getting this feature is mostly coz i was having a bit of fun experimenting with scripting stuff (and fixing up the game's camera code), hence the cutscene is defined using a new custom object orientated language, an example of which below..

Code: Select all

section(1)
{
	playerpos = Vector();
	playerpos.SetToLocalPlayerPosition();

	modelpos = playerpos;
	modelpos.Add( (1,0,0) );

	campos = playerpos
	campos.Add( (0,2,1) );

	camposEnd = campos;
	camposEnd.Add( (1,1.5,0.9) );

	AmbientLight( #808088 );
	DirectionalLight( (0.2,0.4,-0.7), (0.8,0.75,0.6) );
	Model( "Data/Models/Bldgs/StdHouse02.atm", "Data/Models/Bldgs/StdHouse02.bmp", modelpos, (0.0,0.0,0.8) );

	cam = Camera( campos, modelpos );
	cam.BlendTo( 10.0, camposEnd, playerpos);

	caption = Caption( 0.5, 0.65, "This is an example of a cutscene", 1 );	
	caption.FadeIn( 1, 2 );
	caption.FadeOut( 5, 6 );
}
Those of you into a bit of armchair coding will probably be able to work out what that does (Adds a house model near to the player, sets lighting, sets a camera that pans across the scene, and adds a caption that fades in then fades out).
You might also ask why its not done using the existing scripting language.. but i was just having fun experimenting, you see :)

Anyway, its hopefully the sorta thing that can perhaps make the worlds a little more 'rich', and no doubt lead to a few interesting feature requests..

Posted: Sat Feb 14, 2009 12:45 pm
by zaroba
nice :)


now i just have to figure it out :P

hmm...i could see this being used nicely on a world where buildings are built immediately.
build the building, the cutscene is triggered and the camera pans out, you see the building rise from the ground.

Posted: Sat Feb 14, 2009 1:03 pm
by Mishka
Thanks Mit. :wink:

Posted: Mon Feb 16, 2009 1:16 am
by morbydvisns
is the galaxy prepared for....... planet Cutsceneworld?!?!?!

Posted: Mon Feb 16, 2009 6:11 pm
by flametard
Wow once again, this changes everything!!

Posted: Mon Feb 16, 2009 8:24 pm
by Mishka
morbydvisns wrote:is the galaxy prepared for....... planet Cutsceneworld?!?!?!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!


P.S. Mit, why is Zion offline?

Posted: Mon Feb 16, 2009 11:28 pm
by Mit
>> P.S. Mit, why is Zion offline?

because the new server box its on (which is lovely and quiet and environmentally friendly) does seem to enjoy resetting itself occasionally (usually with the excuse of a software update). A slight pain in the arse that i need to resolve, but itll be back shortly..

Posted: Tue Feb 17, 2009 3:56 am
by zaroba
lol. disable automatic update :P