STAR TREK 2d20
Page 1 of 2 12 Last
  1. #1

    Directly edit .pak files.

    For many of you, I'm sure you've encountered the same frustration I did when working on custom rulesets; that is having to change the .pak file to a .zip, edit the files and the change it back. That gets really trying, really fast. Fortunately, in Windows, that's easy to fix. Friendly warning before you try this, editing registry files can TOTALLY fubar your system if you don't know what you're doing. Make sure, for example, that you don't have other programs that use the file extension .pak.

    Anyway, it's a simple registry hack. You just need to make windows recognize .pak files as compressed folders. All you need to do is run CMD as Administrator (Programs->Accessories, the right click command prompt and select Run as Administrator).

    reg copy HKEY_CLASSES_ROOT\.zip HKEY_CLASSES_ROOT\.pak /s /f
    After this is done, the file will be treated as a normal .zip file, and you can explore or replace files as needed (Remember that you can't edit the files directly unless it's supported by your xml editor. AltovaXML Spy handles this, wonderfully).

  2. #2
    Valarian's Avatar
    Join Date
    Mar 2007
    Location
    Worcestershire, UK
    Posts
    2,567
    Or you can unzip the .pak file and use a folder instead. Fantasy Grounds will use the unzipped folder, so you can work on the files and then rezip once you've finished development. Just rename the .pak to .zip before you start. This avoids two references to your ruleset in the rulesets folder. Once you're done, rezip from inside the folder (at the base.xml level) and rename the .zip to .pak. Then move the .pak file to the parent rulesets folder, and remove your work folder.
    Using Ultimate license - that means anyone can play.
    Valarian's Fantasy Grounds Rulesets

  3. #3
    Trenloe's Avatar
    Join Date
    May 2011
    Location
    Colorado, USA
    Posts
    33,291
    Yep, as Valarian says, run your development rulesets in a directory.

    Some info on files and locations here: https://www.fantasygrounds.com/wiki/...rview#Rulesets
    Private Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!

  4. #4
    LordEntrails's Avatar
    Join Date
    May 2015
    Location
    -7 UTC
    Posts
    17,094
    Blog Entries
    9
    Rather than regedit, you can always change file associations through the interface, right mouse, "open with" select your zip program, and check the "Always open with..." box.

    Problems? See; How to Report Issues, Bugs & Problems
    On Licensing & Distributing Community Content
    Community Contributions: Gemstones, 5E Quick Ref Decal, Adventure Module Creation, Dungeon Trinkets, Balance Disturbed, Dungeon Room Descriptions
    Note, I am not a SmiteWorks employee or representative, I'm just a user like you.

  5. #5
    damned's Avatar
    Join Date
    Mar 2011
    Location
    Australia
    Posts
    26,638
    Blog Entries
    1
    Unpacking and running from source works for pak/rulesets, ext/extensions, mod/modules too... maybe it works for ppk as well but that is an edge case!

  6. #6
    Quote Originally Posted by LordEntrails View Post
    Rather than regedit, you can always change file associations through the interface, right mouse, "open with" select your zip program, and check the "Always open with..." box.
    Actually, I tried that. Because it isn’t recognized as a compressed folder by default, it goes into ak endless loop tryng to open it a a standard folder. The loop ended 10 minutes later after I manually entered the keys (you can’t copy/paste from within regedit). As soon as the last string was entered, the folder opened.

  7. #7
    I know. The problem was having to repeatedly change the file extension. When you’re trying to move items around in one of the windows classes, the constant changing gets very tiring. I orefer to have more direct access to the files.
    As for the .mod files, I’m not with them, since it’s less trouble to enter the data in FG and export.

  8. #8
    I just set 7zip as the default program for those extensions and can open and change files from a temporary location. Just copy back the file with the changes. No need to unpack anything.

  9. #9

    Join Date
    May 2016
    Location
    Jacksonville, FL
    Posts
    2,211
    Blog Entries
    7
    7zip will already know it's a .zip file without having to associate it at all. Just right-click -> 7zip -> Open archive.

    If you're actively working with rulesets, extensions, or modules, it's always best to work from a folder as has been repeatedly stated above.

  10. #10

    Reverse

    Quote Originally Posted by Dave0910 View Post
    For many of you, I'm sure you've encountered the same frustration I did when working on custom rulesets; that is having to change the .pak file to a .zip, edit the files and the change it back. That gets really trying, really fast. Fortunately, in Windows, that's easy to fix. Friendly warning before you try this, editing registry files can TOTALLY fubar your system if you don't know what you're doing. Make sure, for example, that you don't have other programs that use the file extension .pak.

    Anyway, it's a simple registry hack. You just need to make windows recognize .pak files as compressed folders. All you need to do is run CMD as Administrator (Programs->Accessories, the right click command prompt and select Run as Administrator).



    After this is done, the file will be treated as a normal .zip file, and you can explore or replace files as needed (Remember that you can't edit the files directly unless it's supported by your xml editor. AltovaXML Spy handles this, wonderfully).
    Hello there, I've done it, but how can I revert it?

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
FG Spreadshirt Swag

Log in

Log in