Quantcast
Channel: Help! with 2.0 - Twine Forum
Viewing all articles
Browse latest Browse all 1844

Can You Multiply A Variable?

$
0
0
I am using Harlowe to make a game. Basically, part of the game is farming to get food. Every time you go to the farm, the seeds you have collected turn into food, and boost your hunger bar. Here's the code:
(set: $hunger to $hunger + $seeds)(set: $seeds to 0)

But the problem is, is that I would like the player to upgrade their farm. So if I set a variable called '$upgrade', it would times the amount of food you get by the upgrade.
(set: $hunger to $hunger + $seeds)(set: $hunger to $hunger x $upgrade)(set: $seeds to 0)

However, I can't figure out how to multiply. If there is a way, please tell me, but if there isn't, could you suggest improvements?

Viewing all articles
Browse latest Browse all 1844

Trending Articles