daisy8 Posted July 29, 2017 Share Posted July 29, 2017 Hi everyone I have a standard door that I am opening with an ID card reader, and that part works great. But what I want to do is hide the prompt to open the door - E) OPEN, and to play a message telling the player to use the ID reader instead. The OnActivate (and play message) script I put on the door wont fire because the door has blocked activation, so the ID reader is the only way to open it. Any ideas on how to do this ? Cheers !daisy Link to comment Share on other sites More sharing options...
kitcat81 Posted July 29, 2017 Share Posted July 29, 2017 I think you don't need any scripts for this. I have not tested myself, but there is a built-in option for doors, activators and other game files to change the activation text. Open your door in the CK and find "Alternate text" option with 2 empty fields where you can type your text for open and close option. Type "Use ID card" there and test in game. Link to comment Share on other sites More sharing options...
daisy8 Posted July 29, 2017 Author Share Posted July 29, 2017 Hey kitcat Thanks for the reply. Yeah, I have played with these, but then text shown on the door is "Security Door, E) Use Keycard" and when the player activates the door nothing happens apart from a click sound. I want the door to just have no prompt and to show message when the player tries to activate it. I have been able to show a message on activate (but the door opens without the keycard). Cheersdaisy Link to comment Share on other sites More sharing options...
kitcat81 Posted July 29, 2017 Share Posted July 29, 2017 (edited) Hey kitcat Thanks for the reply. Yeah, I have played with these, but then text shown on the door is "Security Door, E) Use Keycard" and when the player activates the door nothing happens apart from a click sound. I want the door to just have no prompt and to show message when the player tries to activate it. I have been able to show a message on activate (but the door opens without the keycard). CheersdaisyUnderstood. Was the activation blocked by the same script (function BlockActivation()) ? If so then the OnActivate event should fire anyway. Otherwise I`m not even sure how you would be able to open the door. I don`t think there is any way to remove the prompt without making the door unusable. You can change the prompt almost for any object with a perk label. But I have not tried to use it on doors. Looked at the reader in the CK. As I understand the door is activated by the reader instead. So you can make your message pop up if you attach a script to the reader. Edited July 29, 2017 by kitcat81 Link to comment Share on other sites More sharing options...
daisy8 Posted July 29, 2017 Author Share Posted July 29, 2017 Hey Yeah, the reader I am using has a script with lots of messages for things like player has no card or the reader is inactive and they all work fine. But I want the message to show when the player attempts to open the door. I have prevented the player from opening the door by setting the door to only activate on a parent activator and then just not setting an activator. The reader script then activates the door when the card is swiped. You are right - difficult to get a message to show on activate when the player can't activate the door ! I have tried a script on the door when the door is able to be activated by the player. (Activate parent only unchecked)On activate -1. block activation2. play message3. unblock activation But the door still opens when the player activates the door. This did also show a message though, which is good ! Would states make a script like this work ? daisy Link to comment Share on other sites More sharing options...
kitcat81 Posted July 29, 2017 Share Posted July 29, 2017 You are trying to block it after activating so it does not block it. You should use BlockActivation in another event like OnInit(). Also you don`t need to unblock it to show a message. But in this case you need a way to make it open when you use the reader . You also need to make the door block again if you close it. If you wait a bit I wil ltry to give you more detailed plan. Link to comment Share on other sites More sharing options...
kitcat81 Posted July 29, 2017 Share Posted July 29, 2017 (edited) DoorScript Event OnInit() Self.BlockActivation() EndEvent Event OnActivate(ObjectReference akActionRef) If GetOpenState() == 3 ; If the door is closed If akActionRef == Game.GetPlayer() MyMessage.Show() ElseIf akActionRef is Actor ; do nothing Else ; supposed work if the door is activated by the reader script . In properties of the reader script you should set "Activate as Player" to False SetOpen() EndIf Else SetOpen(False) EndIf EndEvent Edited July 29, 2017 by kitcat81 Link to comment Share on other sites More sharing options...
daisy8 Posted July 30, 2017 Author Share Posted July 30, 2017 Hey kitkat That script works great. It still shows the open prompt when the player approaches the door but it plays the message and the door doesn't open so I can live with that. I'll add some script to yours that closes the door after a short time delay. Thanks a lot for your help !daisy Link to comment Share on other sites More sharing options...
deadbeeftffn Posted July 30, 2017 Share Posted July 30, 2017 You may try Event OnInit() Self.BlockActivation(True, True) EndEvent This way the open prompt will not be shown. Link to comment Share on other sites More sharing options...
kitcat81 Posted July 30, 2017 Share Posted July 30, 2017 (edited) Gld it helped. You can rename the prompt to "Inaccessible" or "locked". You can follow Deadbeeftfffn advice and it will really remove everything - the name and the promt, but then your message won`t work too. Not sure about the reader. Just an option. Instead of blocking activation you can set a lock on your door. It will also change the prompt and when you try to activate the door, you`ll get player comments or/and some vanilla messages that depends on the lock level. Event OnInint() Lock() SetLockLevel(254) ; level 254 will show 'inaccessible" promt and the player will comment "bloked" and "useless", 255 - is "required key", 253 - "terminal only" etc. Type " locklevel" in the CK to learn about global lock values; EndEvent Event OnActivate(ObjectReference akActionRef) If IsLocked(); If the door is locked and obviously closed If akActionRef == Game.GetPlayer() MyMessage.Show() ElseIf akActionRef is Actor ; do nothing Else ; supposed to work if the door is activated by the reader script . In properties of the reader script you should set "Activate as Player" to False Unlock() ; unlocks the door SetOpen() ; optional line, automatically opens the door. EndIf EndIf EndEvent Event OnClosed(ObjectReference akActionRef) Lock() SetLockLevel(254) ; lock again when the door has finished closing. EndEvent Edited July 30, 2017 by kitcat81 Link to comment Share on other sites More sharing options...
Recommended Posts