We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.

how to stop the tween camera event mid flow

Home Forums Puzzles how to stop the tween camera event mid flow

Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #28269
    Avatarjaspixel
    Newbie

    Hi,

    Hoping this is my last question for now (as am sure you are :).I have nearly finished this demo I have put together and if I can up-sell it to my client I will be ready to buy a freelance license.

    I’m just trying to find a way to stop the tween camera animation process which switches between multiple camera positions, when I click anywhere on the screen or on any object/button.

    I have tried adding stop animation on click event, but with no success.

    I also saw on the forums in other discussions that setting the camera in my blender scene to be parented to the target objects for each cameras key position may or may not be necessary? I am unsure which to do for this scenario.

    Please see screen grab attached.

    Many thanks,

    Jas :)

    Attachments:
    You must be logged in to view attached files.
    #28290
    Yuri KovelenovYuri Kovelenov
    Developer

    you can probably have a second non-animated camera that you can snap to the animated camera and switch to.

    3D Verger, the CEO
    LinkedIn | FB | Twitter | VK | 新浪微博

    #28291
    Avatarjaspixel
    Newbie

    Thanks Yuri, but not sure I understand how to implement what you describe :scratch:

    If, as you suggest, I use another camera to jump to when I want to stop the camera tween process from running to multiple camera positions, which puzzles should I use to break the cycle and jump to the new camera please?

    I was looking for a way to assign an id to the tween camera puzzle setup, then I could use the stop or pause animation puzzle to halt it, but not obvious how I would do that if it could be an easier method?

    Also, would be great in future version of verge to be able to type search at the top of the puzzle list to find puzzle options/solutions quicker, but also help find puzzles we may not easily find or know about without trawling through the whole list looking for inspiration of the next puzzle to try. Good for newbies like me at least I believe.

    Many thanks again,

    Jas

    #28354
    Avatarjaspixel
    Newbie

    Hi Yuri,

    Apologies to bug you on this, but wondered if I am close with this solution please.

    See screen grab of the puzzle I think will solve my issues above if I can just finish it off.

    If I use the event “when clicked” I can set the “if missed” option to stop the multiple camera tweening.

    However, I cannot work out how to assign an html button id named “play-world” in my html file and turn it into an object that I can slot into the “when clicked” puzzle at the top.

    You can see the html puzzles I have had a play with (attached), but no combination seems to make the “when clicked” command work when I click on the html button in the viewer.

    I tried using the other Html “on event of ‘click'”, but it does not have the “if” missed option, because there is no “if missed option” like the Event “when clicked” option. Unless there is a workaround for this too?

    Any suggestion how I can make my html id into an object recognised in the “when clicked” and I think I am there.

    Many thanks, :bye:

    Jas

    Attachments:
    You must be logged in to view attached files.
    #28367

    You need to use only Html when clicked puzzles with HTML buttons not a simple when click puzzle, because it works only with meshs on the scene not with HTML elements. To create an action for missed click you just simply can create a When Click event on main container or body and put all missed actions there.

    Co-founder and lead graphics specialist at Soft8Soft. Blender only and forever!

    #28371
    Avatarjaspixel
    Newbie

    Ah, ok thanks for the tip Mikhail.

    Is there an equivalent for the “if missed” puzzle I can create with the HTML “on event of” option please.

    I just need to stop the camera moving when the user clicks anywhere else on the screen than the html button.

    Many thanks,

    Jas

    #28372

    Is there an equivalent for the “if missed” puzzle I can create with the HTML “on event of” option please.

    No. As I said before you need just to create a Event on Click on Body or Document element this will work when you miss and html button.

    Co-founder and lead graphics specialist at Soft8Soft. Blender only and forever!

    #28373
    Avatarjaspixel
    Newbie

    Ok, I’ve got it now, thanks.

    Here is how to do it if any use to anyone else in future.

    Thanks again.

    Jas

    Attachments:
    You must be logged in to view attached files.
    #28384
    Avatarjaspixel
    Newbie

    Hmm, I spoke too soon, my last post idea almost works. Just realised the camera tweens only jump between the first and second camera tweens. Shame, because all other functions work as expected. It never goes to the 3rd, 4th or 5th camera in the list within the timer.

    Will try and figure a way with the On event on click with body as you suggest.
    :scratch:

    #28386
    Avatarjaspixel
    Newbie

    Ok, so I tried the on event method with body and document and while I can get it to jump to another camera, it always reverts back to the multiple tweening cameras which continue jumping to one after the other on a loop.

    Using animation stop and pause also have no effect on the multiple camera tweens, whether I place them in a procedure or not.

    I just don’t understand why, when using the timer puzzle with multiple tween camera puzzles, it only plays between the first two cameras? If the timer puzzle played the whole list, then the problem would be solved easily.

    Am I missing something (apart from a useful brain :wacko: ) as to why the timer doesn’t allow multiple tween cameras please as shown in my previous screen grab?

    Many thanks again, I’m starting to feel like a pain, but am so close to finishing this now I promise :good:

    Jas

    #28409

    Removeing timer doesn’t mean removing action that he run. You need to add a viriable that will be changed from tru to false on click on body and document and before each tween starts you need to add a check of thet viriable is it true or false in if yes it’s tru then run if not then do nothing. That can help to stop the camera movement.

    Co-founder and lead graphics specialist at Soft8Soft. Blender only and forever!

    #28478
    GlifTekGlifTek
    Licensee

    When doing debugging/dev in the 3D scene, I always have a “cut” key, where a make change to camera based off an HTML puzzle “on key” input and make it so if I hit num pad “-” , it switches to a free orbital camera.

    You can do this with what you’re talking about with using the “HTML on event ” puzzle.

    Also, I’m pretty sure you’re talking about my post about animating cameras.

    If you’re not completely knowledgeable about the details of how most things work here yet…

    I’d suggest you animate your camera movement in your 3d package, then you have access to its frames.

    When you do that, you can just have a constant IF puzzle that contains your playing the camera animation when a variable is true and have it stop and go to your other camera when a variable is false.

    #28587
    Avatarjaspixel
    Newbie

    Thanks Mikhail,

    Using the variables was the missing part of the jigsaw (or puzzle :) ) for me.

    Appreciate your solution suggestion too Gliftek, thank you. I have other animation elements going on, so would have been fiddly too.

    I have attached a screen grab of my puzzles to help anyone else in the future.

    Many thanks for all your help.

    Have sent my demo to the client, so lets hope he likes the idea now after all this work :wacko:

    Attachments:
    You must be logged in to view attached files.
Viewing 13 posts - 1 through 13 (of 13 total)
  • You must be logged in to reply to this topic.