Ok well I'm 10000000% sure this has been done already, and is very basic common knowledge, but I had to code it for part of my game and decided I might aswel release it as it may help others, it can't hurt to do that.
It's a good example for beginners learning how to use variables.
This coding is designed to keep a record of how long the player has played for. It also runs error checks to see if the seconds or minutes variables are above 60, and corrects them if they are.
This coding uses conditional branches within, conditional branches, so it doesn't have to constantly check several variables every time a second is counted.
This script uses Labels which can be used to jump to a certain part of coding in a single event. They are used to run a specific part of coding without the whole event being processed, and so can reduce lag in games.
This coding doesn't really require Labels, but if you don't know much about them, this will give you a basic idea.
Enjoy.
http://rapidshare.com/files/60239789/Recording_Play_Time.zip.html
It's a good example for beginners learning how to use variables.
This coding is designed to keep a record of how long the player has played for. It also runs error checks to see if the seconds or minutes variables are above 60, and corrects them if they are.
This coding uses conditional branches within, conditional branches, so it doesn't have to constantly check several variables every time a second is counted.
This script uses Labels which can be used to jump to a certain part of coding in a single event. They are used to run a specific part of coding without the whole event being processed, and so can reduce lag in games.
This coding doesn't really require Labels, but if you don't know much about them, this will give you a basic idea.
Enjoy.
http://rapidshare.com/files/60239789/Recording_Play_Time.zip.html