Jump to content
Sign in to follow this  
dragon zen

[HELP!] SP Respawn: how to disable Blur and RedScreen after death??

Recommended Posts

Hey Friends:

Now I edit SP mission and let player respawn after death (use selectplayer)

But the question is that, sometimes the screen will become red, or high blur after death.

How can I disable such effect or use script to turn it normally? They are very annoying.

Does it concern with "colorCorrections" ppEffectAdjust ??? I don't know how to do.

Thanks for help.

Dragon Zen

Share this post


Link to post
Share on other sites

Are you using TeamSwitch or some specific trigger to use selectPlayer to change units?

Share this post


Link to post
Share on other sites
Are you using TeamSwitch or some specific trigger to use selectPlayer to change units?

Yes, I achieve respawn in SP mission is to create another unit and selectPlayer to that new unit. Does it matter?

I think the major problem is that sometimes the machine run really slow so that the selectPlayer cannot be executed before screen become red....

Share this post


Link to post
Share on other sites

I add a "killed" eventhandler to player to run a file in case of death.

The file triggers and you have as much time as you want in there.

I create a new unit, copy the contents of the dead player to the new player, and selectPlayer to the new unit.

Share this post


Link to post
Share on other sites
I add a "killed" eventhandler to player to run a file in case of death.

The file triggers and you have as much time as you want in there.

I create a new unit, copy the contents of the dead player to the new player, and selectPlayer to the new unit.

Yes, me too. And I guess the problem of red screen and blur is due to the low running of machine, therefore can't do what we need before the screen change.

Share this post


Link to post
Share on other sites

I start my file with a

cutText ["respawning","BLACK IN", 5];

Probably it overwrites the BIS cut.

Share this post


Link to post
Share on other sites
I start my file with a

cutText ["respawning","BLACK IN", 5];

Probably it overwrites the BIS cut.

Thanks for the help. But I'm afraid it was not a cut, but some ppEffect since the screen become always blur or keep red.

Share this post


Link to post
Share on other sites

what seemed to work for me was making sure my respawn script was called, and not spawned from the eventhandler....if you're spawning, 2 scripts are running side by side competing, sometimes the death-blur winning. if you call, you force the game to wait and execute your code first

Share this post


Link to post
Share on other sites

Good call dr_strangepete!!!

I couldn't answer if I should use spawn or call: I went with call, but it was pure luck. Now I have knowledge! Thanks!

Share this post


Link to post
Share on other sites
what seemed to work for me was making sure my respawn script was called, and not spawned from the eventhandler....if you're spawning, 2 scripts are running side by side competing, sometimes the death-blur winning. if you call, you force the game to wait and execute your code first

wow, thx dr_strangpete, I use waitUntil and this may not very strong.

Could u please copy your script about "call"? where do you insert this code?

Share this post


Link to post
Share on other sites

He meant:

player addEventHandler ["killed",{call respawnScript}];

And NOT:

player addEventHandler ["killed",{[]execVM respawnScript}];

player addEventHandler ["killed",{[]spawn respawnScript}];

player addEventHandler ["killed",{yourcode}]; (Your code put between the brackets is spawned/execVMed)

Call is not paralell, so it keeps control of the programflow (preventing BIS die code executed)

the others are all paralell, so the program flows further in the background (and this way: BIS original die code is executed)

In the called script you can use waituntil and such, although it is not nice practice to use sleeps and waituntils in called (nonparalell) code.

Edited by zapat

Share this post


Link to post
Share on other sites
He meant:

player addEventHandler ["killed",{call respawnScript}];

And NOT:

player addEventHandler ["killed",{[]execVM respawnScript}];

player addEventHandler ["killed",{[]spawn respawnScript}];

player addEventHandler ["killed",{yourcode}]; (Your code put between the brackets is spawned/execVMed)

Call is not paralell, so it keeps control of the programflow (preventing BIS die code executed)

the others are all paralell, so the program flows further in the background (and this way: BIS original die code is executed)

In the called script you can use waituntil and such, although it is not nice practice to use sleeps and waituntils in called (nonparalell) code.

Awesome!! thanks for your help

Share this post


Link to post
Share on other sites
Hey Friends:

Now I edit SP mission and let player respawn after death (use selectplayer)

But the question is that, sometimes the screen will become red, or high blur after death.

How can I disable such effect or use script to turn it normally? They are very annoying.

Does it concern with "colorCorrections" ppEffectAdjust ??? I don't know how to do.

Thanks for help.

Dragon Zen

BIS_DeathBlur ppEffectAdjust [0.0];
BIS_DeathBlur ppEffectCommit 0.0;

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×