Jump to content

How to get the reference of the item activated?


Nexusmodsaccountno2

Recommended Posts

Is it possible to get the

 

Ref

 

In a script of the activated reference that the player is activating. (Pretty much the opposite of getactionref)

 

For example the player talks to an NPC by pressing the use key and "activating" (is talking considered activating?) them, can you get that NPCs reference in a script (and then do something with that ref)

 

Trying to set up a system where the player could heal an NPC by using/talking to them.

 

There is the cannibal perk where you can activate dead bodies but the result of that script is to affect the player while I want to affect the thing the player is interacting with.

 

Pretty sure this is impossible right?

Link to comment
Share on other sites

I think you want GetRef?

 

I use it for the examine texts in my quest mod, calling a different corner message depending on the Reference ID of the activated object.

 

It only works on Persistent Refs though, so it's not a blanket solution.

Edited by Radioactivelad
Link to comment
Share on other sites

  • Recently Browsing   0 members

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