mwbay
July 7th, 2011, 01:15
Hi there...
I'm brand new to this, but I'm working to convert the Classic Traveller ruleset to Mongoose Traveller. In MongTrav, Characteristics have modifiers, much like they do in D&D. My goal is to add a column of boxes that auto-calculate those mods based on the current Characteric levels.
I've managed to tweak the Character Sheet to shift the UPP and Armor data over, and added the "Mod." header. Now, I'm trying to figure out how to create the column of boxes.
https://atlantagamer.net/untitled.jpg
There's a script in the charsheet_main.xml file that appears to do it, but I've got no idea how to read that yet.
function onInit()
local pnode = window.getDatabaseNode();
for i,char in ipairs(Global.Lookups.Characteristics) do
local node = pnode.createChild("characteristics."..char.position);
local win = createWindow(node);
if win.name.getValue()=="" then win.name.setValue(char.name) end;
if win.abbreviation.getValue()=="" then win.abbreviation.setValue(char.abbreviation) end;
if win.gpcode.getValue()=="" then win.gpcode.setValue(char.gpcode) end;
if char.physical then
win.damage.setVisible(true);
win.encumbrance.setVisible(true);
end
end
applyFilter();
applySort();
end
If anyone has any suggestions for how to achieve this, I'd love to hear them!
I'm brand new to this, but I'm working to convert the Classic Traveller ruleset to Mongoose Traveller. In MongTrav, Characteristics have modifiers, much like they do in D&D. My goal is to add a column of boxes that auto-calculate those mods based on the current Characteric levels.
I've managed to tweak the Character Sheet to shift the UPP and Armor data over, and added the "Mod." header. Now, I'm trying to figure out how to create the column of boxes.
https://atlantagamer.net/untitled.jpg
There's a script in the charsheet_main.xml file that appears to do it, but I've got no idea how to read that yet.
function onInit()
local pnode = window.getDatabaseNode();
for i,char in ipairs(Global.Lookups.Characteristics) do
local node = pnode.createChild("characteristics."..char.position);
local win = createWindow(node);
if win.name.getValue()=="" then win.name.setValue(char.name) end;
if win.abbreviation.getValue()=="" then win.abbreviation.setValue(char.abbreviation) end;
if win.gpcode.getValue()=="" then win.gpcode.setValue(char.gpcode) end;
if char.physical then
win.damage.setVisible(true);
win.encumbrance.setVisible(true);
end
end
applyFilter();
applySort();
end
If anyone has any suggestions for how to achieve this, I'd love to hear them!