From fa5c47b916aed0de68bcb4de3692c96560e4e399 Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Fri, 6 Jan 2017 23:35:39 +0000 Subject: Fix a slew of event like CHANGED_OWNER, attach() etc not working. Optimization can ba taken too far. Compile scripts synchronously for interactive rezzing because otherwise all events relating to rezzing/ wearing are lost. --- OpenSim/Region/ScriptEngine/XEngine/XEngine.cs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'OpenSim') diff --git a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs index cd5308d..e3922d6 100755 --- a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs +++ b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs @@ -1005,7 +1005,14 @@ namespace OpenSim.Region.ScriptEngine.XEngine Object[] parms = new Object[]{localID, itemID, script, startParam, postOnRez, (StateSource)stateSource}; - if (stateSource == (int)StateSource.ScriptedRez) + // There IS such a thing as too much optimization!! + // DON'T try to defer and queue the below states! + // Doing so may make rezzing snappier in world, but prevents + // vital events like attach, changed owner, etc, from firing. + // This just MUST be synchronous. Believe me, I'm The Author! + if (stateSource == (int)StateSource.ScriptedRez || + stateSource == (int)StateSource.NewRez || + stateSource == (int)StateSource.AttachedRez) { lock (m_CompileDict) { -- cgit v1.1