Icon modding refresh issues

Discussion in 'Mod Support' started by tatsujb, August 19, 2015.

  1. tatsujb

    tatsujb Post Master General

    Messages:
    12,902
    Likes Received:
    5,385
    Making mods for PA is utter torture. Lemme rephrase. Making icons mods for PA is utter torture.

    There is no "press F5" to see results.

    You gotta restart the damn game and generate a new system and start an new game (or reconnect) every damn little change you wanna test !

    and when you're trying to figure out what is mode down to the tiniest of criteria icons HAVE to be saved in to not end up blurry.... there are A LOT of things to test.

    Make icons and all the rest of the files currently non-refreshable ingame refreshable ingame.

    LIKE THE REST.

    FOR THE LOVE OF ALL THAT IS GOOD AND HOLY.

    (I'VE BEEN ASKING FOR THIS FOR TWO YEARS)
    Last edited: August 19, 2015
    Remy561 likes this.
  2. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    Try to reload the icons scene in the debugger via F5
    Also moving this to mod support and giving it a title that has meaning.
  3. wondible

    wondible Post Master General

    Messages:
    3,315
    Likes Received:
    2,089
    Atlases don't have pageIds to pass to the reload call.

    There is now an uncached:// url scheme that could be modded in, although it may still need a page refresh.
  4. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    You can reload them by opening the scene in the debugger and press F5 in the debugger.
  5. tatsujb

    tatsujb Post Master General

    Messages:
    12,902
    Likes Received:
    5,385
    what debugger? what scene? why is there no guide to this?

    Is this some kind of state secret?
  6. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
  7. tatsujb

    tatsujb Post Master General

    Messages:
    12,902
    Likes Received:
    5,385
  8. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    yeah finding sticky threads is hard indeed
  9. tatsujb

    tatsujb Post Master General

    Messages:
    12,902
    Likes Received:
    5,385
    I can't get it to work so far.

    I opened the debugger after starting up my game.

    I opened up the "live game" scene and pressed F5 but no change to my current changed icon.

    tried "special icon atlas" and a number of others as well.
  10. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    You need to open the icon atlas something scene. You can tell you have the right scene by looking at the html. The strategic icon scene has lots of images with the icons in it and when you hover over them in the debugger you will see it ingame.
  11. tatsujb

    tatsujb Post Master General

    Messages:
    12,902
    Likes Received:
    5,385
    I'm on the "icon atlas" scene as soon as it's opened all icons are with a grey transparent box over them.

    but I can't refresh them.
  12. wondible

    wondible Post Master General

    Messages:
    3,315
    Likes Received:
    2,089
    Ah... that works in Windows but not OS X.

    @tatsujb you are on Linux if I recall? Probably same issue.
  13. tatsujb

    tatsujb Post Master General

    Messages:
    12,902
    Likes Received:
    5,385
    currently on windows as a matter of fact.

    can't get it to work though.
  14. tatsujb

    tatsujb Post Master General

    Messages:
    12,902
    Likes Received:
    5,385
    it only works if you refresh "planetary Annihilation Main" but that send you back to the main menu.

    that doesn't make me gain any time.

    I want to be able to refresh icons ingame.
  15. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    Hmm.
    I tested and found that when I change an icon and reload the scene it removes all icons. Somethings seems to break and it doesnt show any icons at all anymore. The icons themselves in the scene are replaced though, but the renderer seems to not like it.

    It'll work though if you instead us js inside the scene to reload only the images, considering how it easily reacts to the mousehover effects of the debugger.
  16. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    $("img").each(function(elem){ $(this).attr("src", $(this).attr("src").split("?", 1)+"?r="+Math.random()) });

    Change the image and then run that javascript in the scene. That works fine for me.
    wondible likes this.
  17. tatsujb

    tatsujb Post Master General

    Messages:
    12,902
    Likes Received:
    5,385
    nice, where do I put this exactly?
  18. tatsujb

    tatsujb Post Master General

    Messages:
    12,902
    Likes Received:
    5,385
  19. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    in the console of the debugger of the icon atlas scene. Copy paste and enter

    [​IMG]
  20. wondible

    wondible Post Master General

    Messages:
    3,315
    Likes Received:
    2,089
    Ah, the good old fashioned cache buster. One less problem for composeable unit mods.

Share This Page