Adding, subtracting, randomizing help

So I have a stat (meat) that can’t go higher than 20. Excess meat is supposed to go into an exmeat variable, set the meat to 20, then take anything from the exmeat to mpile (meat pile).

I can take whatever exmeat is and add it to mpile, but getting exmeat to be whatever is left over from meat is confusing me.


meat 15
You skin the animal and get some extra meat.
meat 25

Unfortunately you have too much, so you move the excess meat into a pile on a pair of large leaves.

This is where I’m having issues.

I am also having an issue I never had an issue with until now. I can’t add random variables. Last year or maybe the year (I have been sort of working since then, but had to take a break for awhile due to health) before I could have

wood 4
*rand wood 4 6
wood 9

But now wood will be between 4 & 6.

1 Like

The first thing:

*if (meat > 20)
	*set exmeat (meat - 20)
	*set meat - exmeat

*set mpile + exmeat

The second thing, you should use a different variable other than wood. Like, newwood, then:

*rand newwood 4 6
*set wood + newwood

I think I need to take a break tomorrow XD my brain must be burnt out not to think of the rand thing.

But thank you for the first thing especially. I didn’t think about the (meat- 20) thing at all.

This topic was automatically closed 24 hours after the last reply. If you want to reopen your WiP, contact the moderators.