Thanks Sebastian for taking the time to reply. Trying to learn here so that really helps While the docs is really helpfull, iām hoping to find some more coding examples here on the forum.
Because thereās not that many coding examples Iām having problems understanding how to use code to for example initiate things. Iām not new to coding (Python) and i learn best from reading other code examples. Is there any way to write it out in an example? For example, i donāt have a z.video object. What iāve found working easiest is just have the video loaded from a URL in a videoplayer symbol.
How would you use a z.video object in a script, have the video loaded from a URL maybe in to a videoplayer and then have it start 9 seconds in?
And then, how can i initiate/start a video based on a button?
Thanks in advance!
Mitsjol
edit example:
const videoplayer = symbol.nodes.videoplayer0;
const video = Z.Video("http://website.nl/url/to/video.mp4")
parent.on("pointerdown", (e) => {
// Runs when pointerdown occurs on the parent node
// The argument e contains useful info about this event:
// https://docs.zap.works/studio/scripting/reference/object/events/pointerdown/
video.start(); // how do i know where this is positioned? can i make it invisible untill it starts?
videoplayer.start(); // start funtion doesn't exist for a videoplayer symbol, right?
});