Shahzaib 3d Customizer

Need help in clock fuction i have added the code in my web app but not working like watch

Recommended Posts

i have issue in 3d analog clock i have export 3d watch from blender everything done just need to work on clock function my  also fucntion is also done but its not working like clock please check the video and help me out  

and i have this code for  clock function all Object piviot point is center but clock function not working perfectly please Check and help me out please   

 

    scene.registerBeforeRender(function () {
 
         var date = new Date();
        var hour = date.getHours() % 12; 
        var minute = date.getMinutes() ; 
        var second = date.getSeconds() ; 
        hand_sec.rotation.y = (second/60.)*minute.*Math.PI/180.;
 hand_min.rotation.y = (minute/60.)*360.*Math.PI/180.;
 hand_hour.rotation.y = (hour/12.)*360.*Math.PI/180.;

    
            });   // this is code i have add  but not working 
 

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.