Loading ...
Sorry, an error occurred while loading the content.

"API" type access to PCGen

Expand Messages
  • STILES, BRAD
    What are the prospects for providing access to PCGen s functionality to other applications? I m specifically referring to Tim Evans PCGenView, but this might
    Message 1 of 9 , Jan 2, 2002
    • 0 Attachment
      What are the prospects for providing access to PCGen's functionality to
      other applications? I'm specifically referring to Tim Evans' PCGenView, but
      this might apply to other apps as well.

      For Tim's program to work, one needs to generate a character, then export
      it, then convert it using his PCGenToPalm helper app, then hotsync it to
      one's Palm.

      To make this process slightly easier, it might be helpful if the PCGenToPalm
      program could run PCGen directly to get the exported data; that would at
      least compress two steps into one, and when Tim gets time for the conduit,
      it would take care of everything but the generation of the character.

      I see two ways of doing something like this, though I haven't a clue as to
      the feasibility of one over the other, nor have I given much thought to
      other possibilities.

      1. Use command line parameters when running PCGen to tell it to export a
      character, and then exit. PCGen loads a lot of data, even for just
      exporting, so this might be a very time consuming process. For export
      purpose, you'd need at least three, path and name of the PCG file, path and
      name of the template to be used, and path and name of the exported file.

      2. Provide a set of public classes in the PCGen jar file that will do the
      export. Given the amount of information that PCGen processes, I don't know
      if this is feasible, or would save any time over the first option. Is there
      a way to do this from an already running instance of PCGen, or would it have
      to be a new instance each time? If one could do it from an already running
      instance of PCGen, then it would be possible to do multiple characters at a
      time, without incurring the overhead of starting and stopping PCGen for each
      one.

      Brad
    • skippy_net
      ... functionality to ... PCGenView, but ... I m very interested in this topic: I ve been itching to create a perl CGI interface to the .pcg files, so I can
      Message 2 of 9 , Jan 2, 2002
      • 0 Attachment
        --- In pcgen@y..., "STILES, BRAD" <BRAD.STILES@s...> wrote:
        > What are the prospects for providing access to PCGen's
        functionality to
        > other applications? I'm specifically referring to Tim Evans'
        PCGenView, but
        > this might apply to other apps as well.

        I'm very interested in this topic: I've been itching to create a perl
        CGI interface to the .pcg files, so I can modify my play-by-email
        character's from work.

        > 1. Use command line parameters when running PCGen to tell it to
        export a
        > character, and then exit. PCGen loads a lot of data, even for just
        > exporting, so this might be a very time consuming process. For
        export
        > purpose, you'd need at least three, path and name of the PCG file,
        path and
        > name of the template to be used, and path and name of the exported
        file.

        Why can't a seperate helper-app read the .pcg files, and create
        the .pdb for the handheld? I haven't used PCGenView (yet! just got
        my Sony CLIE), so I'm not familiar with the steps involved.

        ---
        Is the .pcg format documented thoroughly, anywhere? I've read the
        talk about moving to an XML format, but is that really necessary?
        What's wrong with having some ancillary packages manipulate the .pcg
        files directly?
      • Tim Evans
        Hello skippy_net, Wednesday, January 02, 2002, 2:25:22 PM, you wrote: ... s functionality to ... s PCGenView, but ... s I m very interested in this topic:
        Message 3 of 9 , Jan 2, 2002
        • 0 Attachment
          Hello skippy_net,

          Wednesday, January 02, 2002, 2:25:22 PM, you wrote:

          s> --- In pcgen@y..., "STILES, BRAD" <BRAD.STILES@s...> wrote:
          >> What are the prospects for providing access to PCGen's
          s> functionality to
          >> other applications? I'm specifically referring to Tim Evans'
          s> PCGenView, but
          >> this might apply to other apps as well.

          s> I'm very interested in this topic: I've been itching to create a perl
          s> CGI interface to the .pcg files, so I can modify my play-by-email
          s> character's from work.

          >> 1. Use command line parameters when running PCGen to tell it to
          s> export a
          >> character, and then exit. PCGen loads a lot of data, even for just
          >> exporting, so this might be a very time consuming process. For
          s> export
          >> purpose, you'd need at least three, path and name of the PCG file,
          s> path and
          >> name of the template to be used, and path and name of the exported
          s> file.

          s> Why can't a seperate helper-app read the .pcg files, and create
          s> the .pdb for the handheld? I haven't used PCGenView (yet! just got
          s> my Sony CLIE), so I'm not familiar with the steps involved.

          The problem is the PCG file does not contain all the info that is
          exported so some info is worked out in PCGen..:)

          s> ---
          s> Is the .pcg format documented thoroughly, anywhere? I've read the
          s> talk about moving to an XML format, but is that really necessary?
          s> What's wrong with having some ancillary packages manipulate the .pcg
          s> files directly?


          --
          Best regards,
          Tim mailto:tim.evans@...
          Author of PCGenView http://www.pcgenview.com
          http://pcgenview.com
        • skippy_net
          ... functionality to ... PCGenView, but ... I m intensely interested in this topic, as I ve been toying with creating a perl CGI interface to the .pcg files so
          Message 4 of 9 , Jan 2, 2002
          • 0 Attachment
            --- In pcgen@y..., "STILES, BRAD" <BRAD.STILES@s...> wrote:
            > What are the prospects for providing access to PCGen's
            functionality to
            > other applications? I'm specifically referring to Tim Evans'
            PCGenView, but
            > this might apply to other apps as well.

            I'm intensely interested in this topic, as I've been toying with
            creating a perl CGI interface to the .pcg files so that I can modify
            my play-by-email characters while away from my home computer (ie:
            from work).

            I'm not familiar with XML _at all_, so I'd advocate for ancillary
            programs that manipulate the .pcg files directly -- why require an
            export, if the .pcg file is in a well-defined format?

            (I suppose that argues the point _for_ XML, but oh well)
          • skippy_net
            Pardon the duplicate post -- I m new to Yahoo! groups.
            Message 5 of 9 , Jan 2, 2002
            • 0 Attachment
              Pardon the duplicate post -- I'm new to Yahoo! groups.

              </hangs head in shame>
            • backlash_de
              ... functionality to ... PCGenView, but ... export ... it to ... PCGenToPalm ... would at ... conduit, ... character. ... clue as to ... thought to ... export
              Message 6 of 9 , Jan 2, 2002
              • 0 Attachment
                --- In pcgen@y..., "STILES, BRAD" <BRAD.STILES@s...> wrote:
                > What are the prospects for providing access to PCGen's
                functionality to
                > other applications? I'm specifically referring to Tim Evans'
                PCGenView, but
                > this might apply to other apps as well.
                >
                > For Tim's program to work, one needs to generate a character, then
                export
                > it, then convert it using his PCGenToPalm helper app, then hotsync
                it to
                > one's Palm.
                >
                > To make this process slightly easier, it might be helpful if the
                PCGenToPalm
                > program could run PCGen directly to get the exported data; that
                would at
                > least compress two steps into one, and when Tim gets time for the
                conduit,
                > it would take care of everything but the generation of the
                character.
                >
                > I see two ways of doing something like this, though I haven't a
                clue as to
                > the feasibility of one over the other, nor have I given much
                thought to
                > other possibilities.
                >
                > 1. Use command line parameters when running PCGen to tell it to
                export a
                > character, and then exit. PCGen loads a lot of data, even for just
                > exporting, so this might be a very time consuming process. For
                export
                > purpose, you'd need at least three, path and name of the PCG file,
                path and
                > name of the template to be used, and path and name of the exported
                file.
                >
                > 2. Provide a set of public classes in the PCGen jar file that will
                do the
                > export. Given the amount of information that PCGen processes, I
                don't know
                > if this is feasible, or would save any time over the first option.
                Is there
                > a way to do this from an already running instance of PCGen, or
                would it have
                > to be a new instance each time? If one could do it from an already
                running
                > instance of PCGen, then it would be possible to do multiple
                characters at a
                > time, without incurring the overhead of starting and stopping PCGen
                for each
                > one.
                >
                > Brad

                I haven't tried yet, but wouldn't it suffice to instantiate
                PlayerCharacter.java and then use its public load and print methods?
                I'm not positiv about loading a char, but printing is definitly no
                problem - once your instance of PlayerCharacter holds all data.

                Kinson
              • Brass Tilde
                ... _________________________________________________________ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com
                Message 7 of 9 , Jan 2, 2002
                • 0 Attachment
                  > -----Original Message-----
                  > From: skippy_net [mailto:skippy@...]
                  >
                  >
                  > Why can't a seperate helper-app read the .pcg files, and create
                  > the .pdb for the handheld? I haven't used PCGenView (yet! just got
                  > my Sony CLIE), so I'm not familiar with the steps involved.

                  Two problems with this (well, one isn't really a problem). Not all the
                  information that is exported, is held in the PCG file. The PCG file has
                  many references to data that exists elsewhere, such as in LST files, or
                  values that are derived at runtime.

                  The other thing is, the code for exporting is already written. If some
                  method can be found to re-use it, why reinvent the wheel.

                  Brass


                  _________________________________________________________
                  Do You Yahoo!?
                  Get your free @... address at http://mail.yahoo.com
                • Mark Hulsman
                  ... PCGenToPalm ... Well, it would not be able to run PC Gen and get data straight from it. But if you use another java program it can instantiate Globals and
                  Message 8 of 9 , Jan 2, 2002
                  • 0 Attachment
                    > To make this process slightly easier, it might be helpful if the
                    PCGenToPalm
                    > program could run PCGen directly to get the exported data; that would at
                    > least compress two steps into one, and when Tim gets time for the conduit,
                    > it would take care of everything but the generation of the character.

                    Well, it would not be able to run PC Gen and get data straight from it. But
                    if you use another java program it can instantiate Globals and
                    PlayerCharacter and then it can use any of PC Gens data manipulation
                    methods. The gui is not required for any of the data stuff. You would jsut
                    have to write a java program that could tell Globals which pcc files to load
                    and tell PlayerCharacter to load a PCC.

                    > 2. Provide a set of public classes in the PCGen jar file that will do the
                    > export. Given the amount of information that PCGen processes, I don't
                    know
                    > if this is feasible, or would save any time over the first option. Is
                    there
                    > a way to do this from an already running instance of PCGen, or would it
                    have
                    > to be a new instance each time? If one could do it from an already
                    running
                    > instance of PCGen, then it would be possible to do multiple characters at
                    a
                    > time, without incurring the overhead of starting and stopping PCGen for
                    each
                    > one.

                    All the classes in the jar are already public and can do all this. You
                    basically jsut have to import the package pcgen.core and that has all the
                    data manipulation stuff you need. If you did it like this there would be no
                    need to have PC Gen running at all. You'd just have a small java program
                    that you tell which template and character to use and it could do it using
                    the core package.
                  • skippy_net
                    ... got ... the ... file has ... files, or ... some ... I m sure it s been addressed somewhere, but: why not include all the information in the .pcg files? It
                    Message 9 of 9 , Jan 3, 2002
                    • 0 Attachment
                      --- In pcgen@y..., "Brass Tilde" <brasstilde@y...> wrote:
                      > > Why can't a seperate helper-app read the .pcg files, and create
                      > > the .pdb for the handheld? I haven't used PCGenView (yet! just
                      got
                      > > my Sony CLIE), so I'm not familiar with the steps involved.
                      >
                      > Two problems with this (well, one isn't really a problem). Not all
                      the
                      > information that is exported, is held in the PCG file. The PCG
                      file has
                      > many references to data that exists elsewhere, such as in LST
                      files, or
                      > values that are derived at runtime.
                      >
                      > The other thing is, the code for exporting is already written. If
                      some
                      > method can be found to re-use it, why reinvent the wheel.

                      I'm sure it's been addressed somewhere, but: why not include all the
                      information in the .pcg files? It would be a static snapshot of the
                      rules, and would not include the logic or game mechanics to obviate
                      the need for the books. So it shouldn't violate any intellectual
                      propert concerns. (Indeed, people distribute fully loaded character
                      sheets in MS Word or HTML format already; if .pcg files are simple
                      text, this should be no different).

                      As for the second point, re-inventing the wheel would be (partly)
                      necessary if someone would like to use a non-java solution.

                      For example, I have a very sluggish laptop that I take to gaming
                      sessions, and PCGen performs _abysmally_ on it. If I could create a
                      text based perl interface for .pcg manipulation, I'd use that much
                      more often while at the gaming table. Likewise, that perl solution
                      could be made into a CGI for execution on my website to allow my play-
                      by-email characters to maintain their character sheets themselves,
                      while still keeping all files / information under my website (so we
                      all know where to go for the authoritative character sheet).
                    Your message has been successfully submitted and would be delivered to recipients shortly.