Reset layout and Score problem.

Looking to build a team or have a job to offer?

Post » Fri Mar 01, 2013 5:58 am

So i have a problem with my game, when im pressing "R" For restart it wont work, or .. it does restart but it dosen't restart my score instead it add score, it makes me kinda frustrated becouse in my eyes ive done right, but i dont know, here is some pictures of my first score and then the score after i pressed "R" and then all of my Score events

First


After


Event Sheet


I hope any one of you have any tips and fix :)
B
3
Posts: 3
Reputation: 431

Post » Fri Mar 01, 2013 1:34 pm

Firstly, a warm welcome to the C2 Forums.

Unfortunately, I don't think you will find much help in this section of the forums. I suggest you (or a moderator) move your message to the "Construct 2 General" section. This area is for people looking for jobs.

Next, nobody can understand what the three tiny images in your message mean; they are just too small. It would be better you either redo the images, or you provide a small part of your program that shows the problem. That way, somebody will be able to help you out.

Alternatively, search the forums on how to do debugging. I would recommend you check the plugins and install one so you can watch variables and see what is happening in the background.

Regards,
Gavin @ GamesWarp
=========================================
If you are on Linkedin, join other C2 professionals and network on the Scirra Construct 2 Developer Group at https://www.linkedin.com/groups?home=&gid=6732005
B
47
S
10
G
6
Posts: 193
Reputation: 7,604

Post » Tue May 14, 2013 1:51 pm

This might be a little late but, Ive encountered the same problem in the past and the present. If your going to restart the layout from within the layout use

SYSTEM:ON START OF LAYOUT:SET VALUE

And reset the values of the variables to 0 individually by name.

Hope this helps, worked for me
Image
B
71
S
22
G
2
Posts: 671
Reputation: 8,522

Post » Tue May 14, 2013 2:36 pm

Globals hold their value, on purpose, between layouts. If you need to reset your globals add action: Reset global variables
ImageImageImage
B
67
S
19
G
124
Posts: 3,214
Reputation: 74,415

Post » Tue May 14, 2013 4:52 pm

Here is what I do. I have never had any problems.

B
50
S
14
G
12
Posts: 813
Reputation: 16,764


Return to Job Offers and Team Requests

Who is online

Users browsing this forum: BackendFreak and 0 guests