-
June 5th, 2019, 00:30 #1
Trying to alter VtM Character Sheet ...and I'm lost
Brand new to xml / lua so have no idea what I am doing. Realized the VtM uses an altered CoreRPG ruleset, so was able to alter the theme of it to be more readable, but the biggest issue I am having is with the character sheet. The layout is good however I do not want the ? and close icon to be hidden, and the dots to click on do not allow you to interact to input any stats. I think I have identified the issue, though not possible nor do I know what I would change it to be in order to fix it. Here is a screenshot of the charactersheet (The nodes are what allow no input), and the suspect line of code. Only showing the code for the Str set as its duplicated for the rest with different call tags.
VtMSheet.png
xml code
Code:<genericcontrol name="physicalattributeframe"> <bounds>15,145,200,70</bounds> <frame> <name>sheetgroup</name> </frame> </genericcontrol> <stringcontrol name="strength"> <anchored> <to>physicalattributeframe</to> <position>insidetopleft</position> <offset>10,11</offset> </anchored> <center /> <font>sheettextsmall</font> <static>Strength</static> <tooltip> <text>Strength</text> </tooltip> <script> function onDoubleClick(x,y) local difftmp = 0; local valuetmp = 0; local tableaulist = window.getDatabaseNode().getChild("strengthlist").getChildren(); for k, v in pairs(tableaulist) do valuetmp = v.getChild("charsheet_radio_button1").getValue() + v.getChild("charsheet_radio_button2").getValue() + v.getChild("charsheet_radio_button3").getValue(); valuetmp = valuetmp + v.getChild("charsheet_radio_button4").getValue() + v.getChild("charsheet_radio_button5").getValue() + v.getChild("charsheet_radio_button6").getValue(); valuetmp = valuetmp + v.getChild("charsheet_radio_button7").getValue() + v.getChild("charsheet_radio_button8").getValue() + v.getChild("charsheet_radio_button9").getValue(); valuetmp = valuetmp + v.getChild("charsheet_radio_button10").getValue(); end local dice = ChatManager.d10Check(valuetmp); local rRoll = { sType = "dice", sDesc = "Strength", aDice = dice, nMod = difftmp }; if (valuetmp ~= 0) then ActionsManager.actionDirect(nil, "dice", { rRoll }); end end </script> </stringcontrol>
"Smile. Now."
The words are gurgitated from the half-orc who looms over you seemingly peering into your soul with a snarl. A nervous smile crosses your face as you realize the half-orc is not actually snarling, but giving you his own version of a smile.
"Good. You friend now."
-
June 5th, 2019, 00:32 #2
lua code (I am suspecting this part of the code, though if needed I can post the rest.)
Code:function onWheel(notches) local flag = 0; if OptionsManager.isOption("MWHL", "on") then flag = 1; elseif (Input.isControlPressed() == true) then flag = 1; end if (flag==1) then local button10 = getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button10").getValue(); local button9 = getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button9").getValue(); local button8 = getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button8").getValue(); local button7 = getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button7").getValue(); local button6 = getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button6").getValue(); local button5 = getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button5").getValue(); local button4 = getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button4").getValue(); local button3 = getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button3").getValue(); local button2 = getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button2").getValue(); local button1 = getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button1").getValue(); local total = 1; if (notches >= 1) then if (button1 == 0 and button2 == 0 and button3 == 0 and button4 == 0 and button5 == 0 and button6 == 0 and button7 == 0 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button1").setValue(1); total = 1; elseif (button1 == 1 and button2 == 0 and button3 == 0 and button4 == 0 and button5 == 0 and button6 == 0 and button7 == 0 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button2").setValue(1); total = 2; elseif (button1 == 1 and button2 == 1 and button3 == 0 and button4 == 0 and button5 == 0 and button6 == 0 and button7 == 0 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button3").setValue(1); total = 3; elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 0 and button5 == 0 and button6 == 0 and button7 == 0 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button4").setValue(1); total = 4; elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 1 and button5 == 0 and button6 == 0 and button7 == 0 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button5").setValue(1); total = 5; elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 1 and button5 == 1 and button6 == 0 and button7 == 0 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button6").setValue(1); total = 6; elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 1 and button5 == 1 and button6 == 1 and button7 == 0 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button7").setValue(1); total = 7; elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 1 and button5 == 1 and button6 == 1 and button7 == 1 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button8").setValue(1); total = 8; elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 1 and button5 == 1 and button6 == 1 and button7 == 1 and button8 == 1 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button9").setValue(1); total = 9; elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 1 and button5 == 1 and button6 == 1 and button7 == 1 and button8 == 1 and button9 == 1 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button10").setValue(1); total = 10; end elseif (notches <= 0) then if (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 1 and button5 == 1 and button6 == 1 and button7 == 1 and button8 == 1 and button9 == 1 and button10 == 1) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button10").setValue(0); elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 1 and button5 == 1 and button6 == 1 and button7 == 1 and button8 == 1 and button9 == 1 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button9").setValue(0); elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 1 and button5 == 1 and button6 == 1 and button7 == 1 and button8 == 1 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button8").setValue(0); elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 1 and button5 == 1 and button6 == 1 and button7 == 1 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button7").setValue(0); elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 1 and button5 == 1 and button6 == 1 and button7 == 0 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button6").setValue(0); elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 1 and button5 == 1 and button6 == 0 and button7 == 0 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button5").setValue(0); elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 1 and button5 == 0 and button6 == 0 and button7 == 0 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button4").setValue(0); elseif (button1 == 1 and button2 == 1 and button3 == 1 and button4 == 0 and button5 == 0 and button6 == 0 and button7 == 0 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button3").setValue(0); elseif (button1 == 1 and button2 == 1 and button3 == 0 and button4 == 0 and button5 == 0 and button6 == 0 and button7 == 0 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button2").setValue(0); elseif (button1 == 1 and button2 == 0 and button3 == 0 and button4 == 0 and button5 == 0 and button6 == 0 and button7 == 0 and button8 == 0 and button9 == 0 and button10 == 0) then getWindows()[1].getDatabaseNode().getChild("charsheet_radio_button1").setValue(0); end end end end
"Smile. Now."
The words are gurgitated from the half-orc who looms over you seemingly peering into your soul with a snarl. A nervous smile crosses your face as you realize the half-orc is not actually snarling, but giving you his own version of a smile.
"Good. You friend now."
-
June 5th, 2019, 00:58 #3
I believe that the dots are changed by mousewheel and or ctrl+mousewheel.
-
June 5th, 2019, 01:05 #4
Control + mousewheel did the trick, thanks! Also what would I search the file for to make the close option shown and not hidden?
(edited as it did not show on mouseover either)Last edited by ProfDaemon; June 5th, 2019 at 01:09.
"Smile. Now."
The words are gurgitated from the half-orc who looms over you seemingly peering into your soul with a snarl. A nervous smile crosses your face as you realize the half-orc is not actually snarling, but giving you his own version of a smile.
"Good. You friend now."
-
June 5th, 2019, 01:14 #5
The ? icon probably never got implemented in this ruleset. It was written before ? became a thing in CoreRPG (afaik).
Have a look at record_char.xml in CoreRPG and look for <close_charsheet />
Then search the rest of the ruleset for close_charsheet and see what you find...
-
June 5th, 2019, 05:23 #6
Figured it out, all set
Last edited by ProfDaemon; June 5th, 2019 at 05:26.
"Smile. Now."
The words are gurgitated from the half-orc who looms over you seemingly peering into your soul with a snarl. A nervous smile crosses your face as you realize the half-orc is not actually snarling, but giving you his own version of a smile.
"Good. You friend now."
-
June 5th, 2019, 07:38 #7
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks