bomo99 Posted January 20, 2023 Share Posted January 20, 2023 Hello, i made a teleport spell about 4-6 years ago which works fine, but has a bug, but first i will detail what the teleport spell does then say what the bug is, here is what the spell does 1. on Spell cast move a marker to player2. then move player to a different marker3. change a Global Variable to 1(to switch between enter and exit states)4. when player casts the spell again they move to the marker from point 1 sounds simple, and it works very well, but the bug here might be what i am using but i'm not sure, when you save/autosave in the area after point 2, and close the game/CTD then load the save, and use the spell to leave it doesnt do anything at first, but when casted again it will do point 2, i am wondering if this is because i am using the static XMarker as the Ref for the markers, would changing these to Activators be more reliable? Link to comment Share on other sites More sharing options...
RomanR Posted January 21, 2023 Share Posted January 21, 2023 From the description it seems that your "mark" marker got completely purged. Is it set as permanent reference? Link to comment Share on other sites More sharing options...
bomo99 Posted January 21, 2023 Author Share Posted January 21, 2023 yes both markers are set to be persistent References Link to comment Share on other sites More sharing options...
Oblivionaddicted Posted January 21, 2023 Share Posted January 21, 2023 Why don't you create one spell for each teleportation point? Link to comment Share on other sites More sharing options...
bomo99 Posted January 22, 2023 Author Share Posted January 22, 2023 Why don't you create one spell for each teleportation point?i don't like clogging up my spell book if i can help it, if its possible to do with one spell using a global variable that changes which direction it takes, then i am happy Link to comment Share on other sites More sharing options...
IcelandicPsychotic Posted January 22, 2023 Share Posted January 22, 2023 You could open a MessageBox when the spell is cast where the player chooses which location to teleport to. Link to comment Share on other sites More sharing options...
bomo99 Posted January 22, 2023 Author Share Posted January 22, 2023 You could open a MessageBox when the spell is cast where the player chooses which location to teleport to.i prefer to not use messagebox for the teleport, as it would slow the spell a little, just want stable markers that wont break after a CTD, as i think static objects reset their positions, but i want to know if i were to change them to activators if it will be more reliable, as i have stated above, the spell works fine it is just after a CTD, the marker that moves to the player resets itself and traps in the area Link to comment Share on other sites More sharing options...
RomanR Posted January 23, 2023 Share Posted January 23, 2023 I had a little time yesterday, so I made "To Testing Hall and Back" spell. Today after further testing it seems I can present the spell script here. Spell was tested against saving and restarting Oblivion and also against waitng for 72 hours, which is default for performing cell reset. scn RomRTeleportScript float pos float angle begin ScriptEffectStart if RomRAddTeleportSpell.marker_set == 0 set angle to player.GetAngle Z if RomRTeleportMarkerRef.GetInSameCell player == 0 set RomRAddTeleportSpell.marker_set to 1 RomRTeleportMarkerRef.SetAngle Z angle RomRTeleportMarkerRef.MoveTo player else set pos to player.GetPos X RomRTeleportMarkerRef.SetPos X pos set pos to player.GetPos Y RomRTeleportMarkerRef.SetPos Y pos set pos to player.GetPos Z RomRTeleportMarkerRef.SetPos Z pos RomRTeleportMarkerRef.SetAngle Z angle set RomRAddTeleportSpell.marker_set to 1 endif endif if RomRAddTeleportSpell.marker_set == 2 set RomRAddTeleportSpell.marker_set to 0 player.MoveTo RomRTeleportMarkerRef endif end begin ScriptEffectUpdate if RomRAddTeleportSpell.marker_set == 1 set RomRAddTeleportSpell.marker_set to 2 player.MoveTo "244EB" endif end I hope it will help, even it's made for player only and overall is too simple. Link to comment Share on other sites More sharing options...
GamerRick Posted January 23, 2023 Share Posted January 23, 2023 (edited) Does GetInSameCell work for exterior world space cells? bomo99: Show us your code. It sounds like a simple script bug. Edited January 23, 2023 by GamerRick Link to comment Share on other sites More sharing options...
RomanR Posted January 23, 2023 Share Posted January 23, 2023 @GamerRick: Yes, however I always used this function in conjunction with player and persistent objects so far. Wiki doesn't mention any problem with exterior cells too, I checked it just for sure. Link to comment Share on other sites More sharing options...
Recommended Posts