Jump to content

auto eat mod request for new vegas


kucingkucing

Recommended Posts

hi, I not native English speaker, sorry if there any mistake

ok, it quite silly, but I the creator of this mod :

The Witcher 3 - Auto Eat Mod
https://www.nexusmods.com/witcher3/mods/4479

I like to create the very same thing, but for the new vegas,
I do some research and this is the code:

Scriptname AutoEatScript extends Quest  

Event OnQuestInit()
   RegisterForHitEvent(PlayerRef)
EndEvent

Event OnHit()
    bool property done Auto
    int property consumingtime Auto
    int property total Auto

    done = false
    While (!done)
//    get item in slot 8
//    if (item in slot 8 not edible)
        done = true
        Debug.Notification("item in slot 8 is not edible")
//    elseif (slot 8 is empty)
        done = true
        Debug.Notification("slot 8 is empty")
      else
//      consumingtime = get item in slot 8 consume time
//      total = get item in slot 8 heal per second * consumingtime
        if (total <= (Game.GetPlayer().GetBaseActorValue("Health") - Game.GetPlayer().GetActorValue("Health")) )
//        consume item in slot 8
          Utility.Wait(consumingtime)
        else
          done = true
        endif
      endif
    EndWhile
EndEvent

note: the // in the start line is I don't know the syntax that i must type

 

if somebody can help me give a clue or even create this mod, I will very very happy,

 

thanks for your attention and have a nice day

Link to comment
Share on other sites

He said he wanted to create the same thing, but for New Vegas.

 

New Vegas doesn't have a quick potion / edible slot. I'm not sure how you would accomplish this in New Vegas.

 

Also, if you have the Lonesome Road DLC, auto-inject stimpaks are included with the DLC, which would effectively do the auto-healing that your mod is trying to do. You don't need a separate mod for that functionality.

Link to comment
Share on other sites

New Vegas doesn't have a quick potion / edible slot. I'm not sure how you would accomplish this in New Vegas.

 

Also, if you have the Lonesome Road DLC, auto-inject stimpaks are included with the DLC, which would effectively do the auto-healing that your mod is trying to do. You don't need a separate mod for that functionality.

thanks for the reply,

let ignore the slot thing, i get new idea:

if (Game.GetPlayer().getItemCount(ID_for_WateredBottle) >= 1)
// get ID_for_WateredBottle consuming time
// get ID_for_WateredBottle healing per second
// consume ID_for_WateredBottle
/*
elseif (another consumable)
*/
endif

now, this is simplified code,

the current problem is that 3 syntaxes (starting with //),

can somebody give me the clue for the syntax?,

thanks

 

 

Link to comment
Share on other sites

I've created a mod just like this for somebody else

You can find it here (https://www.nexusmods.com/newvegas/mods/67319?tab=files) under the name "virginharvester - 002"

 

It automatically consumes food and drink items in your inventory so you always stay at the desired health (Which can be specified in the included INI file). You can also blacklist certain food items.

Edited by IntenseMute
Link to comment
Share on other sites

I've created a mod just like this for somebody else

You can find it here (https://www.nexusmods.com/newvegas/mods/67319?tab=files) under the name "virginharvester - 002"

 

It automatically consumes food and drink items in your inventory so you always stay at the desired health (Which can be specified in the included INI file). You can also blacklist certain food items.

thank you very very much

Link to comment
Share on other sites

  • Recently Browsing   0 members

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