The problem is clearly not with the javascript. Here's a quick snippet to show you the working of the code.
document.getElementById('points').value = 100;
As you can see, the javascript perfectly assigns the new value to the input element. It would be helpful if you could elaborate more on the issue.