Virtual Entity 의 시야를 플레이어가 공유받을 수 있게됩니다.
Camera 는 Virtual 환경에서만 동작하기 때문에 별도의 Handler 를 구성하여 제어해야합니다.
( 그렇지 않으면 플레이어는 접속을 종료하기 전 까지 원래의 시야로 돌아올 수 없게 됩니다. )
아래는 간단한 예제 코드와 인게임 테스트 이미지입니다.
val am = VirtualArmorStand(sender.location)
sender.virtual {
updateEntity(am)
setCamera(am)
while(!sender.isSneaking) {
am.setLocation(am.getLocation().add(.0, .05, .0,))
updateEntity(am)
delay(50)
}
setCamera(null)
am.destroy()
updateEntity(am)
}
Virtual Entity 의 시야를 플레이어가 공유받을 수 있게됩니다. Camera 는 Virtual 환경에서만 동작하기 때문에 별도의 Handler 를 구성하여 제어해야합니다. ( 그렇지 않으면 플레이어는 접속을 종료하기 전 까지 원래의 시야로 돌아올 수 없게 됩니다. )