Jump to content

NPCs use stimpak scift


Deleted48943468User

Recommended Posts

You could look at how this works:

https://www.nexusmods.com/newvegas/mods/39058

 

If you're not looking to give them extra stim-paks, my approach would just be something like

if GetHealthPercentage <= .5
    if GetItemCount Stimpak > 0
        EquipItem Stimpak
    endif
endif

But if you are looking to give NPCs stimpaks, I would probably do a script that makes an array of all NPCs in the load order at the start of the session, and then adds and equips stim-paks for them based on certain conditions, such as randomness, level health per centage, or whatever you like.

 

I'm personally fond of using the player's Luck value in my calculations. I have a hostile NPC that when you go through a door is spawned at a distance from the player that is smaller if the player's luck is lower and larger if the luck value is higher. It depends on other values as well, but I like that Luck is part of the equation.

Link to comment
Share on other sites

  • Recently Browsing   0 members

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