Beiträge von ZioPano

    I need to disable to keyboard movements when the user has clicked an hotspot.
    I can easily disable the mouse movement by putting a layer over the pano.
    I can also disable the keyboard movement by setting the focus over another div/input.
    But is there a simpler way?

    I've tried this:

    this.pano.set("control.usercontrol", "off");
    Obviously it's obsolete/deprecated since centuries.

    Any tips?
    Thanks in advance

    Example:
    Let's say I'm making a game where I want that the player has access only to 3 scenes instead of all 4.
    Then when he solves the riddle in the first 3 scenes, I want to grant access to the 4th one.

    To accomplish this I need to prevent him to navigate to scene 4 until he solved the riddle.
    How can I do this? (dinamically from javascript)
    I use the Everpano navigator, I don't know if this changes things.

    Thanks in advance

    Hi,

    do you have an example?
    Or what do you mean with 'cycle again'?

    Alternatively you could request a redraw by calling updatescreen() or invalidatescreen():
    https://krpano.com/docu/actions/#updatescreen
    https://krpano.com/docu/actions/#invalidatescreen

    Best regards,
    Klaus

    Thanks Klaus for your reply.
    For "cycle again" I mean that after I've put all the hotspots invisibile, I need to put them again visible so I cycle again through them.
    I'll try the "invalidate" thing asap!

    Hello there,
    Sorry for the dumb question, I looked for an answer in the forum but I haven't found one.
    I'm cycling on the hotspots in this way (obviously this.pano is the pointer to krpano)


    for (let x = 0; x < this.pano.get('hotspot.count'); x++) {
    let h = this.pano.get("hotspot[" + x + "]");
    h.visible = false;

    }


    and I made the hotspots not visible.
    But if cycle again and put them back to visibile, it doesn't work.
    I think I must force the view to redraw but I do not know how to do it.
    Any tips?
    Thanks in advance