So I am trying to enter a new data file for AMP Year 1.
One of the concepts is that you have really three resource pools.
SP - Skill points
LP - Loyalty points
BP - Bonus points
So when you purchase a skill, it can come from SPs normally, but if you run out, you can use BPs as well.
Here is the code I was using:
~First is cost of 2
if (field[trtUser].value > 8) then
if (#resleft[resCP] < 2) then
hero.child[resBP].field[resSpent].value += (field[trtUser].value * 2) - 8
else
hero.child[resCP].field[resSpent].value += (field[trtUser].value * 2) - 8
endif
~Here are skills costing 1
else
if (#resleft[resCP] < 1) then
hero.child[resBP].field[resSpent].value += field[trtUser].value
else
hero.child[resCP].field[resSpent].value += field[trtUser].value
endif
endif
The behavior is that it always pulls out of the BP pool.
So the first question is why is the macro always testing to 0?
The second question is more complicated. I came to the realization that it is just calculating the value and not incrementing the resource variable. So is there a way to track values based on how I spend points? I realize my code does not do that, but I'm still considering how to implement it.
One of the concepts is that you have really three resource pools.
SP - Skill points
LP - Loyalty points
BP - Bonus points
So when you purchase a skill, it can come from SPs normally, but if you run out, you can use BPs as well.
Here is the code I was using:
~First is cost of 2
if (field[trtUser].value > 8) then
if (#resleft[resCP] < 2) then
hero.child[resBP].field[resSpent].value += (field[trtUser].value * 2) - 8
else
hero.child[resCP].field[resSpent].value += (field[trtUser].value * 2) - 8
endif
~Here are skills costing 1
else
if (#resleft[resCP] < 1) then
hero.child[resBP].field[resSpent].value += field[trtUser].value
else
hero.child[resCP].field[resSpent].value += field[trtUser].value
endif
endif
The behavior is that it always pulls out of the BP pool.
So the first question is why is the macro always testing to 0?
The second question is more complicated. I came to the realization that it is just calculating the value and not incrementing the resource variable. So is there a way to track values based on how I spend points? I realize my code does not do that, but I'm still considering how to implement it.