CinnamonMods Posted June 27, 2020 Share Posted June 27, 2020 I would like to use the elevator button to teleport the player to a custom interior. Would that be possible, and if so how? Link to comment Share on other sites More sharing options...
Reneer Posted June 27, 2020 Share Posted June 27, 2020 It's certainly possible. You would simply need to attach a script to the elevator button and use the following code. Please note my Oblivionscript is rusty as heck and there may be ways to improve on this. Importantly, I haven't tried to compile it since I don't have Oblivion installed anymore. I hope this is helpful. Scriptname LGPL_ElevatorButton_OnActivateTeleportPlayer Copyright 2020 Reneer This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. Find a copy of the LGPL at https://www.gnu.org/licenses/licenses.html#LGPL. Begin OnActivate set refVar to GetActionRef if (refVar.GetIsReference Player == true) YourDoorRef.Activate Player endif End Link to comment Share on other sites More sharing options...
CinnamonMods Posted June 27, 2020 Author Share Posted June 27, 2020 It's certainly possible. You would simply need to attach a script to the elevator button and use the following code. Please note my Oblivionscript is rusty as heck and there may be ways to improve on this. Importantly, I haven't tried to compile it since I don't have Oblivion installed anymore. I hope this is helpful. Scriptname LGPL_ElevatorButton_OnActivateTeleportPlayer Copyright 2020 Reneer This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. Find a copy of the LGPL at https://www.gnu.org/licenses/licenses.html#LGPL. Begin OnActivate set refVar to GetActionRef if (refVar.GetIsReference Player == true) refVar.MoveTo YourCellMarkerHere endif End Thank you! Silly question, but where can I find my interiors cell marker or am I supposed to make one? Link to comment Share on other sites More sharing options...
Reneer Posted June 27, 2020 Share Posted June 27, 2020 Oh, actually, upon further inspection on best practices we should be activating the door for the interior cell. I've updated the script above. You should change YourDoorRef to whatever the persistent reference of the exterior door that leads to your interior cell. Link to comment Share on other sites More sharing options...
Recommended Posts