Ice Cold Nuka Cola

Post » Sat May 17, 2014 4:12 pm

Hi, I'm making my own very simple player housing mod for New Vegas, and I would love to have a Nuka Cola machine that is just like the one in My Megaton House, with the list of decisions about doing nothing, getting some ice cold nuka cola, or turning all nuka colas ice cold. I found the script for the original machine, and I understand that there are certain reasons why it doesn't work the same in New Vegas, but I just don't have the energy to teach myself enough coding to understand why it doesn't work. If someone who is familiar enough with writing codes for this to be a simple matter that does not require a great deal of effort, your help would be appreciated. Cheers

scn NukaVendingMachineScript

;The Player can add Nuka-Colas to the machine and have them changed to Ice-Cold Nuka-Colas
;The Player can then dispense them as desired

short Button
short NukasOnMe
short GoNuka


begin OnActivate

if ( IsActionRef Player == 1 )
if ( Player.GetItemCount NukaCola >= 1 )
ShowMessage HD00NukaMachineWith
set GoNuka to 2
elseif ( Player.GetItemCount NukaCola < 1 )
ShowMessage HD00NukaMachineWithout
set GoNuka to 1
endif
endif

end

begin gamemode

set Button to GetButtonPressed

if ( Button == 0 ) && ( GoNuka >= 1 )
Activate
set GoNuka to 0
elseif ( Button == 1 ) && ( GoNuka == 2 )
set NukasOnMe to ( Player.GetItemCount NukaCola )
Player.RemoveItem NukaCola NukasOnMe
AddItem MS05IceNukaCola NukasOnMe
set NukasOnMe to 0
set GoNuka to 0
elseif ( Button == 1 ) && ( GoNuka == 1 )
;Do Nothing
set GoNuka to 0
elseif ( Button == 2 ) && ( GoNuka == 2 )
;Do Nothing
set GoNuka to 0
endif

end

User avatar
Emerald Dreams
 
Posts: 3376
Joined: Sun Jan 07, 2007 2:52 pm

Post » Sun May 18, 2014 4:16 am

Look at the Underwater House mod, it has a Nuka Cola Machine that does just what you want. See how that script works.

User avatar
Nicole Mark
 
Posts: 3384
Joined: Wed Apr 25, 2007 7:33 pm

Post » Sun May 18, 2014 12:20 am

thank you

User avatar
Schel[Anne]FTL
 
Posts: 3384
Joined: Thu Nov 16, 2006 6:53 pm

Post » Sun May 18, 2014 4:04 am

that had the unintended outcome that i screwed up my master file. that code did not help me. that response was not actually what i was asking for. im not an idiot and i wasnt being lazy or feeling sorry for myself when i said i dont have the energy, its actually the truth. if anyone can answer my actual original request. that would be helpful. i understand completely if no one has the time or energy. it may take some time for me to figure out what i have now done to my master file. i may have to start building my mod again from scratch. at this point i cant even get my game to load. so there is no rush. if someone can help great, but if no one can help, or doesnt have the time or energy, please dont worry about it.

User avatar
Sweets Sweets
 
Posts: 3339
Joined: Tue Jun 13, 2006 3:26 am

Post » Sun May 18, 2014 5:53 am

His mod requires NVSE, and since that fridge is a Sorter, it could be that is needed to make his script run.

User avatar
Taylor Tifany
 
Posts: 3555
Joined: Sun Jun 25, 2006 7:22 am

Post » Sun May 18, 2014 4:02 am

That script will work just fine in New Vegas, I just tested it. The only thing you need to do is attach that script to a vending machine, I'd suggest making a copy (by simply renaming the ID to something of your choosing and creating the new form when asked) of NukaVendingMachine or MS05NukaColaVendingMachineClean if you want the pristine version. If you decide to copy the NukaVendingMachine then don't forget to delete the items that are already in it after you've copied it.

After that just make sure the script is attached to your vending machine copy and then place it in the world.

User avatar
Hella Beast
 
Posts: 3434
Joined: Mon Jul 16, 2007 2:50 am


Return to Fallout: New Vegas