Computer Science Canada Time.Elapsed |
Author: | Mr. T [ Sun May 29, 2005 12:27 pm ] |
Post subject: | Time.Elapsed |
is there a way to hault the Time.Elapsed from counting becuz..my scoring system bonus works on the amount of time u spend within a level. however, when the level is complete, a scoring chart appears...if u spend a long time in the scoring chart, the Time.Elapsed will still be counting milliseconds, and then u end up geting a negative bonus. please help. |
Author: | MysticVegeta [ Sun May 29, 2005 12:45 pm ] | ||
Post subject: | |||
This? |
Author: | Mr. T [ Sun May 29, 2005 12:52 pm ] | ||||
Post subject: | Alex's Opinion | ||||
I'm not sure if that would work...let me give u some code.
the problem is that this reset line
takes into affect before the game enters the next level...so the time is continually counting. |
Author: | Cervantes [ Sun May 29, 2005 2:50 pm ] |
Post subject: | |
Everytime you enter a new level, store the Time.Elapsed at that time into a variable. When you finish the level, use (Time.Elapsed - the_time_variable_from_the_start_of_the_level) to determine the score. |