0.52.0 : Cutscenes

Forum Archive - from http://theuniversal.net
Locked
User avatar
Mit
Staff
Staff
Posts: 3551
Joined: Sun Sep 21, 2003 10:14 pm
Location: Unknown

0.52.0 : Cutscenes

Post 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..
User avatar
zaroba
World Owner
World Owner
Posts: 7257
Joined: Fri Oct 10, 2003 11:06 pm
Location: Hereford, PA
Contact:

Post 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.
User avatar
Mishka
Posts: 1894
Joined: Fri Dec 29, 2006 6:19 pm
Location: Treasure Planet. Pirate Headquarters.

Post by Mishka »

Thanks Mit. :wink:
User avatar
morbydvisns
Posts: 1889
Joined: Sun Jan 30, 2005 12:51 am

Post by morbydvisns »

is the galaxy prepared for....... planet Cutsceneworld?!?!?!
User avatar
flametard
Posts: 1245
Joined: Sun Apr 01, 2007 2:05 am
Location: Join NR! faction name: 'NR new recruits' password: 'Truth'
Contact:

Post by flametard »

Wow once again, this changes everything!!
User avatar
Mishka
Posts: 1894
Joined: Fri Dec 29, 2006 6:19 pm
Location: Treasure Planet. Pirate Headquarters.

Post by Mishka »

morbydvisns wrote:is the galaxy prepared for....... planet Cutsceneworld?!?!?!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!


P.S. Mit, why is Zion offline?
User avatar
Mit
Staff
Staff
Posts: 3551
Joined: Sun Sep 21, 2003 10:14 pm
Location: Unknown

Post 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..
User avatar
zaroba
World Owner
World Owner
Posts: 7257
Joined: Fri Oct 10, 2003 11:06 pm
Location: Hereford, PA
Contact:

Post by zaroba »

lol. disable automatic update :P
Locked