Re: can someone please explain handles with bgt?

Think of handles as just different types of variables depending on the class you're working with.
You know how we work with strings, ints, and bools? It's like that with classes, such as the timer.
timer walktimer;
Let's say you want to convert the elapsed time of a timer into human readable time, that is minutes, seconds, etc, but you don't want to use a double for whatever reason.
Maybe you want to have a bool that will reset the timer if that bool is true.
string convert_time_to_human(timer @t, bool resetafter=true) {
string output;
int ms=t.elapsed;
//do your stuff for converting your time, and...
if(reset_after==true) t.restart();
return output;
}
If you have any more questions feel free to ask.

-- 
Audiogames-reflector mailing list
Audiogames-reflector@sabahattin-gucukoglu.com
https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
  • ... AudioGames . net Forum — Developers room : Zarvox via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : ivan_soto via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : pauliyobo via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : Zarvox via Audiogames-reflector

Reply via email to