Quest door

What it does
Only allows a certain PC (ie: the one assigned the quest) the ability to unlock a door.

The Script
//:: Name      Guild Quest Script ds //:: FileName   guild_quest_01ds //:: Copyright (c) 2001 Bioware Corp. //::////////////////////////////////////////////// /* PLACE THIS SCRIPT ON THE OnUnlock SCRIPT PART OF DOOR PROPERTIES MAKE SURE TO CHECK LOCKED (AND EVEN RELOCKABLE) ON DOOR PROPERTIES. MAKE SURE TO CHECK PLOT ITEM BOX SO A PC CANT JUST BASH DOOR APART This script relocks the side door if a non-quest PC unlocks it. It checks with the quest giving NPC to see if the quest has been given. //::////////////////////////////////////////////// //:: Created By: Larry Chambers //:: Created On: 10/14/2002 //::////////////////////////////////////////////// void main { // This gets the PC who unlocked the door object oPC = GetNearestCreature (CREATURE_TYPE_PLAYER_CHAR, PLAYER_CHAR_IS_PC); // This gets the quest-only door we are dealing with object oDoor = GetObjectByTag("dt_Nigels_Side_Door"); // This gets the NPC who handed out the quest (has has varibles // store on him that we need later in script   object oGillo = GetObjectByTag("Gillo"); // iRelockDoor will determine if we lock the door again    int iRelockDoor = TRUE; // Checks NPC (who gave out the quest) to see if Quest // was given to anybody (varible stored on NPC)    if (GetLocalInt(oGillo,"GuildQuest01") == 1)        { // Checks to see if PC who unlocked door is on either part of // two part quest, and if so, gives iRelockDoor a false setting.            if ((GetLocalInt(oPC,"GuildQuest01") == 1) || (GetLocalInt(oPC,"GuildQuest01") == 2))               iRelockDoor = FALSE;        } // Heres what we do with door once we determine its setting    if (iRelockDoor == TRUE)        { // This RELOCKS the unlocked door, thus not allowing PC to open it            SetLocked(oDoor,1); // This gives a simple message to PC telling him he cant use this door            ActionSpeakString("** This is a quest door, and has been relocked **");        } // This part gives XP reward (one time only) to PC (who is on quest) // since he was the one who unlocked the door when he was supposed to.    else if (GetLocalInt(oPC,"GuildQuest_SideDoor") != 1)        { // This statement lets the PC get 100 XP for opening front or side door // but not for both (ie: 100 XP once, for either door)            if (GetLocalInt(oPC,"GuildQuest_FrontDoor") != 1)                GiveXPToCreature(oPC,100); // This sets the varible on PC so he can't keep getting 100 XP just for // locking or unlocking door SetLocalInt(oPC,"GuildQuest_SideDoor",1); } }

Foot Note
Anyways, I hope this helps some of you out there with your MP mods.

I would also like to thank Huntsman29 and Elidrin for their help in trying to overcome this problem.

Any questions on this script, or if you find problems with it, please feel free to comment on it and I will try to help you.