Holding button and adding score per sec

Hi and Merry Christmas. Im making a mobile game im totally beginner and i need help. How write a script. When button(not on keyboard) is hold that increase a score(+0,5 per frame), next that score change for money

hey , watch this ,it’s not very nice,but it could help :).


also you can change it to this ,so when you’re not pushing the button,the script will be disabled .

public void addingScore(){
	enabled = true;


public void dontAddScore(){
	addScorrreee = false;
	enabled = false;