Open bortkiewicz opened 8 years ago
How?
Like it stores data somewhere (mainly on the user's computer) to store the data for later use?
No, I understand that - I mean, how are we going to use cookies? How are we going to store data in the user's computer?
Forget that. Upload all of the data onto a repository on Github.
HELLO, @DerpfacePython ?
What? This issue is practically solved. Also, can you please style the page, @testitem? Thanks.
Is not solved! Oh, I styled the page already.
@testitem When I said styling - I meant style the actual game itself, not the page that holds the game. In fact, I don't think that extra bit at the top should even be there at all - this is meant to be a game, after all, not a webpage. Just fix up the styling of the actual game so that it looks better.
We can do cookies after we:
Hello, are you reading this, @testitem?
Yes, of course I am? I am still working on more upgrades
@testitem Like what?
Pretty much all the upgrades in P0.7 and upgrade hiding
I'm still trying to figure out how to include cookies (using js-cookie, which I'll include in the require
folder). Just an update.
It's easier when you read the entire Cookie Clicker source code because they use cookies to store data. Well, the source code is much too long for you to read it in a short amount of time.
I added js-cookie. Now i'm getting thoroughly annoyed that I have to import jc-cookie from main.js when they are in two different branched folders.
Yeah, js-cookie is great... but I just have no idea how it works.
Uh.. docs?
I just have no idea how to access the cookie itself with Cookie.get()
, do I declare it as a variable? Do I just call the function? What do I do?
well basically the readme animation says all.
Make a cookie: Cookie.set(name, value) Get the data: Cookie.get(name) Remove the cookie: Cookie.remove(name)
NO. No variable
just like that.
P.S. I need to eat breakfast now. Bye
Oh well just encode the data into a cookie.
i.e. <money>|<AC-s>|<AC-price>|<MP-s>|<MP-price>|<SC-s>|<SC-price>|<CC-s>|<CC-price>|<BH-s>|<BH-price>|<the-upgrades-purchased>
Does this use cookies to store the current stats and stuff?