[messages] [Module Design] Re: Invisible Opacity Level
timothy.mccarron at sbcglobal.net
Mon Mar 7 07:08:59 MST 2011
You can find the relevant Invisible trait code here
http://vassalengine.svn.sourceforge.net ... a?view=log
You wouldnt want to edit it but make a copied version which you would
change and import as a custom class so It does not affect other modules.
You would probably want this custom class to override/write? how
hideable works. You really need Joel or Mike or Brent or Pieter (who's
done a lot of this lately) tell you specifics here how to do it.
Going over the code it looks like (I think - could be wrong) that it is
using java.awt.AlphasComposite to create the opacity effect for the
hidden counter specifically the section:
Composite oldComposite = g2d.getComposite();
piece.draw(g, x, y, obs, zoom);
I'm guessing you are going to want to change the AlphaComposite.SRC_OVER
to 1.0F (which would be Clear).
See http://download.oracle.com/javase/1.4.2 ... osite.html
Read this topic online here:
More information about the messages