Jump to content

Trying to get a Rad Purge Script to work


PAJB666

Recommended Posts

Hey guys, im trying to add a rad purge script to my bunker mod im making, so far it wont save which i know means theres a problem with the script ive written itself. im trying to get it to purge rads when i activate a switch on the wall.

 

i need a fresh set of eyes to look it over for me

 

SCN Radpurge

 

begin OnActivate

if ( checkChoice )

set choiceID to GetButtonPressed

if ( choiceID > -1 )

if ( choiceID == 0 )

set currRads to Player.GetActorValue RadiationRads

if ( currRads > 0 )

Activate

PurgeChamberRef.SetOpenState 0

set purifyStage to 1

endif

endif

set checkChoice to 0

endif

End

 

many thanks guys

Link to comment
Share on other sites

Hey guys, im trying to add a rad purge script to my bunker mod im making, so far it wont save which i know means theres a problem with the script ive written itself. im trying to get it to purge rads when i activate a switch on the wall.

 

i need a fresh set of eyes to look it over for me

 

SCN Radpurge

 

begin OnActivate

if ( checkChoice )

set choiceID to GetButtonPressed

if ( choiceID > -1 )

if ( choiceID == 0 )

set currRads to Player.GetActorValue RadiationRads

if ( currRads > 0 )

Activate

PurgeChamberRef.SetOpenState 0

set purifyStage to 1

endif

endif

set checkChoice to 0

endif

End

 

many thanks guys

 

I would love to add this to my mod! If you get it done post it here! this may help lots of people

Link to comment
Share on other sites

I'm having difficulty following what you're doing in your script. If you just want to cure the player's rads when they hit the switch, all you need is something like this:

 

scn AAPurgeRadiationSwitchSCRIPT

ref target

begin onActivate
set target to getActionRef
target.restoreAV RadiationRads 1000
end

Link to comment
Share on other sites

  • Recently Browsing   0 members

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