The points stored in the usermeta table is the actual number of points that each user has for each points type. (Note that it is possible that this will be stored in its own table in the future.)
WordPoints does not calculate the number of points that a user has based on the points logs. That would make the plugin do a lot of work each time it wanted to know how many points a user has. It would make it very difficult to show a list of the users with the most points, for example. That is why the number of points each user has is stored in the usermeta table.
The number in the usermeta table is the one that WordPoints uses. The number of points is never calculated from the logs. In fact, it is possible that the number in usermeta would be a different amount from what you could calculate from the logs. This is because it is possible to modify a user’s points without logging the transaction, or delete a log without modifying the points. The plugin does not do either of these things, but they are possible.
So, there is a difference between the number in usermeta and the total you would calculate from the logs. Usually they will be same, but it is possible that sometimes they could be different.
My recommendation is this:
- You should do whatever you want to with the number from the logs.
- Your code should not break if there is a discrepancy between the logs and the users points.
- When there is a discrepancy, your code should just assume that it is intended. Just assume that something modified one of the values on purpose.
I hope that answers your question.