grey79 Posted February 10, 2012 Share Posted February 10, 2012 What the topic says:Does anyone know the conditions for making these two events trigger? Link to comment Share on other sites More sharing options...
grey79 Posted February 10, 2012 Author Share Posted February 10, 2012 Ok I figured it out. OnCellAttach is when the cell "enters" the world. Meaning it is now loaded into the engine, where before it was not.OnCellDetach is the opposite. So if I have a script on a mapmarker f.ex, containing the above events, then that event will trigger when the cell that mapmarker exists on is loaded into the game. Link to comment Share on other sites More sharing options...
kromey Posted February 10, 2012 Share Posted February 10, 2012 So what would that mean for an exterior cell in the Tamriel worldspace? Does it "enter" the world any time the player re-emerges from an interior cell (or another worldspace, or whatever), or do exterior cells "leave" and "enter" the world based on the player's proximity to them? I ask because this may be very useful for a mod I'm beginning to work on that does some serious stuff around Robber's Gorge... Link to comment Share on other sites More sharing options...
grey79 Posted February 10, 2012 Author Share Posted February 10, 2012 (edited) So what would that mean for an exterior cell in the Tamriel worldspace? Does it "enter" the world any time the player re-emerges from an interior cell (or another worldspace, or whatever), or do exterior cells "leave" and "enter" the world based on the player's proximity to them? I ask because this may be very useful for a mod I'm beginning to work on that does some serious stuff around Robber's Gorge... A cell is loaded when you are near it. So you can be pretty sure that if you are visiting Winterhold, then the cells surrounding and containing Markarth will not be loaded.However, if you are on the outskirts of Markarth, then the cells will loaded. Its an optimization trick obviously. No need to load cells the player has no way of seeing - which again means that every exterior cell is "detached (unloaded)" when you are in a dungeon or a similar interior cell. Hope that clarifies it. Here is a simple test I did:Attached a script to the mapmarker on the alchemistshack.The script contained the above events, and a simple Debug.MessageBox("") output. I fast travelled to a settlement nearby, and rode closer until i got the OnCellAttach event. Edited February 10, 2012 by grey79 Link to comment Share on other sites More sharing options...
kromey Posted February 10, 2012 Share Posted February 10, 2012 Awesome, thanks, that's exactly what I was hoping it would do! This event should let me script some neat action as I develop Robber's Gorge! Link to comment Share on other sites More sharing options...
Recommended Posts