PDA

View Full Version : [Question] Portrait in Charsheet



Alanrockid
August 19th, 2010, 09:15
Hi everyone!
I'm making a ruleset and i would like to have the character portrait displayed both on the desktop of FG and the charsheet.
I've seen some rulesets with such feature and i've studied the code so i can adapt it to my own ruleset. The thing is that i always end up in trouble when it comes to LUA programing... i'm reading tutorials all over the internet, but still it seems too much for me.
Also, i've tried to do this by using tokenfield. Like this:

<tokenfield name="token">
<bounds>435,25,63,63</bounds>
<empty>charlist_base</empty>
</tokenfield>
With this, a empty portrait is displayed in the charsheet and i can drag tokens to it... But when i do this, the portrait turns into a small token...

So... can someone help me? Thanks in advance.

Here's some screens...
1524
1525
1526

Oberoten
August 19th, 2010, 09:43
https://www.fantasygrounds.com/forums/showthread.php?t=7241&highlight=portraitwidget

Should solve your problem. :)

- Obe

*** Edit ***
The archive contains the boiled down code from the thread to be copied into your scripts directory.

Then add :




<genericcontrol name="PortraitFrame">
<bounds>320,155,25,25</bounds>
<icon>invisible_icon</icon>
<script file="scripts\cp.lua" />
</genericcontrol>



To your charactersheet.

- Obe