Page 1 of 1

Time Trials and Better Leveltimers!

Posted: Sun Aug 06, 2017 5:43 pm
by PixelPest
Here's two Beta 4 APIs, one of which is basically leveltimer.lua on steroids and one which allows easy time trial integration into levels and episodes.

Image

Clock.lua
Documentation: http://wohlsoft.ru/pgewiki/Clock.lua
Features:
  • Very easy-to-use stopwatch and countdown timers
  • Tons of customizability
  • Multiple default settings
  • Trigger events when a timer runs out
  • Everything leveltimer.lua has and more!
TimeTrial.lua
Documentation: http://wohlsoft.ru/pgewiki/TimeTrial.lua
Features:
  • Used with clock.lua to create a full time trial system with one extra call
  • Tons of customizability
  • Default graphics for medals
  • Set times simply using a text file
  • Saves and can clear best scores
  • And more!
Download (includes both as well as a demo level): https://www.dropbox.com/s/8fqgib82i5176 ... a.zip?dl=0

At this point the documentations are not complete on the PGE Wiki however for clock.lua there is an extensive documentation in the file and the example level helps explain timeTrial.lua as well.

Enjoy!

Re: Time Trials and Better Leveltimers!

Posted: Sun Aug 06, 2017 6:31 pm
by superfido2
This would go great with time based rewards in episodes. Can't wait for beta 4 so we can use these.

Re: Time Trials and Better Leveltimers!

Posted: Sun Aug 06, 2017 6:33 pm
by PixelPest
superfido2 wrote:Can't wait for beta 4 so we can use these.
Feel free to use them now

Re: Time Trials and Better Leveltimers!

Posted: Mon Aug 07, 2017 2:09 am
by MECHDRAGON777
So I this an edited version of: viewtopic.php?f=87&t=13088#p195538 ?

Re: Time Trials and Better Leveltimers!

Posted: Mon Aug 07, 2017 7:45 am
by PixelPest
MECHDRAGON777 wrote:So I this an edited version of: viewtopic.php?f=87&t=13088#p195538 ?
It's barely related and uses none of the same code

Re: Time Trials and Better Leveltimers!

Posted: Mon Aug 07, 2017 4:51 pm
by ElectriKong
So where is the documentation within the files?

Re: Time Trials and Better Leveltimers!

Posted: Mon Aug 07, 2017 8:02 pm
by PixelPest
Electriking wrote:So where is the documentation within the files?
The top of the file of clock.lua