Home   Help Search Login Register  

Author Topic: enableEndDialog  (Read 1380 times)

0 Members and 1 Guest are viewing this topic.

Offline Surdus Priest

  • Members
  • *
  • Only I can Forgive You!
enableEndDialog
« on: 04 Dec 2007, 12:56:01 »
where can i find the script in the arma folder which is called by the enableEndDialog command?

what i want to do is edit it so make my custom end dialog.

ps i wasnt sure if this was advanced enough for advanced scripting
Campaigns are hard, I'll stick with scripting for now!

Offline Spooner

  • Members
  • *
  • Mostly useless
    • Community Base Addons
Re: enableEndDialog
« Reply #1 on: 04 Dec 2007, 14:30:57 »
I'd guess you'd need an addon with the alternate end dialog in it. You could put an onLoad handler in this new version, to call your script in order to update it with whatever you want to change in it. Problem is that all missions would see this new dialog if the addon was installed. You could make any extra controls invisible at the start and only show them if your script was called (in your mission, that is). Frankly, though, I'd be afraid of potentially messing up every other mission...
[Arma 2] CBA: Community Base Addons
[Arma 1] SPON Core (including links to my other scripts)

Offline Wolfrug

  • Addons Depot
  • Former Staff
  • ****
  • Official OFPEC Old Timer
Re: enableEndDialog
« Reply #2 on: 04 Dec 2007, 15:24:31 »
Edit: I'm assuming you're wanting to change the player's death animation, since in ArmA the only place enableEndDialog is ever used is when the Player dies. :) Of course, if you want to go about changing the actual -dialog- displayed with the enableEndDialog command, I have no idea, but I'm guessing it'd involve modifying way too many core files for comfort.

Actually, all you need to do is create a script named onPlayerKilled.sqs in your main missions' folder, and put everything that happens on the player's death in there.  :good:

Here's some good reading:

Event Scripts

Wolfrug out.
« Last Edit: 04 Dec 2007, 15:29:30 by Wolfrug »
"When 900 years YOU reach, look as good you will not!"

Offline Surdus Priest

  • Members
  • *
  • Only I can Forgive You!
Re: enableEndDialog
« Reply #3 on: 04 Dec 2007, 18:12:10 »
actually i was thinking on the lines of making a replica of the enddialog.  all i would need are the commands for the buttons; quit, replay mission, load auto, and load.

then i was hoping that someone could tell me the location of the original so i could copy paste it into a script i can call to activate in the onplayerkilled.
Campaigns are hard, I'll stick with scripting for now!

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re: enableEndDialog
« Reply #4 on: 04 Dec 2007, 22:09:47 »
enableEndDialog is only used in two scripts, death1.sqs and deathDefault.sqs

Both of these files are held in ca\data\scripts.


Planck
I know a little about a lot, and a lot about a little.

Offline Surdus Priest

  • Members
  • *
  • Only I can Forgive You!
Re: enableEndDialog
« Reply #5 on: 04 Dec 2007, 22:33:15 »
i found them, but what does the command call? where is the script or config that it calls?
Campaigns are hard, I'll stick with scripting for now!

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re: enableEndDialog
« Reply #6 on: 05 Dec 2007, 03:18:59 »
My understanding is this is just a command that enables the load, retry, or quit dialog to appear when the player dies and the onPlayerKilled script is run.

Placing this command in your own onPlayerKilled script will enable those buttons.

At a guess I would say the code that the command runs to achieve this is part of the game .exe as indeed the command itself is.


Planck
I know a little about a lot, and a lot about a little.

Offline Surdus Priest

  • Members
  • *
  • Only I can Forgive You!
Re: enableEndDialog
« Reply #7 on: 05 Dec 2007, 04:17:23 »
drat... ok then, we may have to move this onto advanced scripting.....

i need advise on how to replicate the buttons which appear on enableEndDialog.
Campaigns are hard, I'll stick with scripting for now!