Jump to content

Reverting Camera Displacement


ProgMath2

Recommended Posts

player.SetRefEssential 1
player.Kill

Player falls to the ground. When he gets up, the camera is no longer located on the heigh of his head, but lies on the ground under his feet.

How to revert it back to normal position?

Edited by ProgMath2
Link to comment
Share on other sites

All I can recall is this is a known fact, and so far no way to fix it has been found. That's why all after-player-death type of events in mods actually have to "prevent" the player's death first of all by all means and just fake it instead.

Once the player is dead, he's dead, and the game has to be reloaded for it to become playable again. Trying to game the system with SetRefEssential like above will only mess things up.

 

But wait for someone else to chime in as well here, as what I know about the topic is likely some years old and possibly outdated already by now.

 

Coming to think of it, in the age of OBSE and Blockhead, have you tried "player.Update3D" already by chance? It fixes a lot of messed up skeleton issues with stuff I'm currently playing around, so maybe it will fix this one as well. Worth a try.

Link to comment
Share on other sites

The Player death doesn't just cause a camera misplacement: there are scripts which check for the player death and will stop working.

Also, I suppose many internal flags in the game will signal the player death (like the dead music), and a simple Player.Resurrect won't restore them.

Link to comment
Share on other sites

But wait for someone else to chime in as well here, as what I know about the topic is likely some years old and possibly outdated already by now.

Yep, that's what I've thought creating the topic. I read some articles in wikies saying that's impossible, but I assumed they must be older than modern script extenders.

have you tried "player.Update3D" already by chance? It fixes a lot of messed up skeleton issues with stuff I'm currently playing around, so maybe it will fix this one as well.

I did. It seems that camera is different object than animation skeleton. On player death some deep-buried script slowly lowers it for retard cinematic purposes. If you say something like player.SetRestrained 1 (which locks the camera) in the middle of that process, the camera will stay at that middle position.

 

to prevent death you can use event handler OnHealthDamage

I've created mod like that, you can try it Amulet of Greed at feature name Greed Eternal

also you can look at my code. maybe some inspiration come out

I didn't know about that handler, thank you.

I'll look on your code if I decide to make my own, my super-own undeath mod.

 

The Player death doesn't just cause a camera misplacement: there are scripts which check for the player death and will stop working.

Also, I suppose many internal flags in the game will signal the player death (like the dead music), and a simple Player.Resurrect won't restore them.

There's a lot of mods that implements player immortality. And now you just come here and say "I don't believe in immortality".

 

 

 

I was thinking about making my own Sheogorath immortality mod. I know that the other ones exist, but I was hoping that high-end scripting could already have solved some problems that had been making the modders of the past use surrogate ways to acquire the result (and I don't trust other people's mods, that's the second reason).

The main reason I've started thinking about that is the paradox of Shivering Isles:

Sheogorath is above SI laws, but even Sheogorath can't eat 3 portions of Greenmote and stay alive.

I find this... discriminating.

Therefore, preventing death is not a panacea, because it won't catch the "kill" command.

Edited by ProgMath2
Link to comment
Share on other sites

Master Forli ! :D

 

anyway, what my master said is right about "many internal flags in the game will signal the player death (like the dead music), and a simple Player.Resurrect won't restore them."

 

that's why it will gonna be a long road if you try change original player death mechanism. you must overhaul the Oblivion system, just thinking about it is pretty much hassle itself

 

I can create Greed Eternal (player immortal) feature is because I learn how to from Master Forli, he teach me event handler OnHealthDamage

Link to comment
Share on other sites

I don't believe in immortality because no mod does. Check all those mods: none of them wait for the player to die, they always save the player in the last second with either a check on his health or with the OnHealthDamage handler, but they won't let the player die.

As I said, the player death is something more than just putting a dead flag on the Player actor.

 

There is something which may help you: http://cs.elderscrolls.com/index.php?title=Resurrecting_the_Player

http://www.uesp.net/wiki/Tes4Mod:Resurrecting_the_Player

 

Note: the health threshold method (GetAV Health < x) can fail, but the OnHealthDamage method won't.

Edited by forli
Link to comment
Share on other sites

I think there also was a Vanilla script in Shivering Isles...

 

 

...making it so when being Sheogorath yourself you can cast a power that will save you the next time you die and will make you resurrect in the Isles afterwards.

 

 

But if I recall the code correctly, even the game's developers had to go the death "prevention" route to achieve this, for even they know of no way to correctly resurrect the player once he really died.

 

However, in one thing I share your concern. I'm not sure a handler called OnHealthDamage will be able to also catch a scripted "player.kill" command, and I know quite some features in the game which will kill you by that means and not by hurting you until death. :ermm:

Link to comment
Share on other sites

I've found a solutuion.

Set player essential + OnKnockout handler with SetRestrained 1.

The camera stays ok in almost all the cases (except for situations with heavy lags).

No actual death happens, GetDead/OnDeath doesn't ring, so all the scripts should continue their work.

Edited by ProgMath2
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...