Jump to content

How do I make a terminal check for caps???


trewbarton

Recommended Posts

Is there a way to have a terminal menu item check for caps before running an item result script? Ex. Player wishes to buy a perk for 300 caps using the script

 

player.AddPerk ???Perk

player.RemoveItem caps001 300

 

DisablePlayerControls

StartQuest ImplantTimerQuest

set GameHour to (GameHour + 3)

 

How would you enforce the 300 cap stipulaation?

 

p.s. I'm new at this

Link to comment
Share on other sites

Is there a way to have a terminal menu item check for caps before running an item result script? Ex. Player wishes to buy a perk for 300 caps using the script

 

player.AddPerk ???Perk

player.RemoveItem caps001 300

 

DisablePlayerControls

StartQuest ImplantTimerQuest

set GameHour to (GameHour + 3)

 

How would you enforce the 300 cap stipulaation?

 

p.s. I'm new at this

 

 

When you enter the strip a securitron asks for a credit check, go into that code if you can and see how they did it.

Link to comment
Share on other sites

  • 2 weeks later...

Is there a way to have a terminal menu item check for caps before running an item result script? Ex. Player wishes to buy a perk for 300 caps using the script

 

player.AddPerk ???Perk

player.RemoveItem caps001 300

 

DisablePlayerControls

StartQuest ImplantTimerQuest

set GameHour to (GameHour + 3)

 

How would you enforce the 300 cap stipulaation?

 

p.s. I'm new at this

 

When you enter the strip a securitron asks for a credit check, go into that code if you can and see how they did it.

 

 

As I'm working on something that uses this exact thing, I might be of assistance.

 

Set the Reference to player (which is located in the 188 base block), then GetItemCount as the Function. Count the item Caps001. Operator => and the value whatever you want it to be.

 

On another line, the reference is subject. GetIsID (for the terminal itself). Although I'm not certain this is necessary, but the NPC's that use similar code use this as well.

 

Hope I wasn't completely vague.

Link to comment
Share on other sites

  • Recently Browsing   0 members

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