Jump to content

Recommended Posts

Posted

I need some help to write an Ondeath script, so when I kill a specific NPC, it will make the Player Essential and enter into bleedout instead of being able to be killed. Im definitely an amateur when it comes to scripting, and have tried dissecting various mods and investigating the wiki to try and figure it out, my sadly I cannot get it. Any help would be appreciated. (And then of course writing a script to make the player un-essential again as well)

Posted
You cant make an actor essential with a script. Only thing you could do is increase the hp of the player when it goes below a limit or try to resurrect the player after he got killed.
Posted

I agree, you can make the Player essential. There is another mod that actually does it, but gets very complicated with the scripting because of what the mod entails, so I had a very difficult time trying to dissect it.

 

Ive seen that in the wiki about setessential to the actor base. My problem is I dont understand how this looks when putting the whole script together, with the "extends to", and the "Auto", etc. Again I am very amateur at this, and am trying to learn and understand it. The most I am really able to do are ondeath, onopen, ontriggerenter, etc. scripts that enable or disable items.

But I am having a difficult time understanding how to write something that affects the actorbase.

Posted (edited)

All I can suggest is to start at the beginning and work from there.
I know it not what you want to do, but you've got to learn to crawl before you walk.

Start with:
http://www.creationkit.com/Bethesda_Tutorial_Papyrus_Hello_World

Then continue on with the basic tuts.
After you've done them (not skimmed them or skipped to the end) you will understand "extends" and "Auto" or at least what they relate to.
You will also understand what a property is and more.

Then you will be able to do that basic task your trying to do.

Edited by sLoPpYdOtBiGhOlE
Posted

I believe you might be able to make the player essential by attaching them to an alias in a quest. Look at this:

 

http://www.creationkit.com/Quest_Alias_Tab

 

You should be able to check the box that says "Essential" for a quest alias you create yourself. Then direct the alias towards the player by clicking on "Forced Reference" and selecting the PlayerREF object reference (found in any cell in the vanilla game).

 

This, of course, assumes you've set up a quest that knows when to place the player into the quest alias in order to make them essential, and take them out again once they no longer need to be immortal. Do you know how to do that?

Posted (edited)

At this line of the ops response

 

 

My problem is I dont understand how this looks when putting the whole script together, with the "extends to", and the "Auto", etc.

 

Without the basic fundamentals of understanding things such as declaring a property or the very start of what the script extends...

So using ForceRefTo() and Clear() in a script attached to the quest or anything, will beyond the ops scope untill he/she does some reading.

Edited by sLoPpYdOtBiGhOlE
Posted

Ok. Please dont hate me. Im a moron. But I could of had it working the whole time. I ummmm, kind of had the mod Everyone Killable turned on. :confused:

 

I have it working by marking 'The Player' as essential as a quest alias.(which I originally tried, but sadly..........Everyone Killable...... :blush: )

 

I also can have it working with script. I have tested with an Ondeath script ive placed it on an NPC, also even an OnOpen script I put on a door. I will share the script if anyone is interested.

One thing is, when I enter bleedout, I stay in bleedout, and wont exit it unless I use a potion to cure myself. After that if I enter bleedout again, Im immediately healed right away. Weird

 

By the way, I said I was amateur with scripting, I didnt say I was completely ignorant of it all. Personally for me if someone asked for help in an area, I would show them what needed to be done, and then explain why each component does what it does, especially with something that was really as simple as this. But thats just me.

  • Recently Browsing   0 members

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