1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 |
ZO_INTERACTION_SYSTEM_NAME = "interact"
--Interaction Manager
---------------------
return manager
end
EVENT_MANAGER : RegisterForEvent ( "InteractWindow" , EVENT_INTERACTION_ENDED , function ( _ , ... ) self : OnInteractionEnded ( ... ) end )
end
-- If we are interacting already, and the call comes from switching interactions, we need to make sure the previous interact
-- scene takes care of what it needs to before moving on to another interact scene. This is currently how it works,
-- but is not the ideal solution since there are implications of how InteractScene works that by happenstance work with this flow
if ( self . currentInteraction and ( interaction . type ~= self . currentInteraction . type ) and self . currentInteraction . OnInteractSwitch ) then
end
end
end
end
-- The intention here is to account for situations where the interaction got ended in code but Lua hadn't been aware of it
-- For example, if combat kicked the player out of an interact
-- For now this will only fire the callback if the interact that was cancelled was the same interact that this manager thought should be running
-- This is an edge case, the standard flow should have the owning scene starting and ending explicitly wherever possible
if self . currentInteraction and self . currentInteraction . interactTypes and self . currentInteraction . OnInteractionCanceled then
end
end
end
local interactTypes = interaction . interactTypes
if ( interactTypes ) then
for i = 1 , # interactTypes do
end
end
end
if interaction == nil then
else
end
end
--Bypass any hide confirmations with the arrested reason
local DONT_PUSH = false
else
if allowed then
else
-- If we're trying to bring up the conversation window but we rejected the request, we want to end that conversation
-- However, we don't want to end conversations if we were rejected by an already ongoing conversation
local isNotAlreadyInConversationInteractScene = true
if interactType == INTERACTION_CONVERSATION then
isNotAlreadyInConversationInteractScene = false
break
end
end
end
if isNotAlreadyInConversationInteractScene then
end
end
end )
end
end
if obj then
end
--if the object doesn't exist then it won't be showing
return false
end
-- function wrappers as this manager function is called from
-- multiple files. Now just redirects it to the proper object
-------------------------------------------------------------
end
end
-- Globals
-------------------------------------------------------------
|