Quick script request: NoPickUp

Post » Tue Jun 19, 2012 9:03 pm

I'm a little intimidated about learning a whole new language, so I wondered if someone could write a quick script for me? It's for a silver platter I've hung on the wall as a mirror. I've checked the 'do not havok settle' button, but I don't want it to come off the wall if the player accidentally activates it, so I need a script to stop it being picked up.

In Morrowind, it would just have been

Begin NoPickup

if ( OnActivate == 1 )
Return
Endif

End

What would it be in Skyrim?

Thanks!
User avatar
Nims
 
Posts: 3352
Joined: Thu Jun 07, 2007 3:29 pm

Post » Wed Jun 20, 2012 2:12 am

it would be a lot easier to create a STAT object from the plate mesh instead of write a script for it


for example, look for one of those dreamcatcher wall decorations. duplicate it, swap out the mesh for your silver platter and rename the object.

done


BTW, even if you disabled it from being picked up, the "do not havok settle" thing wont protect it from being knocked off by an arrow, shout or any physical force.
User avatar
Patrick Gordon
 
Posts: 3366
Joined: Thu May 31, 2007 5:38 am

Post » Tue Jun 19, 2012 6:26 pm

Blockactivation
http://www.creationkit.com/BlockActivation_-_ObjectReference
does this for Skyrim.

it require that you have an onactivate() function in the object but you would obviously have
User avatar
T. tacks Rims
 
Posts: 3447
Joined: Wed Oct 10, 2007 10:35 am

Post » Tue Jun 19, 2012 2:29 pm

it would be a lot easier to create a STAT object from the plate mesh instead of write a script for it


for example, look for one of those dreamcatcher wall decorations. duplicate it, swap out the mesh for your silver platter and rename the object.

done


BTW, even if you disabled it from being picked up, the "do not havok settle" thing wont protect it from being knocked off by an arrow, shout or any physical force.
Obviously making a stat would be ideal, but I don't hve a bsa archive unpacker to get to the mesh I need.

Re the blockactivation, please could you put that in a whole script for me?

Thanks, both, for your replies

:edit: I'm downloading a bsa unpacker. Still be handy to know, though
User avatar
~Sylvia~
 
Posts: 3474
Joined: Thu Dec 28, 2006 5:19 am

Post » Wed Jun 20, 2012 1:47 am

Correction here, blockactivation will not stop you from bumping it just from activating it and probably from moving.

Event OnInit()
self.blockactivation()
endevent

Event OnActivate(ObjectReference akActionRef)
endevent

Event OnGrab()
endEvent

the empty functions is just to grab the events so they are not handled the default way.
User avatar
Tanya Parra
 
Posts: 3435
Joined: Fri Jul 28, 2006 5:15 am

Post » Tue Jun 19, 2012 9:53 am

Brilliant, thanks!

Sorry for being so helpless, but I'm not a coder so working with scripts is a big thing for me - it took me several years to really get comfortable with Morrowind's scripts, and most of the Oblivion/Fallout scripts I used were modified ones from Morrowind.
User avatar
Taylrea Teodor
 
Posts: 3378
Joined: Sat Nov 18, 2006 12:20 am


Return to V - Skyrim