system expressions

Get help using Construct 2

Post » Sun Oct 13, 2013 10:44 am

http://www.dwbailey.com/images/SquirrelNutsSaturday/

so play the gamee and collect a acorn then go to the hometreee to the left ..the acorn will take the value of the acorncounter
B
9
S
2
Posts: 272
Reputation: 1,632

Post » Sun Oct 13, 2013 10:46 am

That's only setting the text, not the variable itself.

use a system trigger once
add a line system set value Acornreturned to AcornReturned+Acorncount.
You could just set the text to "Acorn: "&Acornreturned
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Sun Oct 13, 2013 10:59 am

[QUOTE=LittleStain] set text: "AcornTotal: "&(acorncount+acornreturned)

[/QUOTE]

you were exactly right...i didnt define the acornreturn variable...

some reason i thought i was doing that by doing settext..arg....
thank you so much for helping me out here
B
9
S
2
Posts: 272
Reputation: 1,632

Post » Sun Oct 13, 2013 11:22 am

http://s93.photobucket.com/user/spawn85027/media/eventsheet_zpsa6951f8a.jpg.html

its not adding correctly..sometimes it doesnt add at all, not sure if it has to do with a timer, but i need the timer to happen so that the acorncounter resets after player collides with tree
B
9
S
2
Posts: 272
Reputation: 1,632

Post » Sun Oct 13, 2013 11:35 am

http://www.dwbailey.com/images/sq/

so if you play it..when you pick up a nut and return it to the tree it stays zero..but then if you pick up another one it starts to add it...and then keep on doing it, it starts adding it all wierd.
B
9
S
2
Posts: 272
Reputation: 1,632

Post » Sun Oct 13, 2013 11:47 am

remove the system every tick condition.

move the system set acorncount to above the set text field.
The order of events and actions can influence everything.
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Sun Oct 13, 2013 11:59 am

thanks littlestain, got it working perfectly now...it seems that i was over analyzing it...had to remove the waittime from the event sheet..it was actually hurting it...once i removed it..and collided with the home tree it worked great...
B
9
S
2
Posts: 272
Reputation: 1,632

Post » Sun Oct 13, 2013 12:09 pm

http://www.dwbailey.com/images/sqnuts/

heres the link of it working
B
9
S
2
Posts: 272
Reputation: 1,632

Post » Sun Oct 13, 2013 7:13 pm

make sure you press control to attack the nut bags.
B
9
S
2
Posts: 272
Reputation: 1,632

Previous

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 41 guests