Web Tech II Class 06 Javascript animation and gameplay

Web Tech II  Class 06 Javascript animation and gameplayShort Description
that sort of an approach is that it allows for animation to be created via javascript. That can be used in order to create unique …

Website: www.purplestatic.com | Filesize: 77kb

Content
Web Tech II - Class 06: Javascript animation and gameplay
J. Adrian Herbez - purplestatic@yahoo.com
Sometimes you might find that you want to have a javascript function happen every so often. There are various reasons that you
might want to do that (redirect a user to another site after a certain amount of time, for example), but one of the great things about
that sort of an approach is that it allows for animation to be created via javascript. That can be used in order to create unique
interfaces or even full-on games.
Using the timer
Usually, javascript executes in response to a user event, such as a mouse click or a mouse over. It can also be called by forms,
and when a page loads. However, you can also tell a given function to run itself a set time from the present. To do that, you need
to use the setTimeout() function, which takes two arugments:
1) the function (or line of code) to run
2) the number of milliseconds (1000 millliseconds = 1 second)
So, if you had a function named myDelay() and you wanted it to happen 3 seconds from some…

Get the file Download here

AddThis Social Bookmark Button
Related Books:
  • JavaScript Animation
  • Active Legends For Interactive Cartographic Animation
  • HTML Concepts Glossary
  • JavaScript Programming A detailed look at some Javascript …
  • A Unified Security Model for Web Applications
  • Adobe Acrobat 3D Controlling Animations
  • AutoCAD Tutorial
  • Lesson 7-Animation

  • Related Searches: , , , ,



    Comments

    Leave a Reply