ComGamer's Forum Posts

  • Like I mentioned, is most likely server side.

    Routers also have the ability to cache requests in some scenarios to save bandwidth, this may happen in a commercial or institutional setting, unlikely for home internet though.

    I'm at a home network, my router can't cache sites.

  • I tried everything to clear all data, but still Chrome keeps finding old files, for example an old version of c3runtime.js:

    - Deleted the sw.js and offline.json files from the server, to be sure Chrome doesn't save the app for offline use.

    - With Crome Dev Tools cleared all files in storage, cached-storage, ...

    - Cleared all browsing data, history, ...

    - Even changed the directory of the app on the server

    Reloaded with Ctrl+Shift+R, and still Chrome used old files that didn't exist anymore.

    But I've found the solution in the end: incognito-modus.

    + force a reload of the json file by adding ?t=" & random(1000) to the URL.

    Thank you all for your help!

    My working code:

    Wim

  • Lennaert,

    Thank you for your response.

    I started with one dictionary, but added a second one, just to be sure I don't display the data from the first dictionary. So I know yes.

    Wim

  • The caching doesn't seem the (only or main) reason. I discovered where to find the cached json-file (https://developer.chrome.com/docs/devtools/storage/cache/) and deleted the json-file (and even all the other cached files). But I still get the data from the old json file. Even after closing the tab and restarting the application. I still get the old data. This old data doesn't exist anymore at this point, so where is he getting this data??

    Wim

  • This tip of oosyrag about caching seems to get me a step along the way, but I'm not there yet.

    To avoid a cached result, JQuery doesn't seem necessary, adding a unique ID to the URL should be enough if I understand the following correctly. But unfortunately it doesn't work. I still get the same result.

    w3schools.com/js/js_ajax_http_send.asp:

    In the example above, you may get a cached result. To avoid this, add a unique ID to the URL:

    xhttp.open("GET", "demo_get.asp?t=" + Math.random());

    xhttp.send();

    So I tried:

    url":"\"https://www.mysite.be/testjson/MyDictionary.json?t=" & random(1000)"

    But with no effect on the caching.

    Wim

  • Hi,

    To test and finetune a lot of properties (different speeds, strengths, powers, ...) in my game I want to be able to change them while playing the game. All the values are in a dictionary, which is loaded from a json-file. I can host the game and the file on the same webserver (to prevent cross-domain problems which I have in preview mode) and change the values in the json-file on this server.

    But when I change the values and reload the json-file in the project, the data imported from the file isn't changed. Even if I reload (ctrl + F5) the gamepage, it still loads the old data that doesn't exist anymore.

    I made a new project with a simplified version of this problem:

    Any ideas to solve this?

    Thanks!

    Wim

    Tagged:

  • No problem :-),

    I tried it in Firefox but there are other styling problems.

    I think I have to live with the blue hover color.

    Thank you for your time!

    Wim

  • Thank you lennaert, but it doesn't work as expected.

    The background-color of the complete dropdown changes, not the background color of the item I'm pointing at, that is still blue.

    So still looking for the correct property.

    Wim

  • Thank you for your reaction, but I can't find out wich of these property names would change the color 'on hover'. I already use all the other properties.

  • Hi,

    Wich is the property name of the background-color on hover in a dropdown list (list plugin)? The standard color is blue, but I want to change it. I successfully changed font, color, ... with 'Set CSS style' so I know how to do this. Finding property names of common properties is no problem, but I can't find the property name of the background anywhere because it's not a standard property.

    Screenshot (I want to change the blue):

    i.imgur.com/lwXPRTs.png

    Screenshot of my code to change the style of the list:

    i.imgur.com/9Yim8Ne.png

    Thanks!

    Wim

    Tagged:

  • dop2000,

    Thank you very much! This is such a good and simple solution.

  • Hi,

    I want to change the animation of a sprite that is spawned as a particle, but this doesn't happen immediately.

    I've build a small test project to show the problem (also see screenshot below):

    https://github.com/WimDeBacker/WimDeBacker/blob/WimDeBacker-TestSpawnSprite/TestSpawnSprite.c3p

    Setting the particle object to the sprite is done immediately, but then changing the animation of the last spawned sprites doesn't work. The animation of the sprites that where spawned the previous mouseclick change like expected (become red in the example), but the last spawned sprites stay green.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Thank you very much! Both your solutions are almost the same now.

    Wim

  • Dear Maverick1912 and dop2000,

    Thank you for your answers!

    The method of Maveric1912 seems the best of the two answers to me.

    Maverick, do you have a .c3p file of upbeat-payne-96f97b.netlify.app ?

    In the solution of dop2000 recalculating the sectors for every possible angle seems very complex (e.g. every quadrant needs a completely different polygon)

    Thanks!

    Wim

  • The problem is that the DrawingCanvas object doesn't have an Arc-function. (I just added it to the feature requests.) That would probably be the easiest way, but isn't available for Construct3 (why??). It was available in Construct 2 and there's even a nice tutorial: https://www.construct.net/en/tutorials/draw-slices-dynamically-label-1295.

    Some requirements for the arc/pie:

    - Pixel-perfect alignment with backgroundpicture in the project.

    - The pie must change every second because it's a kind of clock.

    I tried:

    - iFrame and use the Arc function of the Canvas, but aligning the arc with the background picture and make this work on every platform and screen size seems to be very complex.

    - I thought that maybe by using scripting, I could get the context of the DrawingCanvas and use that to draw the arc, but 'GetContext' isn't available as a method of the Drawing Canvas Script Interface.

    Thanks!

    Wim

    Tagged: