I am currently trying to play a video in a loop via SpriteKit. I know that I need AVFoundation and the AVPLayer() for this, however I don't know how to initialize and use this... Could someone help me with this?
Here is my current code block:
let mapSeriallyVideo = SKVideoNode(fileNamed: "map_serially.mp4")
mapSeriallyVideo.position = CGPoint(x: 850, y: 1100)
addChild(mapSeriallyVideo)
mapSeriallyVideo.play()