I have a piece of code that starts a timer based on fps and I need a script that will allow me to trigger this to start/stop using a collision:
var DragRace = pc.createScript('dragRace');
DragRace.prototype.initialize = function() {
this.time = 0;
};
DragRace.prototype.update = function(dt) {
this.time++;
var time = this.time ;
this.entity.element.text = time;