Floofy Posted September 28, 2011 Report Share Posted September 28, 2011 I'm sure somebody's got this down to a science and has 50+ examples, The only thing I need to finish my engine is a timer, not just a counter that goes up, I already have that. The problem is when I die and respawn at my checkpoint, the timer is back to zero. this presents a problem as a competent player could simply die after touching the checkpoint nearest to the goal, and rack up a huge time bonus. Any examples/explanations would finish this engine. Link to comment Share on other sites More sharing options...
DimensionWarped Posted September 28, 2011 Report Share Posted September 28, 2011 Sonic Worlds already has checkpoints and a persistent timer that saves the time you hit them. But if you just dropped this in the wrong forum or something, I'd suggest you consider using either an object with global scope to store the time the checkpoint was reached numerically and load that at the start of the level/reset it on gameover or when the level is finished, or you use a global variable to do pretty much the same thing. Link to comment Share on other sites More sharing options...
Floofy Posted September 28, 2011 Author Report Share Posted September 28, 2011 I'm sorry, I just checked SW delta 1.2b and the timer still resets... The score is consistent, yet the time is not. am I missing a plugin? Link to comment Share on other sites More sharing options...
DimensionWarped Posted September 28, 2011 Report Share Posted September 28, 2011 Eh, it's possible I was just incorrect. I'll have a look tomorrow. Link to comment Share on other sites More sharing options...
Floofy Posted September 28, 2011 Author Report Share Posted September 28, 2011 Eh, it's possible I was just incorrect. I'll have a look tomorrow. k Link to comment Share on other sites More sharing options...
luksamuk Posted September 28, 2011 Report Share Posted September 28, 2011 Noticed this too. This should be fixeable through saving the timer for when the frame restarts. All you have to do is save it in a Global Value in case of death (unless if it's a Time Over), and load it again in the start of frame. Make sure to set this Global Value that stores the timer value to 0 in case of death by Time Over or in case you finish the level. (I am talking about Sonic Worlds. If you're not using Sonic Worlds, just make the level timer in a global value and remember to reset it in the cases I said above.) Link to comment Share on other sites More sharing options...
Floofy Posted September 29, 2011 Author Report Share Posted September 29, 2011 Noticed this too.This should be fixeable through saving the timer for when the frame restarts. All you have to do is save it in a Global Value in case of death (unless if it's a Time Over), and load it again in the start of frame. Make sure to set this Global Value that stores the timer value to 0 in case of death by Time Over or in case you finish the level. (I am talking about Sonic Worlds. If you're not using Sonic Worlds, just make the level timer in a global value and remember to reset it in the cases I said above.) I'm adding on to Blazefire's 06 engine which is based off of worlds. I've tried fiddling around with global values but nothing seems to be working... at all... Here's the MFA What am I doing wrong? Link to comment Share on other sites More sharing options...
luksamuk Posted September 29, 2011 Report Share Posted September 29, 2011 One hint:Don't directly post your engines here, in order to avoid future "headaches" for you. I didn't really lok for your code, but here's what you should do. You see the even in the green square? That's me, saving the value "Game Timer" to a Global Value Z, when you touch the checkpoint. When you respawn, just make the "Game Timer" value be the same of Global Value Z. If you die by Time Over or go to another level, make sure to make Global Value Z reset to 0. EDIT: Bigger image: 1 Link to comment Share on other sites More sharing options...
Floofy Posted September 29, 2011 Author Report Share Posted September 29, 2011 One hint:Don't directly post your engines here, in order to avoid future "headaches" for you. This engine may not look it, but it's is far from complete according to my testers emails today. I wouldn't post a newly completed engine before the game is done. Anywho, you're a lifesaver, I've upped your rep, and will be implementing this ASAP. You too winnie, you've been the first response for all of my help topics. Link to comment Share on other sites More sharing options...
luksamuk Posted September 29, 2011 Report Share Posted September 29, 2011 Thank God you're conscius about that, then :B Anytime you need, bro. If you have more trouble, just gimme the word. Thanks for the rep. Link to comment Share on other sites More sharing options...
Recommended Posts