local key exists not appearing?

Just started using Construct 2? Post your questions here

Post » Tue Nov 03, 2015 5:06 pm

This has been doing my head in all day, I'm trying to add a highscore save function and I need to use "local key exists" when the layout has been started to check for the highscore.

But after 3 -4 hours of trying, the command will not apppear for me?

Heres a pic (remove the spaces to see it)
h t t p ://s21.postimg. org/ld77y20fb/help.jpg

I have a highscore tutorial capx and when I try to select "local key exists" as a condition in that, it shows!! but in mine it doesnt.

Am I doing something dumb or is this a bug? (I suspect the former but I cannot fathom out why its not working)
B
6
S
1
Posts: 73
Reputation: 556

Post » Tue Nov 03, 2015 6:04 pm

I'm guessing you are either looking for "local storage item exists" or following a tutorial that covers the depricated webstorage-object..

If the first is true, it should be a seperate event, because a triggered event cannot be a subevent of a triggered event..
If the second is true, please look for a tutorial about local storage..
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 » Tue Nov 03, 2015 6:33 pm

What's the tutorial?

There are a lot of these save game tutorials and examples on here that unfortunately are using the - now deprecated - webstorage object. Swapping the method for the new localstorage object shouldn't be too difficult.
If your vision so exceeds your ability, then look to something closer.
Moderator
B
131
S
29
G
81
Posts: 5,328
Reputation: 56,630

Post » Tue Nov 03, 2015 8:20 pm

zenox98 wrote:What's the tutorial?

There are a lot of these save game tutorials and examples on here that unfortunately are using the - now deprecated - webstorage object. Swapping the method for the new localstorage object shouldn't be too difficult.


Here it is h t t p ://expirebox.com/download/a11c58f073636d4bf538a59d54a1b62d.html
(remove the spaces)

its not in english but the event sheet is english
B
6
S
1
Posts: 73
Reputation: 556

Post » Tue Nov 03, 2015 8:21 pm

LittleStain wrote:I'm guessing you are either looking for "local storage item exists" or following a tutorial that covers the depricated webstorage-object..

If the first is true, it should be a seperate event, because a triggered event cannot be a subevent of a triggered event..
If the second is true, please look for a tutorial about local storage..



aha.. yes the second seems to be true, I'm sorry about that. my fault for being dim.
B
6
S
1
Posts: 73
Reputation: 556

Post » Tue Nov 03, 2015 8:33 pm

Hardly your fault. Many of the examples and tutorials need updating to replace webstorage with localstorage.
If your vision so exceeds your ability, then look to something closer.
Moderator
B
131
S
29
G
81
Posts: 5,328
Reputation: 56,630

Post » Tue Nov 03, 2015 11:20 pm

Message: OldieSteve can only post plain text URLS until they have 500 rep. 1 URLS modified. Why?
I really don't want to start another thread today (I'm very careful about spamming) but I have an issue thats bugging me. I cannot seem to find the right way to trigger my game over text. I tried using "is physics sleeping" as the manual suggested (or my interpretation of it) but that doesn't quite work.

I have a capx here for you to have a peek at.

h t t p://expirebox. com/download/1590e9673ea346d8ee10e3b1b587c5d3.html
(remove the spaces)
B
6
S
1
Posts: 73
Reputation: 556

Post » Wed Nov 04, 2015 7:38 am

For some reason I cannot download from that site without disabling lots of my security blocking addons :/

Usually, for game over triggers etc, I would use Global variables, so that for instance, when Lives < 0 Set 'GameOver' = 1.

Then in another part of the program - I would use a different Event sheet, as I find just adding and removing bits easier if they are on their own Event sheet - you would just have a single check for the Global 'GameOver' = 1 and go to your game over Layout or display GameOver text routine.

Is this the type of thing you mean?
If your vision so exceeds your ability, then look to something closer.
Moderator
B
131
S
29
G
81
Posts: 5,328
Reputation: 56,630

Post » Wed Nov 04, 2015 11:40 am

Not really, its a ball game where you drop balls into slots and score points, I want to trigger game over when:-

a: your remaining balls = 0
and
b: all the balls have stopped moving

I'm sorry about that site, thats scary. either my security is lacking or adblock filtered it out somehow. I'll see if I can find another place to upload it.

Edit:- perhaps try this h t t p ://www100.zippyshare. com/v/YMnHeLGj/file.html

if thats still a problem I'll have to do some research into what filehost to use. :)
B
6
S
1
Posts: 73
Reputation: 556


Return to Beginner's Questions

Who is online

Users browsing this forum: ksiads and 0 guests