Upon entering a cell, am forcibly warped to different cell?

Post » Tue Jan 19, 2016 9:31 pm

My problem is that I have two particular cells (cell X and Y) which if I enter, either by COC or by door, I am immediately teleported from that cell to a new one, cell Z, and my controls are disabled (disableplayercontrols). Additional info:


  • This bug makes no sense at all; cells X and Y are end-game locations in which the player's movements should be tightly controlled, and have nothing to do with cell Z, so I didn't set this up myself by mistake

  • If I COC back to cell X or Y a second time, I am no longer warped back to Cell Z anymore

  • If I COC to cell X or Y initially, I have to close the console before being warped, suggesting a menumode == 1 or cellchanged == 1 check?

  • Cell Z happens to be a transit type cell which I do have a number of scripts set up to warp the player to. However, none of the scripts which warp the player to cell Z are placed on any objects in Cell X or Y, or initiated by any scripts running in cell X or Y.

  • Previous versions of the mod file had no such problem, but while I have worked on cells X and Y recently, I can't pinpoint any new changes which could have produced this bug -- the changes have mostly been with statics

  • Console ('sv') tells me that no innappropriate global scripts are running before or after the warp bug

  • Cell X and Y are both similarly named, but a third cell also shares the naming similarity but is unaffected by the bug

  • This bug would pretty much cripple the end-game sequence of the mod, so please help me!

Later, I will try copy-pasting everything in cell X and Y and adding them to brand new dummy cells and seeing if the problem persists. I have no idea how or why this is happening.

User avatar
Pete Schmitzer
 
Posts: 3387
Joined: Fri Sep 14, 2007 8:20 am

Post » Tue Jan 19, 2016 3:21 pm

Try searching in the CS "Player->PositionCell" and "disableplayercontrols". It may give the clue as to which script is causing it.

User avatar
Jennie Skeletons
 
Posts: 3452
Joined: Wed Jun 21, 2006 8:21 am

Post » Tue Jan 19, 2016 11:25 am


Yeah, I tried searching the CS for cell Z's name, which should be a more sensitive way of finding the right scripts, but none of them ran (see below) when the bug showed its ugly face.



Update:



I just ran a test where I used the CS search to find all scripts which included the name of cell Z, and then wrote a global script which runs the scriptrunning check for all of those scripts and spews up messageboxes if any of them are running. Ran the script, warped, got bugged, but none of them triggered, so no script ran?



Also, I noticed that after getting bugged, a follower variable "NON_SabrinaFollowing" was set from 0 to 1, which is something that none of my warp scripts ever do (because if the var is 0 then Sabrina is not following, and 1 is following, so in no circumstance would a warp script ever say "oh, you didn't have Sabrina with you when I started? I'll warp you there and then tell the game that Sabrina is now with you when she is not").



Someone, please help me save my gorgeous end-game battle sequence!

User avatar
Tamika Jett
 
Posts: 3301
Joined: Wed Jun 06, 2007 3:44 am

Post » Tue Jan 19, 2016 3:43 pm

ScriptRunning only detects global scripts, so if it's a local script attached to some object you wouldn't get any messageboxes.



You could try copying the mod and deleting all the scripted objects from the cell then checking if the bug remains.


Most likely the bug originates from some script, but it's hard for us to pinpoint which without knowing any of their details.

User avatar
Ann Church
 
Posts: 3450
Joined: Sat Jul 29, 2006 7:41 pm

Post » Tue Jan 19, 2016 3:18 pm

It's weirdness like this which has, for many years now, put me off of playing with scripting. I eventually gave in and started teaching myself to cannibalize the work of vanilla scripts and other modders, reverse engineering similar bits of code into something I could use and understand.



Unfortunately, this method also comes with a lot of inefficiency and weirdness of its own, and it has been the death knell of many of my more complicated dream projects. So I can empathize with the frustration.



I do hope you figure it out, though, because whatever this 'end-game battle sequence' is, it sounds like something I would enjoy playing quite a lot!

User avatar
Mrs Pooh
 
Posts: 3340
Joined: Wed Oct 24, 2007 7:30 pm

Post » Tue Jan 19, 2016 4:40 pm

Sigh... whatever the diametric opposite of genius is, is what I am. Intimidating levels of stupidity. The culprit was that I had indeed attached a global warping script to an object present in both of these cells. The reason I didn't pick it up at first was because the object was a sword in someone's inventory, so it didn't show up on the render list. Looking at past mod versions, the swords aren't even meant to have scripts on them, so how... why... they ended up with those scripts are a mystery to me.






Glad you overcame the primal fear! The vast majority of my scripting related 3am-frustration-rampages are purely due to my own stupid mistakes (see above), in my experience. I rarely ever get stuck on the actual making scripts work part, and there really is so much more you can do with scripting than without, so I think you made the right choice by learning (though I know, it doesn't feel that way when things go wrong and you don't know why).



Also, your dialogue ideas from the other thread sound really cool! Have you thought about making a WIP thread on the mod forum? Mods which add dialogue and personality to the game are so rare...

User avatar
kevin ball
 
Posts: 3399
Joined: Fri Jun 08, 2007 10:02 pm

Post » Tue Jan 19, 2016 7:57 pm

Good to hear the problem is solved. Looking forward to that epic end-game battle sequence! ;)

User avatar
Sophie Louise Edge
 
Posts: 3461
Joined: Sat Oct 21, 2006 7:09 pm

Post » Tue Jan 19, 2016 12:57 pm


I'll probably create a WIP thread once I'm a bit more comfortable with the way that I'm doing things.



Morrowind's dialogue system really wasn't ever designed for making branching conversations with multiple dialogue choices effecting the ultimate outcome. I'm also finding myself struggling to come up with adequate responses for the wide variety of characters players using my mod might be playing. I want them to be broad enough that everyone can find conversational options they 'like'... but not so broad that they begin to feel as generic as the default conversational options. This bit is hard, with only my own characters and play-style to go on. The responses I keep coming up with seem to fall more in line with the way my own characters would converse, rather than a broader audience. So that's going to need some work.



Lastly, I haven't quite worked out how to prevent infinitely repeatable dialogue loops yet... I initially wanted to use journal entries, but I've moved away from that now. Some journal entries would be good, but I don't want to overclutter the already very cluttered journal system.



Once I've settled on an actual course of action, I'll probably put up a WIP thread and let everyone tell me how awful and broken it is.

User avatar
Veronica Martinez
 
Posts: 3498
Joined: Tue Jun 20, 2006 9:43 am


Return to III - Morrowind