Talk:Activation Functions
Revision as of 17:34, 10 September 2007 by imported>Haama (Notes on multiple activations)
"There appears to be some kind of recursion catch that stops calls working if the same script is called within the same frame more than ~4 times."
Guidobot, is this only true for recursion? I've not had any problems so far with 100s of activations (and yes, I need them), so long as it's another script calling the activator, and not the activator calling itself. Are there special circumstances?
--Haama 04:40, 12 July 2007 (EDT)
- I assume that the limit is put there as a recursion catch but it is active no matter how the object script is called within the same frame, e.g. having multiple Activate/PlaceAtMe lines in a single script or in multiple scripts running in the same frame. This also applies to scripts on objects placed in the game. For example, when you have 4 or more scripted skeletons some will appear to freeze/lag.
- --Guidobot 20:11, 9 September 2007 (EDT)
- I've done a bit more testing since then (see Activate), and as far as I can tell it's only true of recursion (not sure about the skeleton thing, though). One of my mods, Inventory Tracker, activates a single activator 1000 times a frame without any problems (reported, or in tests). The recursion limit also seems to be limited to the onActivate block, as I've run over 250 quest result scripts from within each other (again, see Inventory Tracker). I've also done some tests with mixes of result scripts and onActivate blocks, and 'SomeObject.Activate player, 1' won't run if and only if there are 3-4 other onActivate blocks running at the time (not, in the same frame). I'd have to dig those tests up, though.
- --Haama 18:34, 10 September 2007 (EDT)