OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: Aldo15 on 23 Mar 2011, 22:39:30

Title: How I make my own custom scene, when the player is dead?
Post by: Aldo15 on 23 Mar 2011, 22:39:30
I want to make a scene, when me or the player die, but I don't know how to make it. Could you give me a tutorial abuot that?

Cheers,
Aldo15
Title: Re: How I make my own custom scene, when the player is dead?
Post by: OFP_f3d3 on 23 Mar 2011, 22:52:31
I think that you have to create it as you create an intro, using camera.sqs

As soon as you write "exit" at the end of the end-camera script the death camera will be shown as always but remember to put:
Code: [Select]
NOT (alive ap)in the condition field

or

Code: [Select]
getdammage ap > 0.9
that means that if the player receives more than 0.9 damage, the camera will be shown.

I hpe it helps ;)

ofp_f3d3
Title: Re: How I make my own custom scene, when the player is dead?
Post by: Aldo15 on 23 Mar 2011, 23:08:23
Don't work!  :(

I've put that, but the camera isn't  shown, just it shown the default camera.

EDIT : I've found the script, I think is called "Onplayerkilled.sqs" now I can  put custom scenes, when the player is dead.  :D

Regards,
Aldo15

Title: Re: How I make my own custom scene, when the player is dead?
Post by: Lenyoga on 24 Mar 2011, 00:08:26
I think putting a script called 'OnPlayerKilled.sqs' in the mission folder works. Algo script tiene que estar un camera-script como un intro o un outro. Non lo so que it really works or not. (Still have to improve my Spanish)
Title: Re: How I make my own custom scene, when the player is dead?
Post by: Aldo15 on 24 Mar 2011, 01:04:50
Hi, lenyoga, thanks you for your help...

Well, I've opened the "scripts.sqs" file with the pboX tool, I've seen its content, and I able to see a file called "Onplayerkilled.sqs". I've made a .sqs file called "onplayerkilled.sqs" in my mission folder,at the beginning this script does not worked me, because missing this command ----> "enableEndDialog" Now this script worked well.  :good:

Quote
(Still have to improve my Spanish)

And I have to improve my English.

Saludos,
Aldo15
Title: Re: How I make my own custom scene, when the player is dead?
Post by: Lenyoga on 25 Mar 2011, 16:07:51
Oops I just saw you already mentioned the script above... I'm getting blinder and blinder...