How do I add up the value of variables overlapping a object

Get help using Construct 2

Post » Wed Dec 07, 2016 6:14 pm

It dosent work is says "Value is not an expression or instance variable of money"
B
5
Posts: 13
Reputation: 251

Post » Thu Dec 08, 2016 12:08 am

Well did you add the instance variable to the family?
You need an instance variable for the family which you will use to calculate the values.
"We can't solve problems by using the same kind of thinking we used when we created them."
- Albert Einstein
B
27
S
11
G
8
Posts: 528
Reputation: 7,091

Post » Thu Dec 08, 2016 1:15 pm

single sprite solution

dropChips.capx
B
66
S
24
G
7
Posts: 1,515
Reputation: 11,041

Post » Sat Dec 10, 2016 3:57 pm

but if i want to double all of the money overlapping the pot how do i do that?
B
5
Posts: 13
Reputation: 251

Post » Sat Dec 10, 2016 4:24 pm

You simply add a "*2" at the end of the calculation.
Or, after the calculation you set the text of the pot to "int(Self.Text) *2"
"We can't solve problems by using the same kind of thinking we used when we created them."
- Albert Einstein
B
27
S
11
G
8
Posts: 528
Reputation: 7,091

Post » Sun Dec 11, 2016 4:27 pm

Thanks but I dont mean the worth of the money but the actual money so instead of 5 coins it is 10 coins
B
5
Posts: 13
Reputation: 251

Previous

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 43 guests