Quote:
|
Originally Posted by ZeroTrack
Ok i took them all out and assigned them to var's then set the string this is what happened
2. 0.035332 secs JagenTest
8. 0.006543 secs SernTest
-_- and i didnt initialize it yet
|
I have tested them both offline with similar setup and it shows yours faster than Jagens.
I do not know how accurate the CPU usage indicator in the offline debugger is.
I used the following scripts.
Jagen's Method:
PHP Code:
if (playerenters) {
timeout = 0.05;
}
if (timeout) {
this.temp = 23212613;
this.temp = this.temp / 60^2;
this.realhrs = int(this.temp);
this.temp = this.temp - this.realhrs;
this.temp *= 60;
this.realmin = int(this.temp);
this.temp = this.temp - this.realmin;
this.temp *= 60;
message H: #v(this.realhrs) M: #v(this.realmin) S: #v(this.temp);
timeout = 0.05;
}
~0.053-0.069 cpuusage
Sern's Method
PHP Code:
if (playerenters) {
timeout = 0.05;
}
if (timeout) {
this.temp = 23212613;
this.hours = int(this.temp/(60*60));
this.mins = int((this.temp/60)%60);
this.secs = int((this.temp)%60);
message #v(this.hours)H:#v(this.mins)M:#v(this.secs)S;
timeout = 0.05;
}
~0.043-0.048 cpuusage
Edit: I do not know why Sern's cpuusage is less.
This is offline. Scripts may be processed completely differently online.