Gonna start off by saying I'm fairly new to modding in general, let alone modding in Divinity 2, but this game has inspired me to try my hand at making a custom campaign. Most of what I've done so far is simply creating scenes, I just started scripting today and I've been trying to figure out how to fix this issue I'm having with a pressure plate and door.

I have this script to open/close a door with the pressure plate acting as the toggle, and that much is working great, however if the player clicks to move into the room while the door is open, the door closes before they reach the point, however the character stops as they reach the door and teleports past the door and continues moving to the clicked spot. (I didn't show it in the video because I forgot, but clicking outside the room after the door is closed will not move the character outside of it and will say 'Can't Reach'. So the AI grid is working fine.)

I tried making it so the door closes as soon as the player leaves the plate (the logic for that is commented out, and I just used those lines instead of the Behavior/Reaction at the bottom), it looks messy, but makes the door close faster. However that had the same effect.

Anyone know what might be causing this and if there's anything I can do to fix it so the character does go through the closed door?

Video of issue:
https://youtu.be/3e8kRq9wpYs

Script used:
[spoiler]INIT
ITEM:__Me
ITEM:%pressurePlate_01 = S_TV_EntryRoom_Plate_7e513eb1-b553-4848-99cb-3562dbd540ff
INT:%pressurePlate_01_State = 0


EVENTS
EVENT onInit_SetPos
VARS
FLOAT3:_Pos
ON
OnInit()
ACTIONS
ItemSetCanInteract(__Me,0)
ItemClose(__Me)


EVENT onEvent_SetOff
VARS
ITEM:_Item
ON
OnCharacterItemEvent(_,_Item,"S_TV_EntryRoom_Plate_off")
ACTIONS

Interrupt("moveToPosition")
IF "c1"
IsEqual(_Item,%pressurePlate_01)
THEN
Set(%pressurePlate_01_State,0)
//ItemClose(__Me)
ENDIF


EVENT onEvent_SetOn
VARS
ITEM:_Item
ON
OnCharacterItemEvent(_,_Item,"S_TV_EntryRoom_Plate_on")
ACTIONS
Interrupt("moveToPosition")
IF "c1"
IsEqual(_Item,%pressurePlate_01)
THEN
Set(%pressurePlate_01_State,1)
//ItemOpen(__Me)
ENDIF


BEHAVIOUR
REACTION moveToPosition,1
USAGE ALL
VARS
ITEM:_Item
CHARACTER:_Char
ACTIONS
IF "!c1&!c2"
ItemIsOpening(__Me)
ItemIsClosing(__Me)
THEN
IF "c1"
IsEqual(%pressurePlate_01_State,1)
THEN
IF "!c1"
ItemIsOpen(__Me)
THEN
ItemOpen(__Me)
ENDIF
ELSE
IF "c1"
ItemIsOpen(__Me)
THEN
ItemClose(__Me)
ENDIF
ENDIF
ENDIF
INTERRUPT
ACTIONS
Reset()[/spoiler]

Thanks!