DICE PACKS BUNDLE
Page 16 of 20 First ... 61415161718 ... Last

Thread: NPC Engineer

  1. #151
    Quote Originally Posted by L. R. Ballard View Post
    Perhaps NPC Engineer aspires to parse as well . . .
    Funny you should say that....

    Yeah, my goal is to make NPC Engineer a standalone Bestiary creator. I was researching yet another file structure that will make this easier tonight. This will make its first appearance in the save and load functions in NPC Engineer, and then I'll slowly work towards a full parser using it. It's all part of the fun!

    Maasq
    Engineer Suite
    Import, build or edit NPCs/spells/equipment and then parse them directly into a Fantasy Grounds module.

    Download the latest version from the website.
    Support me by becoming a patron on Patreon.

    Chat directly about issues or suggest features on the
    Discord channel.
    Post issues on the issue tracker on Github.

  2. #152
    I am writing the save & load functions.
    I have decided to move away from XML to ease my journey into parsing. This means any creatures saved individually with the current or previous versions won't load. Does this present a problem to anyone? Do I need to write a converter?

    Maasq
    Engineer Suite
    Import, build or edit NPCs/spells/equipment and then parse them directly into a Fantasy Grounds module.

    Download the latest version from the website.
    Support me by becoming a patron on Patreon.

    Chat directly about issues or suggest features on the
    Discord channel.
    Post issues on the issue tracker on Github.

  3. #153
    Quote Originally Posted by Maasq View Post
    Funny you should say that....

    Yeah, my goal is to make NPC Engineer a standalone Bestiary creator. I was researching yet another file structure that will make this easier tonight. This will make its first appearance in the save and load functions in NPC Engineer, and then I'll slowly work towards a full parser using it. It's all part of the fun!

    Maasq
    Indeed. You appear to be enjoying this project you're working on, and it looks like it is catching on with the FG community. Again, congratulations on an impressive work.

    I learned a lot over the summer when the script was still being written in Autohotkey. Your project helped me to truly start to learn Autohotkey, in fact. For years, I'd been seeking a solution for quickly adding comments to Word documents and assignments submitted online. Since the summer, I've written dozens of scripts that are helping me not only in my freelance editing work but also in grading student essays.

    I appreciate your introducing me to the scripting language and allowing me to peek at the source code for early versions of the utility. My best to you for the continued success of the project!
    Last edited by L. R. Ballard; September 14th, 2017 at 02:25.

  4. #154
    Quote Originally Posted by Maasq View Post
    I am writing the save & load functions.

    I have decided to move away from XML to ease my journey into parsing. This means any creatures saved individually with the current or previous versions won't load. Does this present a problem to anyone? Do I need to write a converter?

    Maasq
    I may have misunderstood the question, but here goes: One feature of the utility that looked promising in early versions was the ability to save an XML version of an NPC. Then that XML version could be uploaded into FG in a PC stat card, which a handful of people found useful. Some even thought a PC version of an NPC a preferable alternative to the less-automated NPC stat card. So, if that feature is saying goodbye, I'll mourn the loss. But if the XML output needs to be put on hold to focus on parsing NPCs, that's probably for the best given that the standard output is .txt, in NPC format.

  5. #155
    Quote Originally Posted by L. R. Ballard View Post
    his
    Now you know.

    Quote Originally Posted by Maasq View Post
    I am writing the save & load functions.
    I have decided to move away from XML to ease my journey into parsing. This means any creatures saved individually with the current or previous versions won't load. Does this present a problem to anyone? Do I need to write a converter?

    Maasq
    Im slightly confused here, you DO need the xml tags if you are going to have a parse utility, if you get rid of the XML how are you going to create a mod?
    My Project : FG5EParser LINK

    Current Projects : Revamped FG5eParser v2!

  6. #156
    Quote Originally Posted by L. R. Ballard View Post
    Indeed. You appear to be enjoying this project you're working on, and it looks like it is catching on with the FG community. Again, congratulations on an impressive work.

    I learned a lot over the summer when the script was still being written in Autohotkey. Your project helped me to truly start to learn Autohotkey, in fact. For years, I'd been seeking a solution for quickly adding comments to Word documents and assignments submitted online. Since the summer, I've written dozens of scripts that are helping me not only in my freelance editing work but also in grading student essays.

    I appreciate your introducing me to the scripting language and allowing me to peek at the source code for early versions of the utility. My best to you for the continued success of the project!
    Thank you very much for your kind words! This sort of thing keeps me going when I meet a teeth-grindingly annoying bug in the code.

    Would it be helpful if I post the uncompiled AHK script too? I started posting the compiled .exe for the convenience of users, more than anything. I'm happy for everyone to see the code and snaffle bits they like

    Quote Originally Posted by L. R. Ballard View Post
    I may have misunderstood the question, but here goes: One feature of the utility that looked promising in early versions was the ability to save an XML version of an NPC. Then that XML version could be uploaded into FG in a PC stat card, which a handful of people found useful. Some even thought a PC version of an NPC a preferable alternative to the less-automated NPC stat card. So, if that feature is saying goodbye, I'll mourn the loss. But if the XML output needs to be put on hold to focus on parsing NPCs, that's probably for the best given that the standard output is .txt, in NPC format.
    All the code for saving XML is still in the program, so I'll be able to add that as an option. The feature will still be there - you can still choose to save an XML file. I'll even tweak that part in the future to make it match more with what FG reads in.

    What I meant was that the save file for NPC Engineer will be changing format, so any NPCs you have saved won't reload when the 'load' feature is added. I am happy to write a little converter to upgrade any such saves so that they work with the 'load' feature.

    The reason for this is that my internal data structure is changing to make reading and manipulating the equivalent of npcs.txt easier for me. This is obviously an important step if I am going to parse the file out for FG. Don't worry if you don't understand what I am saying... it's my fault; I can't really explain what I am trying to do very well!

    It'll all work though, I am sure of it....

    Maasq
    Engineer Suite
    Import, build or edit NPCs/spells/equipment and then parse them directly into a Fantasy Grounds module.

    Download the latest version from the website.
    Support me by becoming a patron on Patreon.

    Chat directly about issues or suggest features on the
    Discord channel.
    Post issues on the issue tracker on Github.

  7. #157
    Quote Originally Posted by kp9911 View Post
    Im slightly confused here, you DO need the xml tags if you are going to have a parse utility, if you get rid of the XML how are you going to create a mod?
    This is down to my inability to explain myself; sorry for causing confusion!

    I have been thinking about how to parse the text files into memory and then sort them in the various ways I need to create the db.xml file - alpha sort, sort by CR, maybe sort by creature type. Now whether it is a limitation of AHK, or of my programming skills, or something else, sorting based on my variables was going to be a gruelling task. I realised I needed to move to an object-based structure to load all the NPCs in the npcs.txt file then manipulate the object as required.

    In the process of researching how to do this, I came across routines to save, manipulate and load json files. I realised that parsing a long text file each time wasn't necessary if I switched to json, so that's my plan for NPCE's own data structure. Obviously it will still support both Par5e and your parser as its main output - this json based system is experimental

    Once I relaise i was going to do that, then it made sense to change my save files for individual NPCs to json files too - reusable code and all that.

    When I parse the json file, the output for the mod file will still have all the required XML in the db.xml file.

    Hopefully that makes better sense. I actually enjoyed writing it, as it is the first time I have put words to my idea and helped clarify it in my own mind.

    Maasq
    Engineer Suite
    Import, build or edit NPCs/spells/equipment and then parse them directly into a Fantasy Grounds module.

    Download the latest version from the website.
    Support me by becoming a patron on Patreon.

    Chat directly about issues or suggest features on the
    Discord channel.
    Post issues on the issue tracker on Github.

  8. #158
    [QUOTE=kp
    9911;354559]Now you know.

    Cool. I thought so, but I like to know for sure if possible.

  9. #159
    Quote Originally Posted by Maasq View Post
    Thank you very much for your kind words!
    You're welcome.

    Quote Originally Posted by Maasq View Post
    Would it be helpful if I post the uncompiled AHK script too? I started posting the compiled .exe for the convenience of users, more than anything. I'm happy for everyone to see the code and snaffle bits they like
    I'm not sure. I think I've got it. Most of what I'm writing now are scripts that I get bits and pieces of from the AutoHotkey website; the scripts have to do with automating comments in various documents or making a GUI for a list of shortcuts or hotstrings. Next I'll be learning how to add URLs and more formatting. As far as scripting for FG goes, most of what I'm writing is easy stuff: adding markup to .txt files.

    I'd use the present version of NPC Engineer if I could add the automatic hit point calculations that I made for an earlier version. The auto calculation of hit points in Monster Maker helps me because late-night work otherwise leads to less-accurate calculation or long asides to the Amazon Echo. So, if I can add something to the existing code in a given version, that would be excellent. Otherwise, I think I'm good, but I may email an advanced question to you in the future.

    Quote Originally Posted by Maasq View Post
    What I meant was that the save file for NPC Engineer will be changing format, so any NPCs you have saved won't reload when the 'load' feature is added. I am happy to write a little converter to upgrade any such saves so that they work with the 'load' feature.

    The reason for this is that my internal data structure is changing to make reading and manipulating the equivalent of npcs.txt easier for me. This is obviously an important step if I am going to parse the file out for FG. Don't worry if you don't understand what I am saying... it's my fault; I can't really explain what I am trying to do very well!

    It'll all work though, I am sure of it....

    Maasq
    Right--changing the save feature won't affect me. I'm ignorant of what the internal data structures were or would become, but I trust you've got a practicable solution. I'll be hanging out.

  10. #160
    Quote Originally Posted by L. R. Ballard View Post
    I'd use the present version of NPC Engineer if I could add the automatic hit point calculations that I made for an earlier version.........Otherwise, I think I'm good, but I may email an advanced question to you in the future.
    I can add that - just two buttons, 'calculate average' and 'roll HP'? I'd be loth to calculate in bonuses from constitution though; there's a rabbit-hole of assumptions and calculations there I'd not want to plunge down at this stage. But if the HP box states (2d8 + 6) I can have it calculate '15' or roll 2d8 and add 6 for the old school feel. Is this what you mean? I can wheel in your code if it is something specific that I am missing here. Just let me know.

    I don't like the idea of leaving the code open to tinkering, as tracking down some unexplained behaviour would be excruciating. I have made life difficult for myself in this respect - my programming uses lots of global variables, because I am the programming equivalent of a toddler with a chainsaw, and that means it would be easy to inadvertently change something that caused the whole edifice to collapse. The first thing any real AHK programmer says to me on Discord when they see my code is a less polite version of 'you are using too many global variables, pal'

    Please feel free to email me any questions, or pop on to Discord and have a chat. I'm no expert but will give it my best shot, and I enjoy chatting about programming. The AutoHotKey Discord channel is also a friendly place (sometimes!) for grabbing advice, if you need real expert help.

    Speak soon

    Maasq
    Engineer Suite
    Import, build or edit NPCs/spells/equipment and then parse them directly into a Fantasy Grounds module.

    Download the latest version from the website.
    Support me by becoming a patron on Patreon.

    Chat directly about issues or suggest features on the
    Discord channel.
    Post issues on the issue tracker on Github.

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
  •  
STAR TREK 2d20

Log in

Log in