PDA

View Full Version : Minimum Ruleset Files



Casimir
September 16th, 2009, 21:04
I'm currently working on a ruleset, both for the purposes of learning how to edit and create one as well as for my own use with my own campaign. I've looked through the documentation I can find regarding ruleset files and scripts, and really haven't found what I am looking for.

I don't want to work from the d20 ruleset as a base. By that I mean that I don't want to use the existing d20 (the one designed for an example) and then have to edit a bunch of files to get my ruleset to work. I'd rather work from scratch, and use the d20 ruleset as a guide for some things so I can see how they flow.

Last night I got as far as the desktop - but it's not rendering the desktop. All it renders is the dice, which don't refresh as they move, so I have basically a FGII opening campaign splash screen with dice images smeared across it as they roll. I tried to use all of the files related to the "desktop.xml" file as my basis - but obviously I missed something(s).

So - what I'd like to know, or find, is what the bare minimum files, scripts, and frames required are in a ruleset so that the desktop renders along with the chat window, dice, modifier box, and upper right buttons (lighting, characters, etc.). From there I can begin working on the character sheet and everything else.

Is that information available anywhere?

Valarian
September 16th, 2009, 21:44
You could start with the Foundation ruleset, or take the Base Ruleset (https://oberoten.dyndns.org/fgwiki/index.php/Base_Ruleset) from the FGWiki.

Ikael
September 17th, 2009, 06:29
I have done some graphical bare-minumum research to separate ruleset's logic from graphics. The idea is that ruleset's size would be kept as minimum as possible and graphical themes would be in separate extension files (just to speedup the downloading process in startup).

To create an empty desktop with correctly rollable dices and exit/back to launcher option in radialmenu one should use at least following graphics:


<root version="2.0">
<framedef name="desktop">
<bitmap file="frames/desktop.png" />
<middle rect="0,0,512,512" />
<right rect="512,0,97,512" />
<decal rect="612,0,512,512" />
</framedef>
<framedef name="mini_name">
<bitmap file="frames/emptyframe.png" />
</framedef>
<icon name="closeprogram" file="icons/icon_closeprogram.png" />
<icon name="rotateccw" file="icons/icon_rotateccw.png" />
<icon name="menuhub" file="icons/menuhub.png" />
</root>

If you don't use desktop-image then dice rolling won't render correctly and if I remember correctly mini_name is somewhat essential or radialmenu will have some renderin problem. Menuhub is not compulsory, but it gives nice look of the radial-menu. Closeprogram icon is used to represent the exit program button and rotateccw is the menuoption to 'return to launcher' (that works at least in my graphical-bare-minumum ruleset).

Foen
September 17th, 2009, 06:35
If you define a "return" icon resource, it will be used for the 'return to launcher' radial menu entry. If "return" isn't defined, it uses "rotateccw" instead.

I've updated the Base Ruleset significantly since it was first posted, and I've put the revised version (0.4.80) on the FG wiki (https://oberoten.dyndns.org/fgwiki/index.php/Main_Page). In future, I'll try to migrate the code back to the Foundation.

Foen

Ikael
September 17th, 2009, 07:24
Thanks Foen about the 'Return' information, it has slightly borthered me that rotateccw works as the return button in my ruleset but for example foundation/3.5 uses the "big arrow" icon.

Moon Wizard
September 17th, 2009, 07:59
I also recently learned that some of the fonts are required to be defined as well. "diemod provides the numbers on the dice that are rolled in the chat window, and "draglabel" provides the numbers/text on the drag pointer when dragging a number/string.

Cheers,
JPG

Casimir
September 17th, 2009, 15:30
I'll give that a shot Ikeal and see how that goes. Ideally what I want to do is to create a base ruleset that has the primary rules for what I want to develop, and then use extensions or modules as supplements that include my own house rules.

It might even be easier to develop each section of the ruleset as a supplement module / extension and then combine them all when it's completed too - I'll have to give that a look over.

EDIT : I'm using the following base.xml code -

<root version="2.0">
<framedef name="desktop">
<bitmap file="frames/desktop.png" />
<middle rect="0,0,512,512" />
<right rect="512,0,97,512" />
<decal rect="612,0,512,512" />
</framedef>
<framedef name="mini_name">
<bitmap file="frames/emptyframe.png" />
</framedef>
<icon name="closeprogram" file="icons/icon_closeprogram.png" />
<icon name="rotateccw" file="icons/icon_rotateccw.png" />
<icon name="return" file="icons/icon_return.png" />
<icon name="menuhub" file="icons/menuhub.png" />
</root>
with the following directory structure :


icons
icon_closeprogram.png
icon_return.png
icon_rotateccw.png
menuhub.png
frames
desktop.png
base.xml

and all I'm getting is this - the desktop image itself is not loading :

https://www.singularitycollective.org/images/desktop1.gif

Where am I going wrong... or is this what I should be getting? I cannot find an "emptyframe.png" image file anywhere in any of the rulesets I have for an example of that image file... could that be the problem?

Ikael
September 17th, 2009, 17:02
I believe you also have to declare following line in your base.xml:
<desktopframe>desktop</desktopframe>

and about that emptyframe.png, it was my own created png image that is just a 1x1 empty pixel, it's corresponsing real image is the mini_name in frame/ folder, but that it's used in radialmenu and don't have anything to do with the desktop problem. Try to set the line mentioned above to you base.xml

Casimir
September 17th, 2009, 17:22
Yea... that was it. Oddly enough I knew that... but didn't realize I hadn't included it. Too many things going on at once I guess (working from home today, messing with this in between projects).