Use the In-Game Community Mods - Original PA Mod Manager (PAMM) is Obsolete

Discussion in 'Released Mods' started by Raevn, August 17, 2013.

Thread Status:
Not open for further replies.
  1. Quitch

    Quitch Post Master General

    Messages:
    5,884
    Likes Received:
    6,045
  2. Quitch

    Quitch Post Master General

    Messages:
    5,884
    Likes Received:
    6,045
    Actually, on a serious note the display will get a little cluttered as I add more and more. While for already installed stuff you could remove the option (or grey it out), for new mods installed through PAMM it must surely know what files exist and be able to remove them?
  3. Raevn

    Raevn Moderator Alumni

    Messages:
    4,226
    Likes Received:
    4,324
    Installation is simply extraction of the contents of a zip file, there's no intrinsic list of files.
  4. Quitch

    Quitch Post Master General

    Messages:
    5,884
    Likes Received:
    6,045
    But PAMM could output the extraction to a log file it could read from, right?
  5. ViolentMind

    ViolentMind Active Member

    Messages:
    394
    Likes Received:
    186
    OK, even after the uninstall, it's still doing the same thing. This sucks because now I can't see whatever is on the bottom of the list for each tab. Never seen anything like this before. What would be cutting off the last portion of only the contents of this window?
  6. LavaSnake

    LavaSnake Post Master General

    Messages:
    1,620
    Likes Received:
    691
    @raevn
    Could you add my timers mod to the news file? I finally got around to uploading it to the Github repo but the news file isn't on there. Thanks!
    Raevn likes this.
  7. dfanz0r

    dfanz0r Active Member

    Messages:
    150
    Likes Received:
    47
    So earlier i had an idea about making a small modification for the ui_mod_list.js so the mods get loaded from a json file. Instead of currently being stored inside javascript code.

    This has advantages being its easier to load save and modify data, possibly simplifying code in mod managers.

    Here is a quick this i put together if anyone really cares. It only really useful if raevn decides to add support in this mod manager for it. Which is quite possible for him do do as long as the .hta is running on a windows install with IE8+.

    https://dl.dropboxusercontent.com/u/37405488/ui_mod_list.zip

    edit:

    After looking into it a bit would be easy to get rid of the ui_mod_list.js completely if one was to modify common.js (media/ui/alpha/js/common.js) add in loadJSON function or w/e and the replace the loadScript for it with loadJSON then add in the lines.

    Also it has occured to me. If the mod ini files were in json instead of as they are now. you would no longer need the rModsList variable for the rModsList mod, you could just load the json configuration files directly. It might even allow you have have an in-game mod manager that could toggle mods in-game.
    Last edited: December 8, 2013
  8. Raevn

    Raevn Moderator Alumni

    Messages:
    4,226
    Likes Received:
    4,324
    At work at the moment, I'll take a look tonight. Sounds interesting!

    This is more or less what I had an idea of in my earlier post :)
  9. dfanz0r

    dfanz0r Active Member

    Messages:
    150
    Likes Received:
    47
    Have been looking into it, there doesn't seem to really be a way to save file with javascript. So yeah the in-game mod manager would really only be good for disabling a certain mod for a bit or enabling one you want for a certain game or w/e.
  10. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    You can store the mod list json in the localstorage just fine. The settings work the same way.
    cptconundrum likes this.
  11. dfanz0r

    dfanz0r Active Member

    Messages:
    150
    Likes Received:
    47
    I guess that could work but mods couldn't be installed as they are currently.(Unless we want to store those there too) So an external mod manager will still probably be needed. So are there anyways of accessing the local storage from outside of a browser?
  12. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    Well it is some sqlite file stored somewhere in the home directory of the user. Never tried to do anything with it so far.
    As an alternative we could just not download the mod files and instead use direct links to the files on github. That way we dont need to install any mods locally. However that would suck once the server is released and some people try to play offline.

    EDIT:
    Also I think at least it would be worth a try to actually really store everything into the localstorage.
    I had that plan for a while with PA Stats, but since PA Stats needs a connection to the server anyway I decided against it.
    cptconundrum likes this.
  13. proeleert

    proeleert Post Master General

    Messages:
    1,681
    Likes Received:
    1,656
    I thought localstorage was limited to 2.5 MB.
    So that would limit the possibilities right ?
  14. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    It is? Oh well, that's not too much.
    Plenty for simple mods without images though.
    cptconundrum likes this.
  15. dfanz0r

    dfanz0r Active Member

    Messages:
    150
    Likes Received:
    47
    The mod changes, coming tomorrow should be interesting.
  16. Raevn

    Raevn Moderator Alumni

    Messages:
    4,226
    Likes Received:
    4,324
    It looks like the following will need to change in PAMM:
    • Extract/read mods in new mods folder (simple)
    • Generate mods.json file (not too hard)
    It's not too clear what happens with ui_mod_list.js :/. It will continue working where it is for now though (even after the update, according to chargrove), so I guess it's wait and see.
  17. proeleert

    proeleert Post Master General

    Messages:
    1,681
    Likes Received:
    1,656
    so the ini file is gone and going to be modinfo.json
  18. Raevn

    Raevn Moderator Alumni

    Messages:
    4,226
    Likes Received:
    4,324
    No; they are both needed for different types of mods. The new system (modinfo.json) is currently only for mods that replace files, it doesn't deal with the current UI hooking system in place (which uses ui_mod_list.js). My guess is they will be integrated at some point, but not at this stage.
  19. proeleert

    proeleert Post Master General

    Messages:
    1,681
    Likes Received:
    1,656
    Yes too bad we need still fill in the ui_mod_list.js

    It should be like this in future
    docnsettings/pa/mods/mymod/modinfo.json
    docnsettings/pa/mods/mymod/ui/mods/live_game/live_game.js (no shadow cause in mods)
    docnsettings/pa/mods/mymod/ui/mods/live_game/custom.js (just another file)
    docnsettings/pa/mods/mymod/ui/mods/live_game/custom.css
    docnsettings/pa/mods/mymod/ui/mods/some.jpg
    docnsettings/pa/mods/mymod/ui/mods/settings/settings.js
    docnsettings/pa/mods/mymod/ui/alpha/live_game/live_game.js (shadow cause in alpha)
    docnsettings/pa/mods/mods.json

    so basically based on the path it should be able to fill in the ui_mod_list.js

    I think it's possible now but everybody should then stick to these folder based rules.
    So then we don't need ini file and you can create ui_mod_list.js based on mod folder structure
  20. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    As long as we keep the mod list array and we keep a way to load files from servers I am fine with it.
    cptconundrum likes this.
Thread Status:
Not open for further replies.

Share This Page