Home   Help Search Login Register  

Author Topic: Trying to make onPlayerRespawnAsSeagull "optional"  (Read 1507 times)

0 Members and 1 Guest are viewing this topic.

Offline desertjedi

  • Members
  • *
Trying to make onPlayerRespawnAsSeagull "optional"
« on: 22 Sep 2009, 18:21:04 »
I am finally fairly certain I know what causes the "insta-death" problem that I discussed here:
http://www.ofpec.com/forum/index.php?topic=33973.0

It happened again this morning. I moved the mission recap panel and I saw an enemy soldier in the far distance and a green tracer on its way to kill me - and that's literally how the mission ends...no sound, no animation, no seagull, no nothing.

The reason, I'm fairly sure, is because onPlayerRespawnAsSeagull.sqs is calling Kegety's Spectating script. The script must realize that I am the last player to die and that no spectating is done and then the mission simply ends.

At this point, it may be too late but I'm wondering if there's anyway to change the call to the spectating script so that the default seagull animation occurs if I'm the last one to die.

I'm guessing not as onPlayerRespawnAsSeagull.sqs has probably already intercepted the call to the default animation and you can not "get back to it".

It would be nice if players who die first get to spectate and the last player to die gets the seagull animation. I keep all my missions "multi-player" friendly but my gaming buddy has very little gaming time so I end up playing alone mostly and I don't get the seagull.

Offline tcp

  • Members
  • *
    • Violator Gaming
Re: Trying to make onPlayerRespawnAsSeagull "optional"
« Reply #1 on: 13 Oct 2009, 01:48:18 »
A quick fix would be to put ~10 at the top of onPlayerRespawnAsSeagull.sqs to make it wait 10 seconds before doing anything. You'll probably be able to change the behavior of the spectator script as well.

Also, the game supports an Outro with different conditions for Win and Loose.

Offline desertjedi

  • Members
  • *
Re: Trying to make onPlayerRespawnAsSeagull "optional"
« Reply #2 on: 14 Oct 2009, 17:43:44 »
Great idea on the 10 second delay. I'm not sure what it will do. Maybe, it will at least give me a decent death animation - I'm not sure.

Yeah, if I was more familiar with editing I could mod the spectator script but I doubt I could make a call to the "Arma default death animation" subroutine if you get my drift.

I will do some research into Outros.

Thanks for the possible solutions.

Offline desertjedi

  • Members
  • *
Re: Trying to make onPlayerRespawnAsSeagull "optional"
« Reply #3 on: 19 Nov 2009, 17:58:52 »
I tried a 10 second delay at the start of the spectating script but it did nothing. I still got the "insta-death". It's kinda crazy - the mission ends and you're still standing there - even though in the game, you died.

But I did find another solution! RueLight's Arma co-op mission pack has, what appears to be, a customized version of Kegety's Spectating script. This script is noticeably different than the version I find in so many of the missions I d/l. It has "back" and "next" arrows so you can quickly scroll through soldiers to watch. It also allows you to "fly the bird" with keyboard controls. I looked at the code and it's noticeably different too and instead of several scripts and .hpp files, it's simply one large script file - that's it.

With the "RueLight" version, you see yourself die, the screen fades to black, then it fades back in and you're a seagull (in first person mode). YIPPEE!

Interestingly, I see the time delays and the "fade to black" and the "fade back in" in both "versions" but the RueLight version does the job. Now where's that dancing banana smiley?!?!
« Last Edit: 19 Nov 2009, 18:05:09 by desertjedi »