1. SPS Accounts:
    Do you find yourself coming back time after time? Do you appreciate the ongoing hard work to keep this community focused and successful in its mission? Please consider supporting us by upgrading to an SPS Account. Besides the warm and fuzzy feeling that comes from supporting a good cause, you'll also get a significant number of ever-expanding perks and benefits on the site and the forums. Click here to find out more.
    Dismiss Notice
Dismiss Notice
You are currently viewing Boards o' Magick as a guest, but you can register an account here. Registration is fast, easy and free. Once registered you will have access to search the forums, create and respond to threads, PM other members, upload screenshots and access many other features unavailable to guests.

BoM cultivates a friendly and welcoming atmosphere. We have been aiming for quality over quantity with our forums from their inception, and believe that this distinction is truly tangible and valued by our members. We'd love to have you join us today!

(If you have any problems with the registration process or your account login, please contact us. If you've forgotten your username or password, click here.)

pull a rope - open a door...

Discussion in 'Neverwinter Nights (Classic)' started by Dice, Dec 15, 2002.

  1. Dice

    Dice ★ SPS Account Holder Adored Veteran

    Joined:
    Jun 23, 2002
    Messages:
    5,125
    Media:
    24
    Likes Received:
    149
    Gender:
    Female
    [​IMG] Hi, Its me again with another question. I hope I'm not being a pest. I was just wondering how I can make a locked door open when I have my character pull a rope. All you guys have been so helpful I thought you could help me with this one...or tell me where to go to find the answer. :wave: Thanks again.
     
  2. Capt. Tripps Gems: 9/31
    Latest gem: Iol


    Joined:
    Mar 11, 2001
    Messages:
    341
    Likes Received:
    0
    There's no rope placeable but there is the pull chain. To simply unlock the door put this in the OnUsed script:
    Code:
    void main()
    {
     object oDoor = GetObjectByTag("yourdoorsname");
     SetLocked(oDoor,FALSE);
    }
      
    Put the tag for your door in "yourdoorsname".
    You also might want to add a sound playing and maybe a speak string line to let the players know that something has happened.
     
  3. Dice

    Dice ★ SPS Account Holder Adored Veteran

    Joined:
    Jun 23, 2002
    Messages:
    5,125
    Media:
    24
    Likes Received:
    149
    Gender:
    Female
    [​IMG] hmmmm. Thanks Capt. Tripps, I did exactly as you said and it didn't work. I have the object put on as usable, and the door tag (door1) is on both the door and in the script for the pull chain. When my character goes to pull it while I am playing the module, the program shows no action what-so-ever, as if it is just there for looks and nothing else. So what am I missing? Thankyou for the script by the way.
     
  4. Capt. Tripps Gems: 9/31
    Latest gem: Iol


    Joined:
    Mar 11, 2001
    Messages:
    341
    Likes Received:
    0
    Did you try the door both before and after pulling the chain? The door should be locked before you pull the chain and unlocked after you pull it. Nothing appears to happen because you have to add the scripts to make things happen. That's why I said you may want to add a sound and a string. Add this after the SetLocked statment:
    Code:
     SpeakString("You hear the sound of a bolt being drawn");
    You can put any statement you want between the quotation marks.

    or to have the door open
    Code:
    ActionOpenDoor(oDoor); 
    Also just to help keep things from getting too confusing, I would rename your door tag to something like ChainUnlock01. This can help when your have to search for it later and find that every area you have created that has doors has a door1.

    [ December 16, 2002, 10:38: Message edited by: Capt. Tripps ]
     
  5. Dice

    Dice ★ SPS Account Holder Adored Veteran

    Joined:
    Jun 23, 2002
    Messages:
    5,125
    Media:
    24
    Likes Received:
    149
    Gender:
    Female
    Well, the only reason I wasn't getting that door to open was because I called it "door1" in the script when its tag was actually "Door1."
    I'm starting to understand script a little now. I incorperated your suggestions with the speakstring and it looked nice. I didn't bother giving the tag a better name for now because I'm just practicing. I will keep your advice in mind for my next mod though. Thanks again.
     
Sorcerer's Place is a project run entirely by fans and for fans. Maintaining Sorcerer's Place and a stable environment for all our hosted sites requires a substantial amount of our time and funds on a regular basis, so please consider supporting us to keep the site up & running smoothly. Thank you!

Sorcerers.net is a participant in the Amazon Services LLC Associates Program, an affiliate advertising program designed to provide a means for sites to earn advertising fees by advertising and linking to products on amazon.com, amazon.ca and amazon.co.uk. Amazon and the Amazon logo are trademarks of Amazon.com, Inc. or its affiliates.