Menu
News
All News
Dungeons & Dragons
Level Up: Advanced 5th Edition
Pathfinder
Starfinder
Warhammer
2d20 System
Year Zero Engine
Industry News
Reviews
Dragon Reflections
White Dwarf Reflections
Columns
Weekly Digests
Weekly News Digest
Freebies, Sales & Bundles
RPG Print News
RPG Crowdfunding News
Game Content
ENterplanetary DimENsions
Mythological Figures
Opinion
Worlds of Design
Peregrine's Nest
RPG Evolution
Other Columns
From the Freelancing Frontline
Monster ENcyclopedia
WotC/TSR Alumni Look Back
4 Hours w/RSD (Ryan Dancey)
The Road to 3E (Jonathan Tweet)
Greenwood's Realms (Ed Greenwood)
Drawmij's TSR (Jim Ward)
Community
Forums & Topics
Forum List
Latest Posts
Forum list
*Dungeons & Dragons
Level Up: Advanced 5th Edition
D&D Older Editions
*TTRPGs General
*Pathfinder & Starfinder
EN Publishing
*Geek Talk & Media
Search forums
Chat/Discord
Resources
Wiki
Pages
Latest activity
Media
New media
New comments
Search media
Downloads
Latest reviews
Search resources
EN Publishing
Store
EN5ider
Adventures in ZEITGEIST
Awfully Cheerful Engine
What's OLD is NEW
Judge Dredd & The Worlds Of 2000AD
War of the Burning Sky
Level Up: Advanced 5E
Events & Releases
Upcoming Events
Private Events
Featured Events
Socials!
EN Publishing
Twitter
BlueSky
Facebook
Instagram
EN World
BlueSky
YouTube
Facebook
Twitter
Twitch
Podcast
Features
Top 5 RPGs Compiled Charts 2004-Present
Adventure Game Industry Market Research Summary (RPGs) V1.0
Ryan Dancey: Acquiring TSR
Q&A With Gary Gygax
D&D Rules FAQs
TSR, WotC, & Paizo: A Comparative History
D&D Pronunciation Guide
Million Dollar TTRPG Kickstarters
Tabletop RPG Podcast Hall of Fame
Eric Noah's Unofficial D&D 3rd Edition News
D&D in the Mainstream
D&D & RPG History
About Morrus
Log in
Register
What's new
Search
Search
Search titles only
By:
Forums & Topics
Forum List
Latest Posts
Forum list
*Dungeons & Dragons
Level Up: Advanced 5th Edition
D&D Older Editions
*TTRPGs General
*Pathfinder & Starfinder
EN Publishing
*Geek Talk & Media
Search forums
Chat/Discord
Menu
Log in
Register
Install the app
Install
Community
General Tabletop Discussion
*Geek Talk & Media
Why's it so hard to create a character generator that rocks?
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="Zappo" data-source="post: 1564106" data-attributes="member: 633"><p>I tried that, back in 3.0. I needed a way to create characters and manage them during the game, and I wanted all the boring stuff to be made by the software. C++, heavily object-oriented, worked on Linux. Every game object (class, feat, monster, stat, whatever) had its own class, and lots of inheritance was involved (eg, Item -> Weapon -> Ranged Weapon -> Light Crossbow). Every object could send or receive messages, and the effect of a user action would cascade through the character to change everything that needs to be changed.</p><p> </p><p> I could click on Barbarian Rage and the code for the Rage would be called, which would tell Constitution "go up by two". Constitution would shout out "I went up by two!", HP would hear it and adjust itself, and so on. Very easy to debug, too; just trace the messages.</p><p> </p><p> Advantage: I could create a half-fiend vampiric ogre ranger/barbarian dual-wielding a bastard sword and a +2 keen dagger, with Weapon Finesse, raging, and read the correct attacks and damage for each attack on the screen. Then terminate the rage and read the new correct attacks and damage, including the fatigue effect. Then terminate the fatigue and read the right stuff again. Then unequip the weapons and read the claw/bite attacks. It even did monks with shuriken, and you know the infernal way shuriken work in 3.0. Pretty good I think. I had all the PHB and a bunch of monsters and templates before I got tired of it (minus the actual effects of spells, though the infrastructure was there).</p><p> </p><p> <em>Big</em> disadvantage: can't add stuff without recompiling. Adding something trivial such as a weapon with no special rules, or a feat with no mechanical effects, is as easy as copying/pasting a single line in a source file and changing the name - the logic would be inherited by parent classes. But complex stuff, eh, you must know C++ and the program's message architecture.</p><p> </p><p> What can I say - back then, I was already good at coding but I hadn't done much software engineering. The message-based architecture was a good idea, as was the inheritance, but lots of other details I'm a bit ashamed of (reason for which I won't release the program). The possibility of adding code to any aspect of any game object means ultimate flexibility - but being <em>forced</em> to do it is bad, not counting the fact that integrating different versions would be a problem.</p><p> </p><p> Maybe a hybrid approach would work better: define game objects in simple, limited XML, with the option to also give them an actual class. Simple stuff like "it's a melee weapon dealing 1d8 piercing damage" can be in the XML (the Weapon base class will interpret this), complex stuff like "you can forfeit an attack to gain a +2 dodge bonus to AC" goes in the code. The class could be stored in a DLL; the program would read the class name, load the code, and start communicating with it via the well-defined message system. This way, you could make "packages" for a book, containing an XML file and a DLL; users would simply download them and plop them in the program dir, and the new stuff would be available in the program and even interact correctly with other packages written by other people (as correctly as the books themselves do anyway... which sometimes isn't much). Any user would be able to add simple stuff, while developers and other "power users" willing to write a bit of C++ and read the message specifications could make the complex, active things. Other programs could just read the XML and make what they want with the data it contains, or link to the DLLs and start swapping messages. Saving/loading could be conceptually similar, too.</p><p> </p><p> Anyway, I won't make this. I estimate around one year of hard work to fully define the message system and XML, build the program, make the PHB package, and test them. I don't have that kind of free time any more. Out of academic interest, what do you professionals think about this architecture?</p></blockquote><p></p>
[QUOTE="Zappo, post: 1564106, member: 633"] I tried that, back in 3.0. I needed a way to create characters and manage them during the game, and I wanted all the boring stuff to be made by the software. C++, heavily object-oriented, worked on Linux. Every game object (class, feat, monster, stat, whatever) had its own class, and lots of inheritance was involved (eg, Item -> Weapon -> Ranged Weapon -> Light Crossbow). Every object could send or receive messages, and the effect of a user action would cascade through the character to change everything that needs to be changed. I could click on Barbarian Rage and the code for the Rage would be called, which would tell Constitution "go up by two". Constitution would shout out "I went up by two!", HP would hear it and adjust itself, and so on. Very easy to debug, too; just trace the messages. Advantage: I could create a half-fiend vampiric ogre ranger/barbarian dual-wielding a bastard sword and a +2 keen dagger, with Weapon Finesse, raging, and read the correct attacks and damage for each attack on the screen. Then terminate the rage and read the new correct attacks and damage, including the fatigue effect. Then terminate the fatigue and read the right stuff again. Then unequip the weapons and read the claw/bite attacks. It even did monks with shuriken, and you know the infernal way shuriken work in 3.0. Pretty good I think. I had all the PHB and a bunch of monsters and templates before I got tired of it (minus the actual effects of spells, though the infrastructure was there). [i]Big[/i] disadvantage: can't add stuff without recompiling. Adding something trivial such as a weapon with no special rules, or a feat with no mechanical effects, is as easy as copying/pasting a single line in a source file and changing the name - the logic would be inherited by parent classes. But complex stuff, eh, you must know C++ and the program's message architecture. What can I say - back then, I was already good at coding but I hadn't done much software engineering. The message-based architecture was a good idea, as was the inheritance, but lots of other details I'm a bit ashamed of (reason for which I won't release the program). The possibility of adding code to any aspect of any game object means ultimate flexibility - but being [i]forced[/i] to do it is bad, not counting the fact that integrating different versions would be a problem. Maybe a hybrid approach would work better: define game objects in simple, limited XML, with the option to also give them an actual class. Simple stuff like "it's a melee weapon dealing 1d8 piercing damage" can be in the XML (the Weapon base class will interpret this), complex stuff like "you can forfeit an attack to gain a +2 dodge bonus to AC" goes in the code. The class could be stored in a DLL; the program would read the class name, load the code, and start communicating with it via the well-defined message system. This way, you could make "packages" for a book, containing an XML file and a DLL; users would simply download them and plop them in the program dir, and the new stuff would be available in the program and even interact correctly with other packages written by other people (as correctly as the books themselves do anyway... which sometimes isn't much). Any user would be able to add simple stuff, while developers and other "power users" willing to write a bit of C++ and read the message specifications could make the complex, active things. Other programs could just read the XML and make what they want with the data it contains, or link to the DLLs and start swapping messages. Saving/loading could be conceptually similar, too. Anyway, I won't make this. I estimate around one year of hard work to fully define the message system and XML, build the program, make the PHB package, and test them. I don't have that kind of free time any more. Out of academic interest, what do you professionals think about this architecture? [/QUOTE]
Insert quotes…
Verification
Post reply
Community
General Tabletop Discussion
*Geek Talk & Media
Why's it so hard to create a character generator that rocks?
Top