Jump to content

A Sales Terminal


Rattlerx5150

Recommended Posts

For my next project, I want to make a terminal where you can buy certain items at a premium price

My intent is to duplicate something I made in FNV, were you can buy items like ammo, weapons, Stimpacks from a terminal

 

Because the scripting is so different I am asking for help

 

I need a basic script for each item where it will look to see if you have the correct amount of money for said item

if you do not it will give an error

if you do it will take the appropriate amount of caps

and give you said item

 

 

Link to comment
Share on other sites

I did this as one of my first scripting projects and it's not too hard once you figure out the logic of the script. Using that thing called the Googles I was able to find this when trying to figure mine out:

https://forums.nexusmods.com/index.php?/topic/1022683-unfinished-advanced-terminal-tutorial/

 

This should give you a nudge in the right direction. It's for FONV, but the basics still apply to FO4 scripting and it was the basis for the terminal script I ended up with. Just look through the FO4 CK wiki and you should be able to "translate" it for FO4.

Link to comment
Share on other sites

Like I said, it should be a nudge in the right direction. Or not apparently. If you want to learn how terminal fragments are scripted, I suggest you look at some vanilla ones in the CK. Maybe start with the book return machines. They are essentially vending machines.

 

All you really need to do is to define your properties then have an if statement to check the amount of caps the player has...

Next a then statement to dispense the item if they have enough caps...

Lastly a elseif to display a message if they don't have enough caps. Of the top of my head that's pretty much how I've done it.

Link to comment
Share on other sites

  • Recently Browsing   0 members

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