Subversion-Projekte sthq.gbs

Revision

Revision 890 | Details | Vergleich mit vorheriger | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
885 lars 1
//--------------------------------------------------------------------------------------
2
//
3
//  EF2 Level Script File
4
//
5
//  Level:		Map5
6
//  Script By:	Nemo22, Cortex, LTiefland, TickNSwisted
7
//  Geometry By:	Nemo22, TickNSwisted, Argyle
8
//  Created on:	07.02.2004
9
//
10
// Last Edited on:  $Date: 2007-10-03 14:57:12 +0200 (Mi, 03 Okt 2007) $
902 lars 11
// Last Edited by:	Chrissstrahl
885 lars 12
//
13
//--------------------------------------------------------------------------------------
14
 
15
#include "maps/global_scripts/global_common.scr"
16
#include "maps/global_scripts/global_math.scr"
17
#include "maps/global_scripts/global_acceleratedMovement.scr"
18
#include "maps/global_scripts/global_cinematicFX.scr"
19
#include "maps/global_scripts/global_archetype.scr"
20
#include "maps/attackplayer.scr"
21
 
22
void main();
23
void initArchetypes();
24
void init();
25
void first_shot();
26
void finish_introcin();
27
void bay_sec_beamin();
28
void sec_shoot();
29
void shuttle_open();
30
void finish_awaycin();
31
void shuttle_away();
32
void shuttle_inside_sparks();
33
void sparks();
34
void redalert();
35
void closed_door_sound();
36
 
37
void shuttlesparks();
38
void bill_ex();
39
 
40
void main()
41
{
42
	initArchetypes();
43
	cam_fadeout( .1, 0, 0, 0, 1, 0 );
44
	$player.notsolid();
45
	$player.hide();
46
	letterbox( .1 );
47
	allowMusicDucking( 0 );
48
	freezeplayer();
49
	cinematic();
50
 
51
	$world.canShakeCamera( 1 );
52
 
53
	init();
54
 
55
	thread first_shot();
56
	soundtrack( "music/m8l2a.mus");
57
}
58
 
59
 
60
void initArchetypes()
61
{
62
 
63
      thread globalArchetype_Setup( $console_hint1, "mdoor");
64
      thread globalArchetype_Setup( $console_hint2, "sdoor");
65
 
66
}
67
 
68
void init()
69
{
70
 
71
   	//$shuttle_stay.solid();
72
   	$ramp_blocker.notsolid();
73
 
890 avenger 74
	if(doesEntityExist($npcs_off)){
75
		$npcs_off.notsolid();
76
		$npcs_off.hide();
77
		$npcs_off.ai_off();
78
	}
885 lars 79
 
80
	$world.light_fade( "light_red", 0, 1 );
81
 
82
	$player.give( "models/weapons/worldmodel-tricorder-STX.tik" );
83
 
84
	$atlantic_out_origin.loopsound( "sound/ships/enterprise/ent_exterior_01.wav", 1 ,1024 );
85
 
86
//--Das Shuttle, das wegfliegt:
87
	$shuttle_fly_away_door.bind( $shuttle_origin );
88
	$shuttle_fly_away_ext.bind( $shuttle_origin );
89
	$shuttle_fly_away_door.hide();
90
	$shuttle_fly_away_ext.hide();
91
 
92
//--Kameras laden und spawnen
93
/*	cam.load( "map5_p_illia1" );
94
	cam.load( "map5_shuttle_cam1" );
95
	cam.load( "map5_shuttle_cam1d" );
96
	cam.load( "map5_shuttle_cam2" );
97
	cam.load( "map5_shuttle_cam3" );
98
	cam.load( "map5_shuttle_cam4" );
99
	cam.load( "map5_shuttle_path" );
100
	cam.load( "map5_cam_shuttle" );
101
	cam.load( "map5_jim_beamin" );
102
	cam.load( "map5_atlantic_last_shot" );*/
103
 
104
	spawn( "Camera", "targetname", "cam1");
105
	spawn( "Camera", "targetname", "cam2");
106
	spawn( "Camera", "targetname", "cam3");
107
 
108
//--Illia SetUp
109
//	$illia_shuttle.pushable( 1 );
110
	globalCommon_AiActorUseWeapon( $illia_shuttle, "none" );
111
	$illia_shuttle.ai_off();
112
	$illia_shuttle.pushable( 0 );
113
	$illia_shuttle.hide();
114
	$illia_shuttle.notsolid();
115
 
116
	globalCommon_AiActorUseWeapon( $ceilling_illia, "none" );
117
	$ceilling_illia.ai_off();
118
	$ceilling_illia.pushable( 0 );
119
	$ceilling_illia.hide();
120
	$ceilling_illia.notsolid();
121
 
122
	globalCommon_AiActorUseWeapon( $illia_shuttle_inside, "none" );
123
	$illia_shuttle_inside.ai_off();
124
	$illia_shuttle_inside.anim( "ent-frontchair-gesture1" );
125
	$illia_shuttle_inside.pushable( 0 );
126
 
127
//--Illia_prisoner SetUp
128
	$illia_prisoner.pushable( 0 );
129
	$illia_prisoner.notsolid();
130
	$illia_prisoner.ai_off();
131
	globalCommon_AiActorUseWeapon( $illia_prisoner, "none" );
132
	globalCommon_AiDummy( $illia_prisoner, "" );
133
	$illia_prisoner.anim("cin-m8_situp");
134
 
135
//--people in Engineering
136
	$jones0.ai_off();
137
	globalCommon_AiActorUseWeapon( $jones0, "none" );
138
	$shaun0.ai_off();
139
	globalCommon_AiActorUseWeapon( $shaun0, "none" );
140
	$bails0.ai_off();
141
	$bails0.pushable( 0 );
142
	globalCommon_AiActorUseWeapon( $bails0, "none" );
143
 
144
	$jones0.anim( "ent-curvedconsole-gesture" );
145
	$shaun0.anim( "ent-compstation-idle" );
146
	$bails0.anim( "ent-compstation-gesture1" );
147
 
148
//--Moya
149
	$moya.ai_off();
150
 
151
//--Security team setup
152
	$sec_1.ai_off();
153
	$sec_1.pushable( 0 );
154
/*	$sec_1.notsolid();
155
	$sec_1.hide();*/
156
	$sec_1.setgroupid ( 668 );
157
 
158
	//$sec_1.giveactorweapon( "actorweapons/fed-compressionrifle.tik", 1.0 );
159
	//$sec_1.useactorweapon( "CompressionRifle" );
160
//	$sec_1.anim( "idle_weapon_legs" );
161
	$sec_1.anim( "compressionrifle_aim" );
162
 
163
	$sec_2.ai_off();
164
	$sec_2.pushable( 0 );
165
/*	$sec_2.notsolid();
166
	$sec_2.hide();*/
167
	//$sec_2.giveactorweapon( "actorweapons/fed-compressionrifle.tik", 1.0 );
168
	//$sec_2.useactorweapon( "CompressionRifle" );
169
	$sec_2.setgroupid ( 668 );
170
 
171
	$sec_3.ai_off();
172
	$sec_3.pushable( 0 );
173
/*	$sec_3.notsolid();
174
	$sec_3.hide();*/
175
	//$sec_3.giveactorweapon( "actorweapons/fed-compressionrifle.tik", 1.0 );
176
	//$sec_3.useactorweapon( "CompressionRifle" );
177
	$sec_3.anim( "crouch_idle" );
178
	$sec_3.setgroupid ( 668 );
179
 
180
	AIHideGroup(668);
181
 
182
//--misc
183
	$illia_shuttle.blink( 0 );
184
 
185
	$kraftfeld.hide();
186
 
187
	$security.nottriggerable();
188
	$trigger_open.nottriggerable();
189
	$away_trigger.nottriggerable();
190
 
191
	globalCommon_SpawnScriptModel( "vehicle/e-shuttle-ext.tik", "dallas_shuttle1", '-2200 596 60', 0 );
192
	$dallas_shuttle1.scale( .01 );
193
 
194
	globalCommon_SpawnScriptModel( "vehicle/e-shuttle-door.tik", "dallas_shuttle2", '-2200 596 60', 0 );
195
	$dallas_shuttle2.scale( .01 );
196
 
197
	$dallas_shuttle1.bind( $dallas_origin );
198
	$dallas_shuttle2.bind( $dallas_origin );
199
 
200
	$atlantic_a.bind( $atlantic_out_origin );
201
	$atlantic_b.bind( $atlantic_out_origin );
202
 
203
	$shuttle_warp.hide();
204
 
205
	wait( .1 );
206
	$sec_2.anim( "idle_weapon_legs" );
207
 
208
//--Maschinenraumtür
209
	$engdoor3.time( .1 );
210
	wait( .1 );
211
	$engdoor3.moveUp( 170 );
212
 
213
	$movewall.bind( $bay_move_origin );
214
}
215
 
216
///////////////////////////////////////////////////////////////////////////////
217
/////////////////////////////////////Intro/////////////////////////////////////
218
///////////////////////////////////////////////////////////////////////////////
219
 
220
 
221
void first_shot()
222
{
223
//--Camera fades in, Illia beams in, walks to console
224
	skipthread ( "finish_introcin" );
225
	$cam1.fov( 60 );
226
	$cam1.follow( $map5_shuttle_cam1d );
227
	$cam1.cut();
228
	wait( .1 );
229
	cuecamera( $cam1 );
230
	wait( .5 );
231
	cam_fadein( 3, 0, 0, 0, 1, 0 );
232
 
233
	wait( 1 );
234
	$illia_shuttle.show();
235
	$illia_shuttle.displayEffect( "TransportIn", "FederationNoAnim" );
236
	wait( 3 );
237
	$illia_shuttle.blink( 1 );
238
	wait( 1 );
239
	$illia_shuttle.headWatchTarget( "illia_look_first", 7 );
240
	wait( 1 );
241
	$illia_shuttle.headWatchTarget( "illia_look_second", 7 );
242
	$cam2.fov( 60 );
243
	$cam2.follow( $map5_shuttle_cam1 );
244
	$cam2.cut();
245
	wait( .1 );
246
	cuecamera( $cam2 );
247
 
248
	wait( 2 );
249
	$illia_shuttle.walkto( "$walk1", "walk" );
250
	wait( .5 );
251
	$illia_shuttle.headWatchTarget( "none", 7 );
252
	waitfor( $illia_shuttle );
253
	$illia_shuttle.walkto( "$walk2", "walk" );
254
	waitfor( $illia_shuttle );
255
	$illia_shuttle.turntoangle( 225 );
256
	waitfor( $illia_shuttle );
257
	$illia_shuttle.anim( "ent-curvedconsole-gesture" );
258
	wait( 2 );
259
	$illia_shuttle.anim( "idle" );
260
	wait( 1 );
261
	$illia_shuttle.playdialog("localization/sound/dialog/map05/illia/damn.mp3", 1, 10000, 0);
262
	waitfordialog( $illia_shuttle );
263
	cam_fadeout( 1.5, 0, 0, 0, 1, 0 );
264
	wait( 2 );
265
 
266
//--Camera cuts to imprisoned Illia
267
	$cam3.fov( 60 );
268
	$cam3.follow( $map5_p_illia1 );
269
	$cam3.cut();
270
	wait( .1 );
271
	cuecamera( $cam3 );
272
	cam_fadein( 1.5, 0, 0, 0, 1, 0 );
273
 
274
	wait( 2 );
275
	$illia_prisoner.playdialog("localization/sound/dialog/map05/illia/ihadto.mp3", 1, 10000, 0);
276
	waitfordialog( $illia_prisoner );
277
	wait( .5 );
278
	$illia_prisoner.playdialog("localization/sound/dialog/map05/illia/maincontrol.mp3", 1, 10000, 0);
279
	waitfordialog( $illia_prisoner );
280
//	wait( 1 );
281
	cam_fadeout( 1.5, 0, 0, 0, 1, 0 );
282
	wait( 2 );
283
	cam_fadein( 1.5, 0, 0, 0, 1, 0 );
284
 
285
//--camera is in shuttle, Illia exits
286
	$cam2.fov( 60 );
287
	$cam2.follow( $map5_shuttle_cam2 );
288
	$cam2.cut();
289
	wait( .1 );
290
	cuecamera( $cam2 );
291
 
292
	$illia_shuttle.walkto( "$walk1", "walk" );
293
	waitfor( $illia_shuttle );
294
	$illia_shuttle.walkto( "$w1", "walk" );
295
	wait( 1 );
296
	///////////////////
297
	//1. Tür geht auf//
298
	///////////////////
299
	$shuttle_stay_door1.anim( "opening" );
300
	$shuttle_stay_door1.playsound( "sound/doors/enterprise_door1.wav", 1 ,800 );
301
	waitforanimation( $shuttle_stay_door1, "opening" );
302
	$shuttle_stay_door1.anim( "open_idle" );
303
 
304
//	$shuttle_stay_door1.time( 1 );
305
//	$shuttle_stay_door1.moveWest( 38 );
306
//	$shuttle_stay_door1.moveNorth( 38 );
307
 
308
	waitfor( $illia_shuttle );
309
	$illia_shuttle.walkto( "$w2", "walk" );
310
	waitfor( $illia_shuttle );
311
	$illia_shuttle.walkto( "$w3", "walk" );
312
	//////////////////
313
	//1. Tür geht zu//
314
	//////////////////
315
	//$shuttle_stay_door1.anim( "closing" );
316
	//$shuttle_stay_door1.playsound( "sound/doors/enterprise_door1.wav", 1 ,800 );
317
	//waitforanimation( $shuttle_stay_door1, "closing" );
318
	//$shuttle_stay_door1.anim( "closed" );
319
 
320
//	$shuttle_stay_door1.time( 1 );
321
//	$shuttle_stay_door1.moveEast( 38 );
322
//	$shuttle_stay_door1.moveSouth( 38 );
323
	waitfor( $illia_shuttle );
324
	///////////////////
325
	//2. door opens //
326
	///////////////////
327
	$shuttle_stay_door2.anim( "opening" );
328
	$shuttle_stay_door2.playsound( "sound/doors/enterprise_door1.wav", 1 ,800 );	waitforanimation( $shuttle_stay_door2, "opening" );
329
	$shuttle_stay_door2.anim( "open_idle" );
330
 
331
//	$shuttle_stay_door2.time( 1 );
332
//	$shuttle_stay_door2.moveWest( 44 );
333
//	$shuttle_stay_door2.moveNorth( 44 );
334
 
335
	$illia_shuttle.walkto( "$w4", "walk" );
336
 
337
	$cam3.fov( 60 );
338
	$cam3.follow( $map5_shuttle_cam4 );
339
	$cam3.cut();
340
	wait( .1 );
341
	cuecamera( $cam3 );
342
 
343
	waitfor( $illia_shuttle );
344
	//////////////////
345
	//2. Tür geht zu//
346
	//////////////////
347
	//$shuttle_stay_door2.anim( "closing" );
348
	//$shuttle_stay_door2.playsound( "sound/doors/enterprise_door1.wav", 1 ,800 );
349
	//waitforanimation( $shuttle_stay_door2, "closing" );
350
	//$shuttle_stay_door2.anim( "closed" );
351
 
352
//	$shuttle_stay_door2.time( 1 );
353
//	$shuttle_stay_door2.moveEast( 44 );
354
//	$shuttle_stay_door2.moveSouth( 44 );
355
 
902 lars 356
	$illia_shuttle.walkto("$w5");
357
	wait(7);
885 lars 358
 
359
	thread finish_introcin();
360
}
361
 
362
 
363
void finish_introcin()
364
{
902 lars 365
vector vPlayerWarp;
885 lars 366
 
902 lars 367
	killthread("first_shot");
368
 
885 lars 369
	$illia_shuttle.warpto( "$w5" );
902 lars 370
	$illia_shuttle.hide();
371
	$illia_shuttle.notsolid();
372
 
373
	vPlayerWarp = $illia_shuttle.getOrigin();
374
	$player.origin(vPlayerWarp);
375
	$player.dropToFloor(999);//Patched 07.sep.2007 @ Chrissstrahl
376
	$player.solid();
377
	$player.show();
378
	removeclass("vehicle");//Patched 07.sep.2007 @ Chrissstrahl
379
 
380
	$ramp_blocker.solid();
381
 
885 lars 382
//--Cinematic beenden
383
	clearletterbox( 0.1 );
384
	noncinematic();
902 lars 385
	cueplayer();
386
	wait(.1);
885 lars 387
	releaseplayer();
902 lars 388
 
389
 
885 lars 390
	//sec_shoot();
391
 
392
}
393
////////////////////////////////////////////////////////////////////////////
394
///////////After the player has maniplulated the main console///////////////
395
/////player has to jump of the railing /////////////////////////////////////
396
////////////////////////////////////////////////////////////////////////////
397
 
398
void bay_sec_beamin()
399
{
400
	skipthread ( "finish_beamincin" );
401
	$player.notsolid();
402
	$player.hide();
403
	letterbox( .1 );
404
	freezeplayer();
405
	cinematic();
406
	$ceilling_illia.turntoangle( 180 );
407
 
408
	$ceilling_illia.show();
409
	$cam1.fov( 60 );
410
	$cam1.follow( $map5_shuttle_door_close );
411
	$cam1.cut();
412
	wait( .1 );
413
	cuecamera( $cam1 );
414
 
415
	wait( 1 );
416
	//--Shuttle sschließt die Türen
417
   	$ramp_blocker.solid();
418
	$shuttle_stay_door.anim( "closing" );
419
	waitforanimation( $shuttle_stay_door, "closing" );
420
	$shuttle_stay_door.anim( "closed" );
421
	wait( 1 );
422
	$kraftfeld.show();
423
	$kraftfeld.playsound( "sound/ships/borg/borg_forcefield_on.wav", 1, 1, 11111 );
424
	$kraftfeld.loopsound( "sound/ships/enterprise/ent_forcefield.wav", .7, 30 );
425
	triggerentity( $kraftfeld_sound );
426
	wait( .4 );
427
 
428
	$rechte_door.time( 5.2 );
429
	wait( .1 );
430
	$rechte_door.moveUp( 300 );
431
	$rechte_door.loopsound( "sound/doors/airlock_open01.wav", 1 ,1024 );
432
 
433
	wait( 5.2 );
434
	$rechte_door.stoploopsound();
435
	$rechte_door.playsound( "sound/doors/airlock_close01.wav", 10 ,1 ,1024 );
436
 
437
	wait( 3.8 );
438
 
439
/*	$sec_1.solid();
440
	$sec_2.solid();
441
	$sec_3.solid();
442
	wait(1);*/
443
 
444
 
445
	$cam2.fov( 60 );
446
	$cam2.follow( $map5_jim_beamin );
447
	$cam2.cut();
448
	wait( .1 );
449
	cuecamera( $cam2 );
450
 
451
	$ceilling_illia.playdialog("localization/sound/dialog/map05/illia/goodbye.mp3", 1, 10000, 0);
452
	waitfordialog( $ceilling_illia );
453
 
454
	wait( 2 );
455
/*	$sec_1.displayEffect( "TransportIn", "FederationNoAnim" );
456
	$sec_2.displayEffect( "TransportIn", "FederationNoAnim" );
457
	$sec_3.displayEffect( "TransportIn", "FederationNoAnim" );
458
	wait( 2 );*/
459
 
460
	AIShowGroup (668, "Federation");
461
	$sec_1.headWatchTarget("player",7);
462
	$sec_2.headWatchTarget("player",7);
463
	$sec_3.headWatchTarget("player",7);
464
	$sec_1.ai_off();
465
	$sec_2.ai_off();
466
	$sec_3.ai_off();
467
	$sec_1.anim( "compressionrifle_aim" );
468
	$sec_2.anim( "compressionrifle_aim" );
469
	$sec_3.anim( "compressionrifle_aim" );
470
 
471
	$sec_2.playdialog( "localization/sound/dialog/map05/lee/donotmove.mp3", 1, 10000, 0);
472
	waitfordialog( $sec_2 );
473
	$ceilling_illia.turntoangle( 270 );
474
	wait( .5 );
475
	$sec_2.playdialog( "localization/sound/dialog/map05/lee/gameover.mp3", 1, 10000, 0);
476
	waitfordialog( $sec_2 );
477
	wait( 1 );
478
	$ceilling_illia.hide();
479
 
480
	//--End cinematic
481
	forcemusic( "action" );
482
	clearletterbox( 0.1 );
483
	noncinematic();
484
	$player.solid();
485
	$player.show();
486
	releaseplayer();
487
	cueplayer();
488
	$player.playerviewangles( '0 270 0' );
902 lars 489
	$player.playerviewangles( '0 270 0' );
885 lars 490
 
491
//	$security_beam.nottriggerable();
492
	$security.triggerable();
493
}
494
 
495
void sec_shoot()
496
{
497
//	centerprint("Sicherheit fängt an zu schießen!");
498
 
499
	$sec_1.turntoangle( 180 );
500
	$sec_2.walkto( "$secnode1", "run" );
501
	$sec_3.walkto( "$secnode2", "run" );
502
	waitfor( $sec_3 );
503
	$sec_1.anim( "idle_weapon_legs" );
504
	$sec_2.turntoangle( 180 );
505
	$sec_3.walkto( "$secnode3", "run" );
506
	waitfor( $sec_3 );
507
	$sec_3.turntoangle( 180 );
508
	waitfor( $sec_3 );
509
	$sec_3.anim( "idle_weapon_legs" );
510
	wait( .7 );
511
	$sec_2.anim( "idle_weapon_legs" );
512
/*	$sec_1.attackplayer();
513
	$sec_2.attackplayer();
514
	$sec_3.attackplayer();*/
515
 
516
//	AIShowGroup(668, "Federation");
517
 
518
	CommandToGroup ( 668 , "groupactortype" , "enemy" , "");
519
	CommandToGroup ( 668 , "visiondistance" , "40000" , "" );
520
	CommandToGroup ( 668 , "fov" , "360" , "" );
521
	CommandToGroup ( 668 , "attack" , "$player" , "" );
522
 
523
	$sec_1.ai_on();
524
	$sec_2.ai_on();
525
	$sec_3.ai_on();
526
 
527
	$trigger_open.triggerable();
890 avenger 528
	if(doesEntityExist($security)){
529
		$security.nottriggerable();
530
	}
885 lars 531
}
532
 
533
void shuttle_open()
534
{
535
   	$ramp_blocker.notsolid();
536
	$shuttle_stay_door.anim( "opening" );
537
	waitforanimation( $shuttle_stay_door, "opening" );
538
	$shuttle_stay_door.anim( "open_idle" );
539
 
540
	$away_trigger.triggerable();
541
	$trigger_open.nottriggerable();
542
}
543
 
544
void shuttle_away()
545
{
546
//--Begin cinematic!
547
	skipthread ( "finish_awaycin" );
548
	$player.notsolid();
549
	$player.hide();
550
	letterbox( .1 );
551
	freezeplayer();
552
	cinematic();
553
 
554
	$illia_shuttle.show();
555
	$cam1.fov( 60 );
556
	$cam1.follow( $away_cam1, $illia_shuttle );
557
	$cam1.cut();
558
	wait( .1 );
559
	cuecamera( $cam1 );
560
 
561
	$illia_shuttle.walkto( "$w4", "run" );
562
	waitfor( $illia_shuttle );
563
 
564
	$shuttle_stay_door.anim( "closing" );
565
	waitforanimation( $shuttle_stay_door, "closing" );
566
	$shuttle_stay_door.anim( "closed" );
567
 
568
	$illia_shuttle.hide();
569
 
570
	$shuttle_stay_door2.hide();
571
	$shuttle_stay_door1.hide();
572
	$shuttle_stay_door.hide();
573
	$shuttle_stay.hide();
574
	$shuttle_fly_away_door.show();
575
	$shuttle_fly_away_ext.show();
576
 
577
	$cam2.fov( 60 );
578
	$cam2.follow( $door_open_cam1 );
579
	$cam2.cut();
580
	wait( .1 );
581
	cuecamera( $cam2 );
582
 
583
	$shuttle_origin.followpath($shuttle_path);
584
	wait( 4.5 );
585
	$shuttle_origin.playsound( "sound/vehicles/shuttlecraft/shuttle_takeoff.wav", 0, 4 );
586
	wait( 16 );
587
	$rechte_door.time( 5.2 );
588
	$rechte_door.moveDown( 300 );
589
	$rechte_door.loopsound( "sound/doors/airlock_open01.wav", 1 ,1024 );
590
	wait( 2);
591
 
592
	wait( 4 );
593
 
594
	$cam2.fov( 20 );
595
	$cam2.follow( $map5_cam_shuttle );
596
	$cam2.cut();
597
	wait( .1 );
598
	cuecamera( $cam2 );
599
	$sky_ship.hide();
600
 
601
	wait( 1.2 );
602
	$rechte_door.stoploopsound();
603
	$rechte_door.playsound( "sound/doors/airlock_close01.wav", 10 ,.5 ,1024 );
604
	wait( .3 );
605
	$dallas_origin.followpath( $map5_shuttle_path );
606
	//wait( 6.5 );
607
	wait( 4 );
608
 
609
	$atlantic_out_origin.followpath( $atlantic_out_path );
610
 
611
	$cam3.fov( 55 );
612
	$cam3.follow( $atlantic_out_cam1, $atlantic_out_origin );
613
	$cam3.cut();
614
	wait( .1 );
615
	cuecamera( $cam3 );
616
	$kraftfeld.hide();
617
 
618
	wait( 8 );
619
 
620
	$cam1.fov( 55 );
621
	$cam1.follow( $atlantic_out_cam2, $atlantic_out_origin );
622
	$cam1.cut();
623
	wait( .1 );
624
	cuecamera( $cam1 );
625
	wait( 17 );
626
	/////////////////////////
627
	//Moya in engineering//
628
	/////////////////////////
629
	$cam3.fov( 75 );
630
	$cam3.follow( $engine_cam1 );
631
	$cam3.cut();
632
	wait( .1 );
633
	cuecamera( $cam3 );
634
 
635
	wait( 1 );
636
	thread sparks();
637
	wait(.1);
638
        $world.playsound( "sound/explo_large_01.wav",3,1,10000);
639
	triggerentity( $big_boom_engineering );
640
	wait(.1);
641
 
642
	$player.earthquake( 2.2, 1 );
643
 
644
	triggerentity( $eng_explosion );
645
	wait( 2 );
646
	thread redalert();
647
	$engdoor3.time( 6 );
648
	wait( .1 );
649
	$engdoor3.moveDown( 170 );
650
	wait( 1 );
651
 
652
	$moya.anim( "tap_comm" );//communicator
653
	waitforanimation( $moya, "tap_comm" );
654
	$moya.anim( "idle" );
655
	wait(1);
656
	$moya.playdialog( "localization/sound/dialog/map05/moya/bridge.mp3", 1, 10000, 0);
657
	waitfordialog( $moya );
658
	$moya.playdialog( "localization/sound/dialog/map05/moya/warpcore.mp3", 1, 10000, 0);
659
	waitfordialog( $moya );
660
	wait( .4 );
661
	$moya.playdialog( "localization/sound/dialog/map05/moya/deadinspace.mp3", 1, 10000, 0);
662
	waitfordialog( $moya );
663
	wait( 2 );
664
	triggerentity( $big_boom_engineering );
665
	thread bill_ex();
666
	wait( 2.5 );
667
	killthread( "sparks" );
668
	$cam2.fov( 90 );
669
	$cam2.follow( $map5_atlantic_last_shot );
670
	$cam2.cut();
671
	wait( .1 );
672
	cuecamera( $cam2 );
673
	wait( 2 );
674
	cam_fadeout( 10, 0, 0, 0, 1, 0 );
675
	wait( 4 );
676
//	stuffcmd( "showmenu continued\n" );
677
//	wait( 4 );
678
//	stuffcmd ( "popmenu 0\n" );
679
 
680
	wait( 4 );
681
	finish_awaycin();
682
}
683
 
684
void finish_awaycin()
685
{
686
//--end cinematic
687
	killthread("shuttle_away");
688
	clearletterbox( 0.1 );
689
	noncinematic();
690
	$player.solid();
691
	$player.show();
692
	releaseplayer();
693
	cueplayer();
694
 
695
	stuffcmd ("map map6");
696
 
697
	cam_fadein( 1.5, 0, 0, 0, 1, 0 );
698
}
699
 
700
//////////////////////////
701
//Explosions and sparks//
702
//////////////////////////
703
void shuttle_inside_sparks()
704
{
705
	$movewall.time( 15 );
706
	$sky_ship.time( 2.9 );
707
	wait( .1 );
708
	$movewall.moveEast( 1600 );
709
	$sky_ship.moveEast( 3 );
710
	$cam1.fov( 90 );
711
	$cam1.follow( $shuttle_inside_cam1 );
712
	$cam1.cut();
713
	wait( .1 );
714
	cuecamera( $cam1 );
715
	$player.earthquake( 1.2, 1 );
716
	triggerentity( $shuttle_inside_spark1 );
717
	triggerentity( $shuttle_inside_spark1_s );
718
	wait( .3 );
719
	triggerentity( $shuttle_inside_spark3 );
720
	triggerentity( $shuttle_inside_spark3_s );
721
	wait( .2 );
722
	triggerentity( $shuttle_inside_spark2 );
723
	triggerentity( $shuttle_inside_spark2_s );
724
	wait( .3 );
725
	triggerentity( $shuttle_inside_spark1 );
726
	triggerentity( $shuttle_inside_spark1_s );
727
	triggerentity( $shuttle_inside_spark3 );
728
	$sky_ship.time( .1 );
729
	wait( 2 );
730
	$sky_ship.moveWest( 3 );
731
	cuecamera( $cam2 );
732
 
733
}
734
 
735
void sparks()
736
{
737
	triggerentity( $sparks1 );
738
	$sparks1.playsound( "sound/impact/explosion/explo_shuttleint.wav" );
739
	wait( 1.1 );
740
	triggerentity( $sparks3 );
741
	$sparks3.playsound( "sound/impact/explosion/explo_shuttleint.wav" );
742
	wait( 2 );
743
	triggerentity( $sparks2 );
744
	$sparks2.playsound( "sound/impact/explosion/explo_shuttleint.wav" );
745
	wait( 1 );
746
	triggerentity( $sparks1 );
747
	$sparks1.playsound( "sound/impact/explosion/explo_shuttleint.wav" );
748
	triggerentity( $sparks3 );
749
	$sparks3.playsound( "sound/impact/explosion/explo_shuttleint.wav" );
750
	wait( 2 );
751
	thread sparks();
752
}
753
 
754
void redalert()
755
{
756
	$world.light_fade( "light_red", .65, .4 );
757
	triggerentity( $redalert_sound );
758
	wait( 1.5 );
759
	$world.light_fade( "light_red", .1, .8 );
760
	wait( 1 );
761
	thread redalert();
762
}
763
 
764
void shuttlesparks()
765
{
766
	$player.earthquake( .8, 2 );
767
	triggerentity( $shuttle_sparks );
768
	triggerentity( $fly_away_sparks_s );
769
	wait( .4 );
770
	triggerentity( $shuttle_sparks );
771
	triggerentity( $fly_away_sparks_s );
772
	wait( .4 );
773
	triggerentity( $shuttle_sparks );
774
	triggerentity( $fly_away_sparks_s );
775
	wait( .6 );
776
	triggerentity( $shuttle_sparks );
777
	triggerentity( $fly_away_sparks_s );
778
	wait( .1 );
779
	thread shuttle_inside_sparks();
780
}
781
 
782
void shuttle_goto_warp()
783
{
784
	$shuttle_warp.show();
785
	$shuttle_warp.followpath( $path_gowarp );
786
	wait( 2.6 );
787
	$shuttle_warp.playsound( "sound/ships/enterprise/ent_enter_warp.wav", 10 ,1 ,1024 );
788
	wait( 3.7 );
789
 
790
	$spawnWarpFlash.scale( .2 );
791
	$spawnWarpFlash.modelname( "models/fx/fx-warpflash-federation.tik" );
792
	$spawnWarpFlash.origin( $shuttle_warp.getOrigin() );
793
	wait( .05 );
794
 
795
	triggerEntity( $spawnWarpFlash );
796
	$shuttle_warp.hide();
797
}
798
 
799
void bill_ex()
800
{
801
	$bails0.turntoangle( 135 );
802
	wait( .1 );
803
	$bails0.anim( "cin-m6l0-engineering-bill" );
804
}
805
 
806
void closed_door_sound()
807
{
808
	$player.playsound( "sound/environment/computer/lcars_no.wav");
809
}