Morphan1_calico_DoorEvents: type: world debug: true constants: directions: - 0,0,1 - 1,0,0 - 0,0,-1 - -1,0,0 - 0,0,-1 - -1,0,0 - 0,0,1 - 1,0,0 doorclosetimer: - if %data% >= 4 && == li@ { - switch %loc% - if { - switch %other% } - queue clear } else { - wait 5s - inject locally doorclosetimer } events: on player right clicks block: - if { - if && != i@air { - queue clear } - if contains s@dRegions_CanUse_Block && !|]||false> { - queue clear } else { - define loc - define data - if %data% > 7 { - define loc - define data } - define direction ]> - define top_data - define other - define other_top - if && == %data% && %other_top% != %top_data% { - switch %other% - wait 5s - inject locally path:doorclosetimer } - define other - define other_top - if && == %data% && %other_top% != %top_data% { - switch %other% - wait 5s - inject locally path:doorclosetimer } else { - wait 5s - inject locally path:doorclosetimer } } }